Register for your free account! | Forgot your password?

Go Back   elitepvpers > Coders Den > C/C++
You last visited: Today at 09:08

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[NosTale]Packets

Discussion on [NosTale]Packets within the C/C++ forum part of the Coders Den category.

Reply
 
Old   #1
 
elite*gold: 0
Join Date: Oct 2010
Posts: 514
Received Thanks: 65
[NosTale]Packets

Hi i have a problem i got a good source code but i don't receive login packets.What i have to add?


This is a code on c++
Code:
#include "TwojeImie2.h"

int _tmain(int argc, _TCHAR* argv[])
{
WSAData wsa;
WORD Version = MAKEWORD(2,1);
WSAStartup(Version, &wsa);

SOCKET Listen = socket(AF_INET, SOCK_STREAM, 0);
SOCKET Connect = socket(AF_INET, SOCK_STREAM, 0);

SOCKADDR_IN Server;

char ip[14] = "127.0.0.1";
int port = 1337;
Server.sin_addr.s_addr = inet_addr(ip);
Server.sin_family = AF_INET;
Server.sin_port = htons(port);

bind(Listen, (SOCKADDR*)&Server, sizeof(Server));

listen(Listen, 1);
int size = sizeof(Server);

std::cout << "--------------------------------------------------------------------------------"
<< " Server connected." << std::endl
<< " Host: " << ip << " : " << port << std::endl
<< "--------------------------------------------------------------------------------" << std::endl;
for(;;){
if(Connect = accept(Listen, (SOCKADDR*)&Server, &size)){
std::cout << "Connection accepted from: " << inet_ntoa(Server.sin_addr) << std::endl;
char recvbuf[225];
recv(Connect,recvbuf,225,0);
std::cout << recvbuf << std::endl;
}

}

WSACleanup();
std::cin.get();
return 0;
}
szymek111 is offline  
Old 09/18/2012, 20:10   #2
 
Engel1621997's Avatar
 
elite*gold: 0
Join Date: Sep 2011
Posts: 581
Received Thanks: 72


This ?

And Port of LoginServer is 4001
Engel1621997 is offline  
Old 09/18/2012, 20:46   #3
 
elite*gold: 113
The Black Market: 133/2/0
Join Date: Dec 2009
Posts: 16,685
Received Thanks: 4,450
Arrow Nostale -> C/C++

#moved
Rorc is offline  
Old 09/20/2012, 20:25   #4
 
elite*gold: 0
Join Date: Dec 2011
Posts: 367
Received Thanks: 199
no..
4001 = old client
4003 = new client..

you try whit 4001 and 4003..
Kingrap is offline  
Thanks
1 User
Old 09/20/2012, 20:41   #5
 
ernilos's Avatar
 
elite*gold: 20
Join Date: Jan 2012
Posts: 766
Received Thanks: 645
Quote:
Originally Posted by Kingrap View Post
no..
4001 = old client
4003 = new client..

you try whit 4001 and 4003..
Lool, for that dont work my client ._.
ernilos is offline  
Old 09/21/2012, 14:43   #6
 
elite*gold: 0
Join Date: Dec 2011
Posts: 367
Received Thanks: 199
now worked?
Kingrap is offline  
Old 10/07/2012, 17:26   #7
 
elite*gold: 0
Join Date: Oct 2010
Posts: 514
Received Thanks: 65
No It's not work ;/


I have a question how is port of polish nostale ?? No Italian,German
szymek111 is offline  
Old 10/07/2012, 23:47   #8
 
ernilos's Avatar
 
elite*gold: 20
Join Date: Jan 2012
Posts: 766
Received Thanks: 645
Quote:
Originally Posted by szymek111 View Post
No It's not work ;/


I have a question how is port of polish nostale ?? No Italian,German
Get it with sniffer(Wpe pro) ^^
ernilos is offline  
Old 10/12/2012, 17:41   #9
 
elite*gold: 0
Join Date: Oct 2010
Posts: 514
Received Thanks: 65
#include "TwojeImie.h"

int _tmain(int argc, _TCHAR* argv[])
{
WSAData wsa;
WORD Version = MAKEWORD(2,1);
WSAStartup(Version, &wsa);

SOCKET Listen = socket(AF_INET, SOCK_STREAM, 0);
SOCKET Connect = socket(AF_INET, SOCK_STREAM, 0);

SOCKADDR_IN Server;

char ip[14] = "86.63.112.65";
int port = 4003;
Server.sin_addr.s_addr = inet_addr(ip);
Server.sin_family = AF_INET;
Server.sin_port = htons(port);

bind(Listen, (SOCKADDR*)&Server, sizeof(Server));

listen(Listen, 1);
int size = sizeof(Server);

std::cout << "--------------------------------------------------------------------------------"
<< " Server connected." << std::endl
<< " Host: " << ip << " : " << port << std::endl
<< "--------------------------------------------------------------------------------" << std::endl;
for(;{
if(Connect = accept(Listen, (SOCKADDR*)&Server, &size)){
std::cout << "Connection accepted from: " << inet_ntoa(Server.sin_addr) << std::endl;
char recvbuf[225];
recv(Connect,recvbuf,225,0);
std::cout << recvbuf << std::endl;
}

}

WSACleanup();
std::cin.get();
return 0;

}

std::string DecryptLoginPacket(std::string str, int plength)
{
std::string decrypted_string;

for (int i = 0; i < plength; i++) { decrypted_string += str[i] - 0xF ^ 0xC3; }

return decrypted_string;


I hex in nostalex.dat file for my ip and port and its dont receive and send login packet I not know what is wrong
szymek111 is offline  
Reply




All times are GMT +1. The time now is 09:10.


Powered by vBulletin®
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.
This site is protected by reCAPTCHA and the Google Privacy Policy and Terms of Service apply.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2025 elitepvpers All Rights Reserved.