🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #7981

Re: Bad URL(), Bad Encoder, Bad...

#7981
From: Joi Ellis [TeamB]
Date: Sat, 05 May 2001 14:51
26 lines
1973 bytes
Harry Whitehouse <harry@envmgr.com> wrote:
> I'm doing a simple GET to a server, and the data portion of the get string
> contains some \u0081 and \u0080 characters used for control.

> Somewhere in the URL MyURL = new URL(".. get operation");          the Java
> runtime is converting these characters to x3F.  This is some sort of
> encoding conversion, because the range of values between x80 and x9F is
> reserved for other Unicode mischief.

[snip]
> This is a HARD one!   Anyone have any thoughts?

You can't send binary data (legally) with a GET.  The characters allowed in
a GET are limited mostly to alphanumerics and excludes space and plus.  Look up
URL encoding, I think there's a Java method that handles it for you.  Any
non-alphanumerics in a GET have to be encoded, ie a space would become a
+ or %20, and a + would become %2B, and an 0x80 would be %80.

I'd just use a POST instead of a GET method.  You can then pass your binary
data into the server via the server's STDIN.

-- 
Joi Ellis (TeamB) 
No direct email, please.
For best results, post on news server newsgroups.borland.com!
Newsgroup Info: http://www.borland.com/newsgroups/guide.html
Technical Details
Message-ID: <3af41379_2@dnews>
Path: arc1-ca.pugleaf.net!newsfeed.google.com!sn-xit-02!sn-xit-03!supernews.com!logbridge.uoregon.edu!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!dnews!not-for-mail
References: <3af356bd_2@dnews>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f74b3,5b605b92ac2631d2
X-Google-Attributes: gidf74b3,public
X-Google-ArrivalTime: 2001-05-05 08:08:45 PST
Message-ID: <3af41379_2@dnews>
From: "Joi Ellis [TeamB]" <joi@aravox.com>
Subject: Re: Bad URL(), Bad Encoder, Bad...
Newsgroups: borland.public.jbuilder.java.language
References: <3af356bd_2@dnews>
User-Agent: tin/1.4.2-20000205 ("Possession") (UNIX) (Linux/2.2.16-3 (i686))
NNTP-Posting-Host: 209.46.41.66
Date: 5 May 2001 07:51:37 -0700
X-Trace: dnews 989074297 209.46.41.66 (5 May 2001 07:51:37 -0700)
Lines: 26
Path: arc1-ca.pugleaf.net!newsfeed.google.com!sn-xit-02!sn-xit-03!supernews.com!logbridge.uoregon.edu!news.maxwell.syr.edu!newsfeed00.sul.t-online.de!newsfeed01.sul.t-online.de!t-online.de!dnews!not-for-mail