Copying the result to notepad confirms the missing special characters..

I'll try your suggestion.

Thanks.

<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
Virus-free.www.avg.com
<http://www.avg.com/email-signature?utm_medium=email&utm_source=link&utm_campaign=sig-email&utm_content=webmail>
<#DAB4FAD8-2DD7-40BB-A1B8-4E2AA1F9FDF2>

On Tue, Jul 2, 2024 at 8:33 AM 'Dan Kortschak' via golang-nuts <
golang-nuts@googlegroups.com> wrote:

> On Mon, 2024-07-01 at 12:03 -0700, Hugh Myrie wrote:
> > I am trying to preserve special characters (group separators and
> > field separators) when reading the request body from a POST request.
> >
> > When I do a dumpRequest I am able to see the special characters (Hex
> > Format, for example: \x1c or \x03). I am sending the data from the
> > client as text/plain.
> >
> > I have tried sending the data as JSON and using the decoder in Go. I
> > have also tried using Base64 and decoding in go accordingly. I have
> > tried json.unmarshal to decode the incoming JSON data. However, in
> > every instance the special characters are removed.
> >
> > I need the special characters to be preserved so I can send the data
> > for further processing. I need the special characters not the
> > hexadecimal representation.
> >
> > I am able to see the actual data being sent to the Go server. I also
> > tried encoding the data from the client side.
> >
> > Your help would be greatly appreciated.
>
> This looks to be working as expected. https://go.dev/play/p/fqLPbsMKaOm
>
> How are you seeing the bytes being missing?
>
>
> --
> You received this message because you are subscribed to a topic in the
> Google Groups "golang-nuts" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/golang-nuts/8cLWTdxHQCI/unsubscribe.
> To unsubscribe from this group and all its topics, send an email to
> golang-nuts+unsubscr...@googlegroups.com.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/golang-nuts/9cf1e4d31b68f7601839a450e1a9aa572458e756.camel%40kortschak.io
> .
>


-- 
http://www.jaxtr.com/blessed_hope

-- 
You received this message because you are subscribed to the Google Groups 
"golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to golang-nuts+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/golang-nuts/CAN-X3%3DZtCpnBMd2Tqr4ohfXRq-xSNH6ij-X%3DXsyjp%3DFy%2Bh1LZA%40mail.gmail.com.

Reply via email to