Strange Behavior with SFSEventParam.LOGIN_PASSWORD

Post here your questions about the Java client / Android API for SFS2X

Moderators: Lapo, Bax

sylhouette
Posts: 20
Joined: 09 Oct 2011, 01:29
Location: Indonesia
Contact:

Strange Behavior with SFSEventParam.LOGIN_PASSWORD

Postby sylhouette » 09 Oct 2011, 01:46

I am quite new to SFS2X development, and I want to use this server for my Android multiplayer card game app. I created a simple LoginHandler for my Android app.

I noticed a strange behavior with the SFSEventParam.LOGIN_PASSWORD. What does exactly this SFSEventParam.LOGIN_PASSWORD do when I send a password string to it?

I tried this scenario: I always send the username a and password of 4124bca9335c27f86f24ba207a4912 to the LoginHandler. But each time I execute my program the LoginHandler sysout always shows different password each time. I need to get my password validated in my Oracle DB.

My LoginHandler snippet

Code: Select all

String username = (String) event.getParameter(SFSEventParam.LOGIN_NAME);

String password = (String) event.getParameter(SFSEventParam.LOGIN_PASSWORD);

System.out.println("username: " + username + ", password: " + password);


It gives the following sysout:

Code: Select all

username: a, password: 2977a5ab3d7594befc6bdd839a83b207

username: a, password: ab257ba4ae0dd4a5ba7b9188fd5f1959

username: a, password: 993b78067a549b0d14c0029611745e54c


I did not change the code, I simply tried to login several times. I'm confused. Anyone can help? Thank you very much [/code]
User avatar
Bax
Site Admin
Posts: 4609
Joined: 29 Mar 2005, 09:50
Location: Italy
Contact:

Postby Bax » 09 Oct 2011, 10:30

Paolo Bax
The SmartFoxServer Team
sylhouette
Posts: 20
Joined: 09 Oct 2011, 01:29
Location: Indonesia
Contact:

Postby sylhouette » 10 Oct 2011, 01:23

Really thankful for the quick help :)

Return to “SFS2X Java / Android API”

Who is online

Users browsing this forum: No registered users and 15 guests