gsloneG
Windmill2y ago
3 replies
gslone

Null bytes in JSON

Hey, I want to pass a JSON object into a script that must contain null-bytes in strings. Like so:

{
  "unicodePwd": "a\u0000"
}


(background: the LDAP password attribute must be passed as UTF-16)

I'm getting the error "error returned from database: unsupported Unicode escape sequence". It should be valid JSON though, and other JSON parsers seem to accept this. Is there anything that I can do here?
Was this page helpful?