Re: Http version error

2003-03-26 Thread Claudio Bisegni
I'have tried now all work correctly, thanks to all of this mlist
On Mercoledì, mar 26, 2003, at 20:05 Europe/Rome, Renaud Bruyeron wrote:
Yes, the 2 spaces cause the 505 since the spec only allows 1 space.
Now the 400 bad request is because you do not have a Host: header (like
Craig mentionned, this is required in HTTP/1.1)
Try HTTP/1.0 or alternatively make sure you have a Host: header

 - Renaud

"Claudio Bisegni" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
i have tryed now with one space tommy give me the erro BAd request
thia is my code for create the http request



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Http version error

2003-03-26 Thread Claudio Bisegni
thanks in advanced, but where i insert the host:header? first or at and 
??
On Mercoledì, mar 26, 2003, at 20:05 Europe/Rome, Renaud Bruyeron wrote:

Yes, the 2 spaces cause the 505 since the spec only allows 1 space.
Now the 400 bad request is because you do not have a Host: header (like
Craig mentionned, this is required in HTTP/1.1)
Try HTTP/1.0 or alternatively make sure you have a Host: header

 - Renaud

"Claudio Bisegni" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
i have tryed now with one space tommy give me the erro BAd request
thia is my code for create the http request



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Http version error

2003-03-26 Thread Renaud Bruyeron

Yes, the 2 spaces cause the 505 since the spec only allows 1 space.
Now the 400 bad request is because you do not have a Host: header (like
Craig mentionned, this is required in HTTP/1.1)

Try HTTP/1.0 or alternatively make sure you have a Host: header

 - Renaud

"Claudio Bisegni" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
i have tryed now with one space tommy give me the erro BAd request

thia is my code for create the http request





-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Http version error

2003-03-25 Thread [EMAIL PROTECTED]
you talk about the "closeSequence" byte array or httpMessage.append
(getHeaderString() + "\n");
 that became httpMessage.append(getHeaderString() + "\n\n");
??

good morning sean

-- Initial Header ---
 
From: "Sean Reilly" <[EMAIL PROTECTED]>
To  : "Tomcat Developers List" <[EMAIL PROTECTED]>
Cc      : 
Date    : Tue, 25 Mar 2003 16:21:12 -0600
Subject : RE: Http version error

> According to this code, you'll need another line break after the final
 header.
> 
> > -Original Message-
> > From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
> > Sent: Tuesday, March 25, 2003 3:57 PM
> > To: Tomcat Developers List
> > Subject: Re: Http version error
> > 
> > 
> > i have tryed now with one space tommy give me the erro BAd request
> > 
> > thia is my code for create the http request
> > 
> > "
> >  httpMessage.append(requestMetod);
> >  httpMessage.append(" /" + 
> > wsda.swclient.WsdaClient.confDelegator.getServerMediatorClass() + 
> > ";jsessionid="+ (sessionID==null?" ":sessionID + " ") +"HTTP/1.1
\n");
> >  httpMessage.append(getHeaderString() + "\n");
> > 
> >  byte[] headerReqbuf = httpMessage.toString().getBytes();
> > 
> >  // scrivo l'header nel buffer
> >  bas.writeBytes(headerReqbuf, 0 , headerReqbuf.length);
> > 
> >  // scrivo il dato d inviare nel buffer
> >  bas.writeBytes(data, 0, data.length);
> >  bas.writeBytes(closeSequence, 0, closeSequence.length);
> > 
> > getHeaderMessage is:
> > 
> >private String getHeaderString() {
> >  StringBuffer result = new StringBuffer();
> >  Vector keys = headerhash.getKeys();
> >  for(int idx = 0; idx < keys.size(); idx++) {
> >result.append(keys.elementAt(idx)+": 
> > "+headerhash.get(keys.elementAt(idx)));
> >result.append("\n");
> >  }
> >  return result.toString();
> >}
> > 
> > "
> > note close sequence is an array of tre byte of "\n"
> > 
> > On Tuesday, March 25, 2003, at 10:39 PM, Sean Reilly wrote:
> > 
> > > Well, the HTTP/1.1 spec 
> > (http://www.w3.org/Protocols/rfc2068/rfc2068, 
> > > Section 5.1)
> > > specifies that a single space should be used.  Since one of the 
> > > differences between tomcat 3 and tomcat 4.1 is that a new HTTP 
> > > protocol handler (Coyote) was written, it could be the problem.
> > >
> > >> -Original Message-
> > >> From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
> > >> Sent: Tuesday, March 25, 2003 3:33 PM
> > >> To: Tomcat Developers List
> > >> Subject: Re: Http version error
> > >>
> > >>
> > >> yes there are tow space you think this is the problem???
> > >> On Tuesday, March 25, 2003, at 10:26 PM, Sean Reilly wrote:
> > >>
> > >>>
> > >>>
> > >>
> > >>
> > >> 
> > 
-
> > >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> > >> For additional commands, e-mail: tomcat-dev-
[EMAIL PROTECTED]
> > >>
> > >>
> > >
> > > 
> > 
-
> > > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > > For additional commands, e-mail: tomcat-dev-
[EMAIL PROTECTED]
> > >
> > 
> > 
> > 
-
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> > 
> > 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
>


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Http version error

2003-03-25 Thread Craig R. McClanahan


On Tue, 25 Mar 2003, Sean Reilly wrote:

> Date: Tue, 25 Mar 2003 15:14:06 -0600
> From: Sean Reilly <[EMAIL PROTECTED]>
> Reply-To: Tomcat Developers List <[EMAIL PROTECTED]>
> To: Tomcat Developers List <[EMAIL PROTECTED]>
> Subject: RE: Http version error
>
> Unless you formatted the email strangely, you have an invalid HTTP request.
> The directive (POST) the URI, and the version must all be on the first line.
> Also, the  tag in the Content-Length header shouldn't be there (I assume 
> that's an email formatted thing, but just in case).
>
> So the request should be:
>
> POST /Tomcat_tre/WsdaServlet;jsessionid= HTTP/1.1
> User-Agent: WSDA_SWCLIENT
> Content-Type: application/octet-stream
> Content-length: 19
> FRAMEWORK_VERSION: 0.0WSDAFM
>

I thought HTTP/1.1 required a Host: header to identify which virtual host
this request is for?

> Does this help?
>
> Sean

Craig

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Http version error

2003-03-25 Thread Sean Reilly
According to this code, you'll need another line break after the final header.

> -Original Message-
> From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 25, 2003 3:57 PM
> To: Tomcat Developers List
> Subject: Re: Http version error
> 
> 
> i have tryed now with one space tommy give me the erro BAd request
> 
> thia is my code for create the http request
> 
> "
>  httpMessage.append(requestMetod);
>  httpMessage.append(" /" + 
> wsda.swclient.WsdaClient.confDelegator.getServerMediatorClass() + 
> ";jsessionid="+ (sessionID==null?" ":sessionID + " ") +"HTTP/1.1\n");
>  httpMessage.append(getHeaderString() + "\n");
> 
>  byte[] headerReqbuf = httpMessage.toString().getBytes();
> 
>  // scrivo l'header nel buffer
>  bas.writeBytes(headerReqbuf, 0 , headerReqbuf.length);
> 
>  // scrivo il dato d inviare nel buffer
>  bas.writeBytes(data, 0, data.length);
>  bas.writeBytes(closeSequence, 0, closeSequence.length);
> 
> getHeaderMessage is:
> 
>private String getHeaderString() {
>  StringBuffer result = new StringBuffer();
>  Vector keys = headerhash.getKeys();
>  for(int idx = 0; idx < keys.size(); idx++) {
>result.append(keys.elementAt(idx)+": 
> "+headerhash.get(keys.elementAt(idx)));
>result.append("\n");
>  }
>  return result.toString();
>}
> 
> "
> note close sequence is an array of tre byte of "\n"
> 
> On Tuesday, March 25, 2003, at 10:39 PM, Sean Reilly wrote:
> 
> > Well, the HTTP/1.1 spec 
> (http://www.w3.org/Protocols/rfc2068/rfc2068, 
> > Section 5.1)
> > specifies that a single space should be used.  Since one of the 
> > differences between tomcat 3 and tomcat 4.1 is that a new HTTP 
> > protocol handler (Coyote) was written, it could be the problem.
> >
> >> -Original Message-
> >> From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
> >> Sent: Tuesday, March 25, 2003 3:33 PM
> >> To: Tomcat Developers List
> >> Subject: Re: Http version error
> >>
> >>
> >> yes there are tow space you think this is the problem???
> >> On Tuesday, March 25, 2003, at 10:26 PM, Sean Reilly wrote:
> >>
> >>>
> >>>
> >>
> >>
> >> 
> -
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >>
> >
> > 
> -
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail: [EMAIL PROTECTED]
> >
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Http version error

2003-03-25 Thread Claudio Bisegni
i have tryed now with one space tommy give me the erro BAd request

thia is my code for create the http request

"
httpMessage.append(requestMetod);
httpMessage.append(" /" + 
wsda.swclient.WsdaClient.confDelegator.getServerMediatorClass() + 
";jsessionid="+ (sessionID==null?" ":sessionID + " ") +"HTTP/1.1\n");
httpMessage.append(getHeaderString() + "\n");

byte[] headerReqbuf = httpMessage.toString().getBytes();

// scrivo l'header nel buffer
bas.writeBytes(headerReqbuf, 0 , headerReqbuf.length);
// scrivo il dato d inviare nel buffer
bas.writeBytes(data, 0, data.length);
bas.writeBytes(closeSequence, 0, closeSequence.length);
getHeaderMessage is:

  private String getHeaderString() {
StringBuffer result = new StringBuffer();
Vector keys = headerhash.getKeys();
for(int idx = 0; idx < keys.size(); idx++) {
  result.append(keys.elementAt(idx)+": 
"+headerhash.get(keys.elementAt(idx)));
  result.append("\n");
}
return result.toString();
  }

"
note close sequence is an array of tre byte of "\n"

On Tuesday, March 25, 2003, at 10:39 PM, Sean Reilly wrote:

Well, the HTTP/1.1 spec (http://www.w3.org/Protocols/rfc2068/rfc2068, 
Section 5.1)
specifies that a single space should be used.  Since one of the 
differences between tomcat 3 and tomcat 4.1 is that a new HTTP 
protocol handler (Coyote) was written, it could be the problem.

-Original Message-
From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
Sent: Tuesday, March 25, 2003 3:33 PM
To: Tomcat Developers List
Subject: Re: Http version error
yes there are tow space you think this is the problem???
On Tuesday, March 25, 2003, at 10:26 PM, Sean Reilly wrote:




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Http version error

2003-03-25 Thread Claudio Bisegni
thianks for the help tomorrow i'll try now is to late, in italy for me, 
tomorrow i'll have a grea work day... i notice you tomorrow

Thanks for now sean

Claudio
On Tuesday, March 25, 2003, at 10:39 PM, Sean Reilly wrote:
Well, the HTTP/1.1 spec (http://www.w3.org/Protocols/rfc2068/rfc2068, 
Section 5.1)
specifies that a single space should be used.  Since one of the 
differences between tomcat 3 and tomcat 4.1 is that a new HTTP 
protocol handler (Coyote) was written, it could be the problem.

-Original Message-
From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
Sent: Tuesday, March 25, 2003 3:33 PM
To: Tomcat Developers List
Subject: Re: Http version error
yes there are tow space you think this is the problem???
On Tuesday, March 25, 2003, at 10:26 PM, Sean Reilly wrote:




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Http version error

2003-03-25 Thread Sean Reilly
Well, the HTTP/1.1 spec (http://www.w3.org/Protocols/rfc2068/rfc2068, Section 5.1)
specifies that a single space should be used.  Since one of the differences between 
tomcat 3 and tomcat 4.1 is that a new HTTP protocol handler (Coyote) was written, it 
could be the problem.

> -Original Message-
> From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 25, 2003 3:33 PM
> To: Tomcat Developers List
> Subject: Re: Http version error
> 
> 
> yes there are tow space you think this is the problem???
> On Tuesday, March 25, 2003, at 10:26 PM, Sean Reilly wrote:
> 
> >  
> >  
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Http version error

2003-03-25 Thread Claudio Bisegni
yes there are tow space you think this is the problem???
On Tuesday, March 25, 2003, at 10:26 PM, Sean Reilly wrote:
 
 


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Http version error

2003-03-25 Thread Sean Reilly
Are there two spaces between the URI and the version in the real request?

POST /Tomcat_tre/WsdaServlet;jsessionid=  HTTP/1.1
^^

That could be the source of the problem (if it's not just in the email).

> -Original Message-
> From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 25, 2003 3:23 PM
> To: Tomcat Developers List
> Subject: Re: Http version error
> 
> 
> thanks in advanced sean,
> in effectly the email wsa wrong formatted, the real my post is:
> 
> POST /Tomcat_tre/WsdaServlet;jsessionid=  HTTP/1.1
> User-Agent: WSDA_SWCLIENT
> Content-Type: application/octet-stream
> Content-length: 19
> FRAMEWORK_VERSION: 0.0WSDAFM
> 
> but the error remain
> 
> I flow this rewest acros a socket
> any idea?
> On Tuesday, March 25, 2003, at 10:14 PM, Sean Reilly wrote:
> 
> > POST /Tomcat_tre/WsdaServlet;jsessionid= HTTP/1.1
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Http version error

2003-03-25 Thread Claudio Bisegni
thanks in advanced sean,
in effectly the email wsa wrong formatted, the real my post is:
POST /Tomcat_tre/WsdaServlet;jsessionid=  HTTP/1.1
User-Agent: WSDA_SWCLIENT
Content-Type: application/octet-stream
Content-length: 19
FRAMEWORK_VERSION: 0.0WSDAFM
but the error remain

I flow this rewest acros a socket
any idea?
On Tuesday, March 25, 2003, at 10:14 PM, Sean Reilly wrote:
POST /Tomcat_tre/WsdaServlet;jsessionid= HTTP/1.1
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: Http version error

2003-03-25 Thread Sean Reilly
Unless you formatted the email strangely, you have an invalid HTTP request.
The directive (POST) the URI, and the version must all be on the first line.
Also, the  tag in the Content-Length header shouldn't be there (I assume 
that's an email formatted thing, but just in case).

So the request should be:

POST /Tomcat_tre/WsdaServlet;jsessionid= HTTP/1.1
User-Agent: WSDA_SWCLIENT
Content-Type: application/octet-stream
Content-length: 19
FRAMEWORK_VERSION: 0.0WSDAFM

Does this help?

Sean

> -Original Message-
> From: Claudio Bisegni [mailto:[EMAIL PROTECTED]
> Sent: Tuesday, March 25, 2003 3:03 PM
> To: [EMAIL PROTECTED]
> Subject: Http version error
> 
> 
> Hi all,
> 
> I have a wireless java application writing in superwaba, and i have
> made myself a code for sending an http servlet request to tomcat.
> 
> In tomcat 3 al work but with tomcat 4.1 i have his errror
> "HTTP/1.1 505 HTTP Version Not Supported" anyone has an idea??
> 
> This is the htttp request that i made is:
> 
> 
> POST
> /Tomcat_tre/WsdaServlet;jsessionid=   HTTP/1.1
> User-Agent: WSDA_SWCLIENT
> Content-Type: application/octet-stream
> Content-length: 19
> FRAMEWORK_VERSION: 0.0WSDAFM
> 
> 
> -
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]