summaryrefslogtreecommitdiff
path: root/src/login_sql
AgeCommit message (Collapse)AuthorFilesLines
2008-02-22Added $(CUSTOM_CFLAGS) into all Makefile.in to provide any custom defs ↵Lupus1-1/+1
directly to all sub make files git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12230 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-01-11Patched a mistake in r12043 that caused inter-server connection problems ↵ultramage1-0/+1
when check_client_version was enabled. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12055 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-01-10Another round of login server cleaningultramage1-169/+139
* fixed passwordencrypt on SQL not behaving correctly (since r10753) * corrected some column lengths in the login db (username, password,...) * fixed some places which used wfifo without first reallocating it * removed interserver packet 0x7532 (Request to end connection), as there was no code that actually sent this packet * moved RFIFOSKIP actions to execute as soon as possible git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12043 54d463be-8e91-2dee-dedb-b68131a5f0ec
2008-01-06Modified showmsg code to not attach a timestamp to MSG_NONE-type messages, ↵ultramage1-9/+9
generated by ShowMessage(). It now works exactly like printf(). Removed/replaced all printf calls in the code. Added a new flag to setting 'console_silent', for filtering debug messages. Silenced the "Broken pipe found" and "Server running in debug mode" messages. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12020 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-17* Added flag.server to indicate interserver socketsultramage1-3/+3
- replaces the previous way (setting 'client_addr' to 0) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11930 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-11Fixed a mistake in r11876 that prevented the login server from doing auth ↵ultramage1-1/+1
correctly due to an incorrect IP being used in the process. The whole thing should be reverted when there is a proper flag to identify interserver connections. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11888 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-09small fix to the server's packet parsing code to display server IPs correctly.ultramage1-6/+8
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11876 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-12-02Fixed charserver unable to reestablish link to login server after a ↵ultramage1-6/+17
disconnect (yet another problem caused by r11826). Copied code from TXT to SQL to perform a graceful shutdown of all login server sockets while exiting. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11848 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-30* Random cleanup/documentation.FlavioJS1-13/+14
* Made common/Makefile get the svn version from the src directory, not src/common. * Added a warning message to the install and uninstall targets. * Renamed all obj directories to obj_all, obj_txt or obj_sql in the makefiles (if an obj/ directory exists, BSD make enters it before reading the makefile) (run ./configure to update your makefiles, and don't forget to do 'make clean' before updating) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11844 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-27* TXT/SQL login server code synchronizationultramage2-139/+154
- exported several core structures to login.h - split off ladmin communication code from the TXT login server - removed all occurences of login_log(); a unified function should be added when SQL's loginlog_db logging code gets synced with TXT - removed conf setting login_log_filename - fixed ladmin getting timeouts since the ping system was changed - removed login/char server_fd[] arrays, added server[].fd instead git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11826 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-26* Normalized makefiles:FlavioJS1-5/+18
- 3 sections: variables, public targets, private/support targets - object files always in a *_OBJ variable - header files always in a *_H variable - object files always generated to an obj* subfolder - all Makefiles can be executed individually, calling other makefiles if necessary - generic object targets when possible git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11812 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-09* Re-worked the login-char-map packet spam mechanismultramage1-7/+13
- mapserver no longer sends entire user list to charserver every 10 seconds; similar change done to the char-login connection - user count updates are only sent when the value actually changes instead of servers polling each other every few seconds - the servers now prevent interserver connection timeout explicitly by sending ping/ack packet pairs instead of relying on the usercount polling to do so; keepalive is sent every 'stall_time'-2 seconds - removed the @refreshonline command as refresh happens automatically every 5 seconds git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11703 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-11-08* Changed EXIT_SUCCESS back to 0 in console.c to avoid an unnecessary include.FlavioJS1-2/+2
* Fixed gm_account_db not being deallocated in login-converter.c. * Refactoring names and documentation in db.h/db.c: - changed 'struct dbt' to 'struct DBMap' and 'DB' to 'DBMap*' - changed 'struct db' to 'struct DBMap_impl' and 'DB_impl' to 'DBMap_impl*' - changed COUNT to DB_COUNTSTAT and made it's existence not depend on DB_ENABLE_STATS - removed some @see links and corrected small typos in the documentation git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11698 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-10-19Removed some overly verbose messages from the TXT login server.ultramage1-20/+20
Fixed some signed/unsigned mismatches in the code. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11520 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-10-18Fixed some gcc-specific stuff, silenced some more warningsultramage1-2/+2
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11515 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-10-17* Merged do_sendrecv() and do_parse() into do_sockets()ultramage1-0/+1
* Fixed subnet check message displaying incorrect ip addresses * client_addr will now be properly set to 0 for server connections * Removed socket code that attempts to cope with code bugs at runtime * Removed outdated copyright and version number from startup logo git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11503 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-10-17Using predefined constants as parameters to the exit() function.ultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11501 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-10-04* Added MAX_HOTKEYS to supplement the HOTKEY_SAVING defineultramage1-1/+1
* Fixed a compile problem when hotkey saving is disabled (topic:167265) * Added script source error reporting to countitem() (topic:167165) * Removed integer mob skill state/target definition support (unused) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11353 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-30Removed redundant 'subnet' s_subnet structure variable.ultramage1-6/+6
Removed duplicate code from the sql charserver that somehow appeared after the tmpsql merge. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11333 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-26Fixed a typo in the sql login server causing client hang after entering a ↵ultramage1-1/+1
wrong password. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11305 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-21* Makefile deleting .svn in save folder.FlavioJS1-9/+16
* Limited the number of packets parsed per cycle to 3. (packet spammers create less lag) * Fixed sql login throwing an out-of-place debug message and escaping too much of the name string when creating a new login with _M/F. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11253 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-20Synced TXT/SQL login server new account creation code. Removed some totally ↵ultramage1-118/+40
useless code. Removed '4'-letter min. password length restriction. Removed some code that (poorly) tries to cope with a broken database. Removed pointless '-3' and '-2' account states ('dynamic ban' mechanism), since `ipbanlist` does that already. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11250 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-20Synced some more :)ultramage1-100/+98
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11249 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-20Partially applied r10021 changes to TXT login server (login_config data ↵ultramage2-55/+60
structure). Synced TXT and SQL login server code. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11248 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-20* Merged the tmpsql branch:FlavioJS3-697/+706
- Abstraction for the sql code (sql.c/h). - New configure script and makefiles. - Restored txt zeny logging code. (r10814) - Rewrote mapserver's sql code - itemdb, mobdb, mapreg, logs. (r10814) - Fixed a precedence issue (&& and ) in char_sql/char.c. (r10833) - Improved db reading code a bit for consistency. (r11077) - Added separate atcommand for mail deletion. (r11077) - Corrected a few messages that said "new" instead of "unread". (r11077) - Broadcast (*) messages now use "*" as the target's name (not ""). (r11077) - Moved StringBuf code from utils.c/h to strlib.c/h. (r11084 r11117) - Some misc login server cleanups (reformatting etc). (r11136) - Corrected/modified some header entries. (r11141 r11147 11148) - Adjusted VS project files. (r11147) - Adjusted the way the sql charserver does item saving. (r11192) - Corrected usage of reserved keyword 'friend' in mmo.h. (r11192) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11245 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-09-13Wiped out every mention of RETCODE from /src.ultramage1-9/+9
The servers no longer save data using CRCRLF as line terminator on Windows. Closes bugreport:45. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@11187 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-08-10- added proper comments to login packet 0x277ultramage1-3/+3
- added a missing \n to one login server warning - silenced one "dc[4] might be uninitialized" warning - fixed an apparently wrong abra_db.txt entry (venom splasher: 40000) - removed .gat from the remaining npcs git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10974 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-08-06* Added a null-pointer check to skill_initunit() to prevent a crashultramage1-5/+8
* Added a while() loop to the client packet processor (for performance) * Added support for kRO 2007-05-14aSakexe langtype 0 login packet 0x2b0 * Added Job_Baby_Alchemist define to complement the Job_Alchemist update * Added custom Hollow Poring mob_db2 entry git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10954 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-07-20* Corrected packet_db.txt. See topic:158382 for details. As a side-effect, ↵ultramage1-1/+1
the latest packet version is now 22 instead of 21. * Added a charserver config option for the character renaming flag, along with a detailed comment on what it's supposed to be. This eliminates all that "change PACKETVER to 8 and recompile" mess. * Moved PACKETVER back to clif.h, cleaned the related code a bit. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10888 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-07-01Cleaned up some parts of the code.ultramage1-4/+3
Removed obsolete script function 'hasitems'. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10838 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-06-23random fixingultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10808 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-06-01Some typo fixing / cleaningultramage1-3/+3
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10658 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-25Corrected some weird fgets() statements, plus reformatted themultramage1-5/+4
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10616 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-23- Added new flag to skill_castnodex.txt, to allow per-skill tweaking of cast ↵ultramage1-1/+1
time and delay reducibility by item scripts (cards and such) - Fixed Martyr's Reckoning never triggering for gms with all skills - Added MO_TRIPLEATTACK and RG_SNATCHER to @skillall's skill filter - Made gm_skill_unconditional bypass skill blocking (guild timer, etc) - Reverted the weird delay_dependon_agi thing (r8923, r9055, r9059) - Changed a few memsets to strncpy (reading past buffer is a bad idea) - Sped up some memset operations (multiples of 4 are faster) git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10613 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-21- Removed the TURBO socket mechanism - it was in fact just using a variable ↵ultramage2-165/+171
to cache a few arithmetic operations (premature optimization) - Since the fifohead mess is gone, fixed leftover bad code structuring git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10599 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-09* Added Buuyo-Tama's shortlist for send/eof sockets (defined out for now). FlavioJS1-13/+13
* Replaced toupper/tolower in ladmin by TOUPPER/TOLOWER defines. Shortlist: It's a list of sockets that have data to send and/or are ready for eof processing. It aims to reduce the amount of time spent on do_sendrecv, where it was spending ~13.5% of execution time on a server with 1k users at WoE. thanks to Buuyo-tama for the profile info and code git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10506 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-06Added a check to login_sql against too long db-stored emails.ultramage1-1/+1
By the way, the length should most likely be 40+1, not 39+1 (underdimensioned)... git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10492 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-05* Removed the dependency on winsock.h for definitions, it's all winsock2.h now.FlavioJS1-0/+3
* Minor documentation/re-coding in chat.c. * More work on ticket #41. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10471 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-05-05- imported the latest working grfio code from stableultramage1-1/+1
- re-added usage of managed allocation routines in grfio - eol-styled some new files - some cosmetic fixes here and there git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10468 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-28Fixed login_sql ipbans not working (due to signed/unsigned mismatch)ultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10390 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-28'minor' detailsultramage1-1/+1
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10389 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-28* Tried and fixed md5 password encryptionultramage2-151/+130
- login_sql was doing stupid things like re-using one pre-generated key for all connections, and escaping binary md5 data (destroying it) - added missing code to login_txt when creating new accounts, showing that storing passwords as md5 hashes never really worked for txt - removed PASSWORDENC's conditional compilation effect, now just a flag - greatly simplified md5 password checking code, credits to eapp * login server will now bind only after finishing the init phase git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10384 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-20- Added ntows() to properly handle that client port number deficiencyultramage1-2/+2
- Adjusted the packet_db array for a more consistent look - Reorganized some entries in packet_db.txt - Fixed a small scripts_custom.conf typo git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10296 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-17Changed some %lu to %u in login_sql/login.c because uint32 is now an ↵toms1-6/+6
unsigned int git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10276 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-17* Discarded extra deflate function needed for afm readingultramage1-2/+1
- as a result, discarded the whole chain of support functions, .c files and includes needed to make that one function run - also removed zlib compile/link dependencies where they are not needed - reduced the whole zlib package into two core include files - adjusted makefiles / project files to reflect this change git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10273 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-16* Finally fixed mingw problems, managed to build both TXT and SQLultramage1-9/+9
* Fixed the uint32 platform problem (Microsoft failed so I removed it :) * Removed the cbasetypes.h dependency from the mapcache generator * Removed some random compilation warnings git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10270 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-09* Played around with MinGW a bit today...ultramage1-6/+6
- adjusted code so that it handles mingw-specific compatibility problems - adjusted the makefile, mingw is not a subset of cygwin * As an experiment Corrected many /W4 warnings on the txt login server git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10192 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-07- Added function str2ip() to do platform-safe conversionsultramage1-3/+3
- Removed a bunch of unused stuff - Moved SIGILL to unix-only defines since tests and docs show that Windows doesn't issue SIGILL - Fixed several annoying compilation warnings git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10177 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-07- Moved e_mail_check() and config_switch() to strlib.hultramage2-117/+62
- Synchronized the login servers a bit git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10174 54d463be-8e91-2dee-dedb-b68131a5f0ec
2007-04-06- Corrected Aliza card's item_db line.skotlex1-6/+6
- Capped clif_heal's heal field (the argument received is int, but the packet field is short, meaning that if the heal is high enough, the client would receive a negative heal amount). - Some indentation fixes. git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@10165 54d463be-8e91-2dee-dedb-b68131a5f0ec