Skip to content

Commit 8fdf60c

Browse files
author
Adrian Jones
committed
DVPL-7026 added "Splunk " to the authentication of streaming sockets if using a token
1 parent 3aa4b56 commit 8fdf60c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

splunklib/client.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1937,7 +1937,7 @@ def attach(self, host=None, source=None, sourcetype=None):
19371937
if sourcetype is not None: args['sourcetype'] = sourcetype
19381938
path = UrlEncoded(PATH_RECEIVERS_STREAM + "?" + urllib.urlencode(args), skip_encode=True)
19391939

1940-
cookie_or_auth_header = "Authorization: %s\r\n" % self.service.token
1940+
cookie_or_auth_header = "Authorization: Splunk %s\r\n" % self.service.token.replace('Splunk ','')
19411941

19421942
# If we have cookie(s), use them instead of "Authorization: ..."
19431943
if self.service.has_cookies():

0 commit comments

Comments
 (0)