Getting Data In

Data Inputs REST / HTTP Header Properties: How can I specify a value with an "aring" (å) character in it?

torustad
Path Finder

Hi all,

So I am trying to specify a rest data input and I think there is a problem specifying a Header property which has a value with an "aring" (å) in it. I edited it into inputs.conf, but it was converted to an "a" when I saved the configuration back from Splunk Web.

I had same problem with curl as well; I got it to work by adding the property to a file which was read by means of the -K switch.
And it had to be an ANSI encoded file.

I have the following configuration which should be ok I think:

[rest://aName]
auth_password = 
auth_type = none
auth_user = 
backoff_time = 30
endpoint = https://aServer.a.dom.ain:8443/aProgram/system?_action=test
host = idm
http_method = POST
index = idm
index_error_response_codes = 1
polling_interval = 22
response_type = json
sequential_mode = 0
sourcetype = json_no_timestamp
streaming_request = 0
http_header_propertys = X-Username=aUserName,X-Password=N_XyZåAbC
disabled = 0

Does anybody know a way to input this password (seemingly ANSI-encoded) with the awkward å (aring)?

Unfortunately, changing the password is not an option.

Thanks and regards,
Bård Tørustad

0 Karma

DalJeanis
Legend

Did you find a solution, Bard?

0 Karma

jkat54
SplunkTrust
SplunkTrust

Yeah what he said... Try \xc3a5 or 0xc3a5 in place of the aring. If that doesn't work, try this urlencoding of it %C3%A5

0 Karma

DalJeanis
Legend

There is a UTF8 encoding for aring (0x'c3a5') , which is different from the UTF16 encoding (0x'00E5')

Have you tried turning the whole thing into a hex UTF8 character string? That would look something like this

UTF8   0x004E005F00580079005AC3A5004100620043
UTF16  0x004E005F00580079005A00E5004100620043
0 Karma

DalJeanis
Legend

I just posted a drilldown question to make sure the code sample has been vetted for format -

Posted here - https://answers.splunk.com/answers/489964/what-is-the-format-for-putting-information-into-co.html?mi...

0 Karma
Got questions? Get answers!

Join the Splunk Community Slack to learn, troubleshoot, and make connections with fellow Splunk practitioners in real time!

Meet up IRL or virtually!

Join Splunk User Groups to connect and learn in-person by region or remotely by topic or industry.

Get Updates on the Splunk Community!

[Puzzles] Solve, Learn, Repeat: Character substitutions with Regular Expressions

This challenge was first posted on Slack #puzzles channelFor BORE at .conf23, we had a puzzle question which ...

Splunk Community Badges!

  Hey everyone! Ready to earn some serious bragging rights in the community? Along with our existing badges ...

[Puzzles] Solve, Learn, Repeat: Matching cron expressions

This puzzle (first published here) is based on matching timestamps to cron expressions.All the timestamps ...