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

  • Home
  • SEARCH
  • 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 3808944
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T15:13:40+00:00 2026-05-19T15:13:40+00:00

I have a problem when i`m sending my last packet,as I said in the

  • 0

I have a problem when i`m sending my last packet,as I said in the comentary,I’m getting an warning sayng that i returned an unexpected answer follow by a different hex number every time i run it.
I am using Proxifier to test this,it always give me this when i try to connect to google:

[06:22] Starting: Test 1: Connection to the Proxy Server
[06:22] IP Address: 127.0.0.1
[06:22] Connection established
[06:22] Test passed.
[06:22] Starting: Test 2: Connection through the Proxy Server
[06:22] Authentication was successful.
[06:22] Warning : the proxy server has returned an unexpected answer (0x32).
[06:22] Connection to www.google.com:80 established through the proxy server.

`void HandleConnection()
{
    cout << "You are connected !!!" << endl;
    char temp[30];
    Recv(temp, sizeof(temp));
    if(temp[0] == 5) // test for version
    {
        cout << "Version good" << endl;
        char* reply = new char[2];
        reply[0] = 5; // version
        reply[1] = 0; // method choosed (no auth required)
        Send(reply, sizeof(reply));
        delete [] reply;
        memset(temp, '\0', sizeof(temp));
        Recv(temp, sizeof(temp));
        temp[sizeof(temp)] = '\0';
        if(temp[0] == 5) // test for version
        {
            if(temp[4] == 14) // test for lenght of www.google.com
            {
                char* domain = new char[temp[4]];
                for(int i = 0; i < temp[4]; ++i)
                {
                    domain[i] = temp[i + 5]; // copy domain name
                }
                domain[14] = '\0';
                cout << endl;
                cout << domain << endl;
                int domainLen = strlen(domain);
                //with this packet i get a warning that i send an unexpected answer
                char* reply = new char[domainLen + 6]; 
                reply[0] = 5; // version
                reply[1] = 0; // succed
                reply[2] = 0; // reserved
                reply[3] = 3; // its a domain
                reply[4] = domainLen; // lenght of domain
                for(int j = 0; j < domainLen; ++j)
                {
                    reply[j + 5] = domain[j];
                }
                reply[4 + domainLen] = 80; // port
                Send(reply, domainLen);
                delete [] reply;
            }
        }
    }

}`
  • 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-19T15:13:41+00:00Added an answer on May 19, 2026 at 3:13 pm

    Following those lines of code:

    if(temp[4] == 14) // test for lenght of www.google.com
    {
        char* domain = new char[temp[4]];
        //....
    

    Maybe it should be

    domain[13] = '\0'; instead of domain[14] = '\0';

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a problem sending POST request with VB6. The code below works properly
I have a problem with sending POST http request. It stops on (HttpWebResponse)request.GetResponse() and
I have a problem with sending string via game center. I am able to
Hi I have a problem in sending data from php to pdf. I think
I have a problem when I want to sending data using byte format in
I have a problem; I want to write a java code for sending an
I have a problem when trying to send a POST request. The sending method
I have a little problem, I'm making project and I'm sending data from client
I have a problem with Python threading and sending a string in the arguments.
I have this problem in IE8 that ignores my first stylesheet link. I don't

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.