소스 검색

fix: incorrect handling when http header value contain multiple colons. (#4574)

10YearsDiary 1 년 전
부모
커밋
109aabc6f2
1개의 변경된 파일3개의 추가작업 그리고 1개의 파일을 삭제
  1. 3 1
      api/core/workflow/nodes/http_request/http_executor.py

+ 3 - 1
api/core/workflow/nodes/http_request/http_executor.py

@@ -160,7 +160,9 @@ class HttpExecutor:
                 continue
 
             kv = kv.split(':', maxsplit=maxsplit)
-            if len(kv) == 2:
+            if len(kv) >= 3:
+                k, v = kv[0], ":".join(kv[1:])
+            elif len(kv) == 2:
                 k, v = kv
             elif len(kv) == 1:
                 k, v = kv[0], ''