Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: Failed to Create Session #4749

Open
4 of 6 tasks
RickParky opened this issue Jun 10, 2024 · 23 comments
Open
4 of 6 tasks

[Bug]: Failed to Create Session #4749

RickParky opened this issue Jun 10, 2024 · 23 comments
Assignees
Labels
bug An issue describing unexpected behavior of code

Comments

@RickParky
Copy link

RickParky commented Jun 10, 2024

By submitting this bug issue, you agree to the following.

  • This is a bug in the software that resides in this repository, and not a support matter (use https://otland.net/forums/support.16/ for support)
  • This issue is reproducible without changes to the C++ code in this repository
  • This bug has not been resolved in master branch
  • There is no existing issue for this bug already

Does this bug crash tfs?

no

Server Version

1.6 (Release)

Operation System

Windows

OS Description

Window 11

Bug description

Upon attempting login, get error "failed to create session"

Possible Pull Requests which are to blame

  • #
  • #

Steps to reproduce

Open server -> Login = Error

Using MyAAC latest version also.

Actual Behavior

otclient_x64_7V6oRMgCax
WindowsTerminal_QeUiPHA9jJ

Expected Behavior

.

Backtrace

No response

@RickParky RickParky added bug An issue describing unexpected behavior of code needs-confirmation not confirmed by a developer yet labels Jun 10, 2024
@github-project-automation github-project-automation bot moved this to Backlog in TFS 1.8 Jun 10, 2024
@ArturKnopik
Copy link
Contributor

Can you check with types are used in Session table + default values?
You can try test using this fix: #4745

@RickParky
Copy link
Author

Problem still persists after this change unfortunately.

@EvilHero90
Copy link
Contributor

Please try to turn off apache and only run mysql server, then change in config.lua httpPort = 80 and try to login.
If that works then your aac needs to be patched in order to successfully login

@danyelvarejao
Copy link
Contributor

danyelvarejao commented Jun 10, 2024

Please try to turn off apache and only run mysql server, then change in config.lua httpPort = 80 and try to login. If that works then your aac needs to be patched in order to successfully login

I encountered the same error while attempting to connect. I'm using only MySQL server with the OTClient by Mehah. Additionally, I'm running the MySQL server on Docker, and the environment is Windows. The issue appears to persist.

@aenyo69
Copy link

aenyo69 commented Jun 10, 2024

Same problem for me.

@EvilHero90
Copy link
Contributor

Please try to turn off apache and only run mysql server, then change in config.lua httpPort = 80 and try to login. If that works then your aac needs to be patched in order to successfully login

I encountered the same error while attempting to connect. I'm using only MySQL server with the OTClient by Mehah. Additionally, I'm running the MySQL server on Docker, and the environment is Windows. The issue appears to persist.

As far as I know Mehah's Client never worked with the current protocol (taken from his github)

function g_game.getSupportedClients()
    return { 740, 741, 750, 755, 760, 770, 772, 780, 781, 782, 790, 792, 800, 810, 811, 820, 821, 822, 830, 831, 840,
        842, 850, 853, 854, 855, 857, 860, 861, 862, 870, 871, 900, 910, 920, 931, 940, 943, 944, 951, 952, 953,
        954, 960, 961, 963, 970, 971, 972, 973, 980, 981, 982, 983, 984, 985, 986, 1000, 1001, 1002, 1010, 1011,
        1012, 1013, 1020, 1021, 1022, 1030, 1031, 1032, 1033, 1034, 1035, 1036, 1037, 1038, 1039, 1040, 1041, 1050,
        1051, 1052, 1053, 1054, 1055, 1056, 1057, 1058, 1059, 1060, 1061, 1062, 1063, 1064, 1070, 1071, 1072, 1073,
        1074, 1075, 1076, 1080, 1081, 1082, 1090, 1091, 1092, 1093, 1094, 1095, 1096, 1097, 1098, 1099, 1100, 1281, 1285,
        1286, 1287, 1291, 1300, 1314, 1316, 1320, 1321, 1332 }
end

Unless Mehah changes that there is currently no way to connect with it
I suggest for now getting the 13.10.12892 client, this one is confirmed to be working

@danyelvarejao
Copy link
Contributor

danyelvarejao commented Jun 10, 2024

I really had to add to this list to try to log in with client 13.10. Considering this, should we update the project's README?
We should also consider adding a tutorial on how to find these supported clients in TFS.

The Forgotten Server is a free and open-source MMORPG server emulator written in C++. It is a fork of the [OpenTibia Server](https://github.com/opentibia/server) project. To connect to the server, you can use [OTClient](https://github.com/mehah/otclient).

@EvilHero90
Copy link
Contributor

We already got the login for Mehah's otc working, we just need to polish the details and propose a PR.
For anyone interested to try the workaround and report back if it worked for him, I'll leave a step by step guide in this post.

TFS side:

  1. config.lua
    httpPort = 80

Client side:

  1. entergame.lua
    ip = world.externaladdress, -> ip = world.externaladdressunprotected,
    port = world.externalport, -> port = world.externalportunprotected,
  2. features.lua
    g_game.enableFeature(GameSequencedPackets) -> --g_game.enableFeature(GameSequencedPackets)
  3. game.lua
    from:
function g_game.getSupportedClients()
    return { 740, 741, 750, 755, 760, 770, 772, 780, 781, 782, 790, 792, 800, 810, 811, 820, 821, 822, 830, 831, 840,
        842, 850, 853, 854, 855, 857, 860, 861, 862, 870, 871, 900, 910, 920, 931, 940, 943, 944, 951, 952, 953,
        954, 960, 961, 963, 970, 971, 972, 973, 980, 981, 982, 983, 984, 985, 986, 1000, 1001, 1002, 1010, 1011,
        1012, 1013, 1020, 1021, 1022, 1030, 1031, 1032, 1033, 1034, 1035, 1036, 1037, 1038, 1039, 1040, 1041, 1050,
        1051, 1052, 1053, 1054, 1055, 1056, 1057, 1058, 1059, 1060, 1061, 1062, 1063, 1064, 1070, 1071, 1072, 1073,
        1074, 1075, 1076, 1080, 1081, 1082, 1090, 1091, 1092, 1093, 1094, 1095, 1096, 1097, 1098, 1099, 1100, 1281, 1285,
        1286, 1287, 1291, 1300, 1314, 1316, 1320, 1321, 1332 }
end

to:

function g_game.getSupportedClients()
    return { 740, 741, 750, 755, 760, 770, 772, 780, 781, 782, 790, 792, 800, 810, 811, 820, 821, 822, 830, 831, 840,
        842, 850, 853, 854, 855, 857, 860, 861, 862, 870, 871, 900, 910, 920, 931, 940, 943, 944, 951, 952, 953,
        954, 960, 961, 963, 970, 971, 972, 973, 980, 981, 982, 983, 984, 985, 986, 1000, 1001, 1002, 1010, 1011,
        1012, 1013, 1020, 1021, 1022, 1030, 1031, 1032, 1033, 1034, 1035, 1036, 1037, 1038, 1039, 1040, 1041, 1050,
        1051, 1052, 1053, 1054, 1055, 1056, 1057, 1058, 1059, 1060, 1061, 1062, 1063, 1064, 1070, 1071, 1072, 1073,
        1074, 1075, 1076, 1080, 1081, 1082, 1090, 1091, 1092, 1093, 1094, 1095, 1096, 1097, 1098, 1099, 1100, 1281, 1285,
        1286, 1287, 1291, 1300, 1310, 1314, 1316, 1320, 1321, 1332 }
end

otclient_x64_2rfUWEjvL7
This should let you correctly login

@EvilHero90 EvilHero90 removed the needs-confirmation not confirmed by a developer yet label Jun 13, 2024
@ArturKnopik
Copy link
Contributor

2. features.lua
g_game.enableFeature(GameSequencedPackets) -> --g_game.enableFeature(GameSequencedPackets)

left side is the same as right side

@RickParky
Copy link
Author

  1. features.lua
    g_game.enableFeature(GameSequencedPackets) -> --g_game.enableFeature(GameSequencedPackets)

left side is the same as right side

Read again, it's not..

@RickParky
Copy link
Author

RickParky commented Jun 13, 2024

otclient_x64_JqVg6HJU6w

Different Error this time, this is with all of above changes.
Thank you all for effort trying to resolve this =) Fingers crossed we get there.

@EvilHero90
Copy link
Contributor

otclient_x64_JqVg6HJU6w otclient_x64_JqVg6HJU6w

Different Error this time, this is with all of above changes. Thank you all for effort trying to resolve this =) Fingers crossed we get there.

Do you have Apache turned on, If yes then try to change the httpPort in tfs to anything else and have it matching in the client, kinda curious If that works

@RickParky
Copy link
Author

otclient_x64_JqVg6HJU6w

    [
      
        ![otclient_x64_JqVg6HJU6w](https://private-user-images.githubusercontent.com/97258974/339247287-9213a538-0290-4094-8154-94a3c96bfe27.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTgyNjM0MzIsIm5iZiI6MTcxODI2MzEzMiwicGF0aCI6Ii85NzI1ODk3NC8zMzkyNDcyODctOTIxM2E1MzgtMDI5MC00MDk0LTgxNTQtOTRhM2M5NmJmZTI3LmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2M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mVwb19pZD0wIn0.zxuls_bMzsReHAh0ErQY_a9S-hMFUvQwt8Tqw3OWolA)
    
    
      
        
          
        
        
          
          
        
      
      [
        
          
        
      ](https://private-user-images.githubusercontent.com/97258974/339247287-9213a538-0290-4094-8154-94a3c96bfe27.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTgyNjM0MzIsIm5iZiI6MTcxODI2MzEzMiwicGF0aCI6Ii85NzI1ODk3NC8zMzkyNDcyODctOTIxM2E1MzgtMDI5MC00MDk0LTgxNTQtOTRhM2M5NmJmZTI3LmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2MTMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNjEzVDA3MTg1MlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTg4MzcwN2Q0YWFiMDcwZmY2ZDQ1Zjg1ZTExYzI1ZmRlYmY3MGQ5NmZhYjQ0NzhkNTE2ZmM1Yjg4ZWRhMzFmYmMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.zxuls_bMzsReHAh0ErQY_a9S-hMFUvQwt8Tqw3OWolA)
    
   [ ![otclient_x64_JqVg6HJU6w](https://private-user-images.githubusercontent.com/97258974/339247287-9213a538-0290-4094-8154-94a3c96bfe27.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6Im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MzsReHAh0ErQY_a9S-hMFUvQwt8Tqw3OWolA)
      
    ](https://private-user-images.githubusercontent.com/97258974/339247287-9213a538-0290-4094-8154-94a3c96bfe27.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTgyNjM0MzIsIm5iZiI6MTcxODI2MzEzMiwicGF0aCI6Ii85NzI1ODk3NC8zMzkyNDcyODctOTIxM2E1MzgtMDI5MC00MDk0LTgxNTQtOTRhM2M5NmJmZTI3LmdpZj9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNDA2MTMlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjQwNjEzVDA3MTg1MlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTg4MzcwN2Q0YWFiMDcwZmY2ZDQ1Zjg1ZTExYzI1ZmRlYmY3MGQ5NmZhYjQ0NzhkNTE2ZmM1Yjg4ZWRhMzFmYmMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.zxuls_bMzsReHAh0ErQY_a9S-hMFUvQwt8Tqw3OWolA)
    
    
      
        
          
        
        
          
          
        
      
      [
        
          
        
      ](https://private-user-images.githubusercontent.com/97258974/339247287-9213a538-0290-4094-8154-94a3c96bfe27.gif?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MTgyNjM0MzIsIm5iZiI6MTcx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MlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTg4MzcwN2Q0YWFiMDcwZmY2ZDQ1Zjg1ZTExYzI1ZmRlYmY3MGQ5NmZhYjQ0NzhkNTE2ZmM1Yjg4ZWRhMzFmYmMmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0JmFjdG9yX2lkPTAma2V5X2lkPTAmcmVwb19pZD0wIn0.zxuls_bMzsReHAh0ErQY_a9S-hMFUvQwt8Tqw3OWolA)

Different Error this time, this is with all of above changes. Thank you all for effort trying to resolve this =) Fingers crossed we get there.

Do you have Apache turned on, If yes then try to change the httpPort in tfs to anything else and have it matching in the client, kinda curious If that works

Same error no matter the httpPort, Apache is indeed turned on.
image

@ArturKnopik
Copy link
Contributor

  1. features.lua
    g_game.enableFeature(GameSequencedPackets) -> --g_game.enableFeature(GameSequencedPackets)

left side is the same as right side

Read again, it's not..

ok.. i missed "--" there :D

@sscwelsh
Copy link

sscwelsh commented Jun 17, 2024

I am having the same issue, I followed the steps on the work around and go to the same spot as @RickParky .
I also tried the port change as suggested with the same error: please see the attached GIF.

I am currently running the Mysql DB on a ubuntu 22 lts server and the server was compiled today and is running on windows 11.

image

tibiaoterror

@reyaleman
Copy link
Contributor

remove .php from 127.0.0.1/login.php

I am having the same issue, I followed the steps on the work around and go to the same spot as @RickParky . I also tried the port change as suggested with the same error: please see the attached GIF.

I am currently running the Mysql DB on a ubuntu 22 lts server and the server was compiled today and is running on windows 11.

@sscwelsh
Copy link

sscwelsh commented Jun 17, 2024

remove .php from 127.0.0.1/login.php

I am having the same issue, I followed the steps on the work around and go to the same spot as @RickParky . I also tried the port change as suggested with the same error: please see the attached GIF.
I am currently running the Mysql DB on a ubuntu 22 lts server and the server was compiled today and is running on windows 11.

Same error
tibiaoterror2

image

@froomzim
Copy link

froomzim commented Jun 18, 2024

I fixed this issue on protocollogin.cpp

here's the new code:

// Generate and add session key
static std::independent_bits_engine<std::default_random_engine, CHAR_BIT, unsigned short> rbe;
std::string sessionKey(16, '\x00');
std::generate(sessionKey.begin(), sessionKey.end(), std::ref(rbe));

output->addByte(0x28);
output->addString(tfs::base64::encode({sessionKey.data(), sessionKey.size()}));

// Convert sessionKey to hexadecimal
std::string sessionKeyHex;
for (unsigned char c : sessionKey) {
	sessionKeyHex += fmt::format("{:02x}", c);
}

// Insert the session into the database
if (!db.executeQuery(fmt::format(
        "INSERT INTO `sessions` (`token`, `account_id`, `ip`) VALUES (UNHEX('{}'), {}, INET6_ATON('{}'))",
        sessionKeyHex, account.id, getConnection()->getIP().to_string()))) {
	disconnectClient("Failed to create session.\nPlease try again later.", version);
	return;
}

@ranisalt
Copy link
Member

@froomzim what version of MySQL/MariaDB are you running?

@froomzim
Copy link

@froomzim what version of MySQL/MariaDB are you running?

mysql Ver 15.1 Distrib 10.4.32-MariaDB, for Win64 (AMD64), source revision c4143f909528e3fab0677a28631d10389354c491

@RickParky
Copy link
Author

I fixed this issue on protocollogin.cpp

here's the new code:

// Generate and add session key static std::independent_bits_engine<std::default_random_engine, CHAR_BIT, unsigned short> rbe; std::string sessionKey(16, '\x00'); std::generate(sessionKey.begin(), sessionKey.end(), std::ref(rbe));

output->addByte(0x28);
output->addString(tfs::base64::encode({sessionKey.data(), sessionKey.size()}));

// Convert sessionKey to hexadecimal
std::string sessionKeyHex;
for (unsigned char c : sessionKey) {
	sessionKeyHex += fmt::format("{:02x}", c);
}

// Insert the session into the database
if (!db.executeQuery(fmt::format(
        "INSERT INTO `sessions` (`token`, `account_id`, `ip`) VALUES (UNHEX('{}'), {}, INET6_ATON('{}'))",
        sessionKeyHex, account.id, getConnection()->getIP().to_string()))) {
	disconnectClient("Failed to create session.\nPlease try again later.", version);
	return;
}

I've managed to login using this method on locahost, using xampp no problems. Thank you!

@froomzim
Copy link

I've managed to login using this method on locahost, using xampp no problems. Thank you!

Glad to know, gl bro

@kokekanon
Copy link

kokekanon commented Jul 11, 2024

TFS

Last commits tfs 98ff8a81: fix NPC baseSpeed & build issue (AccountType_t)
+
image

OTC Redemption

Last Commits OTC 937573e : feat: add scheduleEvent. cycleEvent and removeEvent in controller
+

            g_game.disableFeature(GameSequencedPackets)

image

Secuencia.01.1.mp4

port 80 or 8080 work

can login with OTC Redemption and CipSoft

test in 10.6.12-MariaDB and login.php of myacc

Tibia13.10.12892.zip

https://downloads.ots.me/?dir=data/tibia-clients/windows/zip

change ip :

https://ots.me/ots-ip-changer-12/

login.php

https://github.com/slawkens/myaac

@kokekanon kokekanon mentioned this issue Nov 20, 2024
3 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An issue describing unexpected behavior of code
Projects
Status: Backlog
Development

No branches or pull requests

10 participants