Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 378627
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 12, 20262026-05-12T14:48:47+00:00 2026-05-12T14:48:47+00:00

I try to talk to a server, by telneting to it, and send the

  • 0

I try to talk to a server, by telneting to it, and send the following command through telnet terminal :

POST /%5bvUpJYKw4QvGRMBmhATUxRwv4JrU9aDnwNEuangVyy6OuHxi2YiY=%5dImage? HTTP/1.1
Content-Type: application/x-www-form-urlencoded
Content-Length: 164

[SORT]=0,1,0,10,5,0,KL,0&[FIELD]=33,38,51,58,68,88,78,98,99,101,56,57,69,70,71,72,89,90,91,92,59,60,61,62,79,80,81,82&[LIST]=1155.KL,1295.KL,7191.KL,0097.KL,2267.KL

This works very fine. Now, I wish I can use HttpClient, to talk to the server, as I use telnet to talk to the server. The reason I wish to use HttpClient, instead of using raw TCP socket, is because HttpClient does support NTLM.

However, when I use POST method with NameValuePair :

new NameValuePair("[SORT]", "0,1,0,10,5,0,KL,0")

The request will become URL encoded. The server doesn’t understand URL encoded request.

%5BSORT%5D: 0%2C1%2C0%2C10%2C5%2C0%2CKL%2C0

Is there any way I can avoid this? If not, what is the alternative library I can use? I wish to support NTLM as well.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-12T14:48:47+00:00Added an answer on May 12, 2026 at 2:48 pm

    As I mentioned in the other thread, this is not even valid HTTP POST. So you can’t do it with default post mechanism in HttpClient. You need to make the invalid body yourself and post it.

    Assuming you are using HttpClient 3, following code should work,

        HttpClient httpClient = new HttpClient();       
        PostMethod method = new PostMethod(url);        
        String badFormPost = "[SORT]=0,1,0,10,5,0,KL,0&[FIELD]=33,38,51,58,68,88,78,98,99,101,56,57,69,70,71,72,89,90,91,92,59,60,61,62,79,80,81,82&[LIST]=1155.KL,1295.KL,7191.KL,0097.KL,2267.KL";
        RequestEntity entity = new StringRequestEntity(badFormPost, 
                "application/x-www-form-urlencoded", "UTF-8");
        method.setRequestEntity(entity);
        method.setContentChunked(false);
        httpClient.executeMethod(method);
                ...
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I try to develop a web client gtalk in my http server.I know what
Try the following code public enum Color { Blue=1, Red=2, Green=3 } public List<Color>
Try executing the following in JavaScript: parseInt('01'); //equals 1 parseInt('02'); //equals 2 parseInt('03'); //equals
Ruby keeps segfaulting when using the Koala gem to talk over HTTP: /Users/pawel/.rvm/rubies/ruby-1.9.3-p0/lib/ruby/1.9.1/net/http.rb:799: [BUG]
I am trying to have a client and server talk to each other using
I have written an async UDP client to talk to a server at my
I'm using ColdFusion 7 on a Windows 2003 server to talk to a default
I've found a number of resources that talk about tuning the database server, but
In my current project, my client application first talk with the server and the
I'm using Apache Commons' FTPClient to talk to an FTP server and upload some

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.