Learath
28905c4659
Disable timeout for 0.7 clients
2020-06-20 19:52:23 +03:00
Learath
6db72b2388
Times are no longer negative in 0.7
2020-06-20 11:59:46 +03:00
Learath
91c44f1808
Sixup needs it's own maps
2020-06-20 01:00:45 +03:00
bors[bot]
5b4227fbba
Merge #2283
...
2283: teehistorian: Track whether clients join via the 0.7 protocol r=Learath2 a=heinrich5991
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2020-06-19 20:31:40 +00:00
heinrich5991
e294da41ba
teehistorian: Track whether clients join via the 0.7 protocol
2020-06-19 22:06:39 +02:00
Learath
da68923ac3
Implement a switch for 0.7 compatibility
2020-06-19 22:08:41 +03:00
Learath
aeb7ea2971
Don't forget that the client is Sixup
2020-06-19 20:28:55 +03:00
Learath
70ecf785bb
Compatible version filter
2020-06-19 20:28:55 +03:00
Learath
9f71478099
Get Rcon working
2020-06-19 20:28:55 +03:00
Learath
88ca573682
Serverinfo and Register support for 0.7
...
Co-authored-by: Tim Schumacher <tim@timakro.de>
2020-06-19 20:28:55 +03:00
Learath
9e2434c65d
Better skin colors. Better game message translation
2020-06-19 20:28:55 +03:00
Learath
9dc1a0357a
Get /spec working
2020-06-19 20:28:55 +03:00
Learath
03070d0567
Fix many issues
2020-06-19 20:28:52 +03:00
Learath
807c92f1a4
Generate the 0.7 protocol
2020-06-19 20:27:15 +03:00
Learath
f7e9df7abf
Move the rest of the translation to CServer
2020-06-19 20:27:15 +03:00
Learath
b0e5a37fa9
Do message translation differently
2020-06-19 20:27:15 +03:00
Learath
5000b248bb
Fix things
2020-06-19 20:27:15 +03:00
Tim Schumacher
442148a194
Begin work on 0.7 support
2020-06-19 20:27:15 +03:00
bors[bot]
6f8f606e05
Merge #2276
...
2276: Fix segmentation fault when creating sql tables failed r=heinrich5991 a=Zwelf
`GameServer()->OnShutdown(true);` (which would wait on running threads to exit)
wasn't called if an error occured in the server init. Therefore `CServer` was
freed before the init-thread finished executing, causing a use after free from
`CSqlConnector::ms_ppSqlReadServers` pointing to `CServer->m_apSqlReadServers`.
Fixes #2271
Note that the server exits when creating tables failed. Since the tables are created by default, it has to be disabled explicitly (e.g. `add_sqlserver r teeworlds record teeworlds PASSWORD "localhost" 3306 0`) if the servers should start even when the database connection fails.
Co-authored-by: Zwelf <zwelf@strct.cc>
2020-06-18 19:23:00 +00:00
Zwelf
f5ac6eea56
Fix segmentation fault when creating sql tables failed
...
`GameServer()->OnShutdown(true);` (which would wait on running threads to exit)
wasn't called if an error occured in the server init. Therefore `CServer` was
freed before the init-thread finished executing, causing a use after free from
`CSqlConnector::ms_ppSqlReadServers` pointing to `CServer->m_apSqlReadServers`.
2020-06-18 21:11:36 +02:00
def
882185e299
Make SaveID DEFAULT NULL
2020-06-18 10:32:58 +02:00
Zwelf
f1b2ff086c
Clean up thread safe SQL refactor
2020-06-17 21:15:07 +02:00
Zwelf
ea31171873
Generate passphrase for save-code
...
* when none is given
* if the given save-code already exist
* if the database connection fails therefore it can't be checked if the save-code already exists
Using the short word list from eff:
https://www.eff.org/deeplinks/2016/07/new-wordlists-random-passphrases
2020-06-15 11:14:15 +02:00
Zwelf
528ca377ed
Thread safe saving of team score
2020-06-15 11:14:15 +02:00
Zwelf
62d56ca8e8
Make database init with create tables synchronous
...
Note: database init without creating tables behaves the same
2020-06-15 11:14:15 +02:00
Zwelf
031ac52320
Thread safe /save
2020-06-15 11:14:15 +02:00
Zwelf
4152a1995e
Add missing dependeny to sql string helper
2020-06-15 11:14:15 +02:00
bors[bot]
92fc95d742
Merge #2202
...
2202: Send DDNet version early in the connection process r=Learath2 a=heinrich5991
This gets rid of the problem that we don't know whether we should send
full snapshots to clients because they haven't told us about them being
DDNet yet.
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2020-05-27 17:49:31 +00:00
heinrich5991
f339fea748
Merge pull request #2139 from edg-l/pr_add_upnp
...
Add UPnP support
2020-05-24 22:23:20 +02:00
Edgar
3569e174f2
refactor upnp code
2020-05-24 11:36:43 +02:00
heinrich5991
0d7872c79e
Send DDNet version early in the connection process
...
This gets rid of the problem that we don't know whether we should send
full snapshots to clients because they haven't told us about them being
DDNet yet.
2020-05-22 17:58:41 +02:00
Learath
850e4e84e4
Reserve bytes for the type and token
2020-05-18 21:13:15 +03:00
Learath
788fc8bb5f
Update can happen when the gameserver doesn't exist
2020-05-18 16:17:06 +03:00
Learath
1426392ae7
Don't Destroy if we didn't Init
2020-05-16 23:10:42 +03:00
heinrich5991
457c4db964
Some antibot fixes
2020-05-16 00:39:17 +02:00
Learath
eacc56059b
Keep ticks going
2020-05-15 19:29:34 +03:00
Learath
5e02bb5a23
Extend antibot interface
...
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2020-05-13 23:39:40 +03:00
Ryozuki
b647c1e978
Add UPnP support
2020-04-14 12:11:50 +02:00
bors[bot]
7a3ebd5948
Merge #2041
...
2041: Strip spaces in browser (server name) r=heinrich5991 a=ChillerDragon
before:
![image](https://user-images.githubusercontent.com/20344300/72688976-b45f1d00-3b0c-11ea-8920-5328c6d721f7.png )
after:
![image](https://user-images.githubusercontent.com/20344300/72688970-9db8c600-3b0c-11ea-8636-330218d75ca1.png )
Co-authored-by: KillaBilla <robomastermail@googlemail.com>
Co-authored-by: heinrich5991 <heinrich5991@gmail.com>
2020-01-25 12:45:36 +00:00
bors[bot]
749929431a
Merge #2040
...
2040: fixed faulty message id r=heinrich5991 a=ChillerDragon
(cherry picked from commit 9023796d27
)
Co-authored-by: oy <Tom_Adams@web.de>
2020-01-25 12:40:14 +00:00
12pm
ec42291756
Allow filtering by name in status
...
Easier to find players when the server is full
2020-01-24 14:44:54 +01:00
KillaBilla
ba1abac52f
remove leading and trailing space from server name and forbit the use of multiple spaces
...
(cherry picked from commit a9cc1e8de2
)
2020-01-19 22:28:19 +01:00
oy
1b4131a7fd
fixed faulty message id
...
(cherry picked from commit 9023796d27
)
2020-01-19 21:30:12 +01:00
Learath
d2fad6c79a
Fix demo bug
2020-01-03 12:13:40 +03:00
ChillerDragon
4a6a85124a
Remove some unused includes
2019-12-14 10:20:42 +01:00
def
18e2232727
Add support to tell DDNet7 ranks apart from DDNet ones
...
Saves should not be loadable from one to the other.
Requires:
ALTER TABLE record_race ADD COLUMN DDNet7 BOOL DEFAULT FALSE AFTER GameID;
ALTER TABLE record_teamrace ADD COLUMN DDNet7 BOOL DEFAULT FALSE AFTER GameID;
ALTER TABLE record_saves ADD COLUMN DDNet7 BOOL DEFAULT FALSE AFTER Server;
2019-12-08 16:04:49 +01:00
Dennis Felsing
785ec3d345
Expire server info on connected/drop events
2019-11-04 15:45:55 +01:00
Learath2
c2bcd3bd4d
Fix bug
2019-11-04 01:06:52 +01:00
bors[bot]
0de012572b
Merge #1955
...
1955: Cache serverinfo responses r=def- a=Learath2
I'm not sure I like it but it works
Co-authored-by: Learath2 <learath2@gmail.com>
2019-11-03 20:09:21 +00:00
Learath2
c0b0f48d16
Oops
2019-11-03 20:58:35 +01:00
def
fdaafea6b5
Also init m_aClients[*].m_Latency
...
as reported by valgrind --tool=memcheck:
==376722== Conditional jump or move depends on uninitialised value(s)
==376722== at 0x1CDBDB: int maximum<int>(int, int) (math.h:79)
==376722== by 0x216A46: CPlayer::Tick() (player.cpp:174)
==376722== by 0x1FB308: CGameContext::OnTick() (gamecontext.cpp:658)
==376722== by 0x1C60AF: CServer::Run() (server.cpp:2046)
==376722== by 0x1CB099: main (server.cpp:3040)
==376722==
==376722== Conditional jump or move depends on uninitialised value(s)
==376722== at 0x183F27: int minimum<int>(int, int) (math.h:77)
==376722== by 0x216A65: CPlayer::Tick() (player.cpp:175)
==376722== by 0x1FB308: CGameContext::OnTick() (gamecontext.cpp:658)
==376722== by 0x1C60AF: CServer::Run() (server.cpp:2046)
==376722== by 0x1CB099: main (server.cpp:3040)
2019-11-03 18:54:25 +01:00
Learath2
c4d18118c1
Use automatic storage for the data
2019-11-03 18:31:05 +01:00
Learath2
52cca29cd9
Use a std::list, improve variable naming
2019-11-03 15:39:32 +01:00
Learath2
3d495a9936
Initialize variables
2019-11-03 01:53:50 +01:00
Learath2
79e4651d5b
Only update serverinfo when needed
2019-11-03 01:07:10 +01:00
Learath2
7f0589bff7
Cache serverinfo responses
2019-11-03 00:33:30 +01:00
def
cb738ffed0
Fix show_ips to show regular formatting ( fixes #1873 )
2019-08-01 20:24:30 +02:00
Learath
0bc3650356
Send DDNet capability flag
2019-07-29 14:18:40 +03:00
12pm
c57fcf3ee7
Persist playerflags when using timeout protection
2019-07-26 01:39:53 +02:00
Emir Marincic
57197d990c
Better represent the state of the server
...
Co-Authored-By: heinrich5991 <heinrich5991@gmx.de>
2019-07-20 21:25:15 +03:00
Learath
1769e5ae71
Don't advertise the reserved slots. Fix #1808
2019-07-18 18:20:55 +03:00
bors[bot]
bbcf7a6905
Merge #1815
...
1815: Return error codes on server fail r=def- a=ChillerDragon
Co-authored-by: ChillerDragon <chillerdragon@gmail.com>
2019-07-11 09:25:59 +00:00
ChillerDragon
b9273a9ed2
Return error codes on server fail
2019-07-11 11:18:25 +02:00
ChillerDragon
6172a9dca0
Use the float type explicitly
2019-07-08 23:08:42 +02:00
heinrich5991
62846821da
Revert "Implement ISDDNET. Deprecates #1320 "
...
This reverts commit 1929bc6739
.
2019-06-14 00:28:59 +02:00
heinrich5991
f31e081bd4
Remove all checking for the gametype in the game
...
OK, maybe not actually remove because it is kept for fallback when the
new method isn't available.
The whole gametype parsing business had the same downsides as user agent
parsing on the web, hence I removed it while keeping behavior the same.
This allows servers to explicitly opt in or out of certain bug
workarounds and other client behavior. This increases the complexity of
different configurations that are available in the client (which is a
bad thing).
2019-06-14 00:28:59 +02:00
def
85bb376bdc
sv_server_info_per_second, sv_van_conn_per_second: allow 0 to disable
...
Clean up code a bit, also allow larger values
2019-06-11 18:12:43 +02:00
Learath
1929bc6739
Implement ISDDNET. Deprecates #1320
2019-05-21 10:25:15 +02:00
bors[bot]
9bca330a73
Merge #1691
...
1691: Persist show_ips setting on map changes r=Learath2 a=def-
@12pm
Co-authored-by: def <dennis@felsin9.de>
2019-05-01 12:08:13 +00:00
ChillerDragon
7a7caabbec
Fix inconsistant uppercase server in logs
2019-04-30 09:03:06 +02:00
def
a910d9eff7
Persist show_ips setting on map changes
2019-04-29 21:39:17 +02:00
Dennis Felsing
cde07b420b
Implement changes suggested by -Wuseless-cast
...
But don't enable it yet because I'm not sure what the best way is.
2019-04-11 19:54:43 +02:00
def
ea093f6d39
2 more tries to force DB to respond in UTF8 ( fixes #1599 )
2019-04-08 16:55:53 +02:00
def
25c54ef4db
Implement show_ips to protect accidental leaking of IPs
...
Marks all sensitive data with <{ }> and then filters that out when
show_ips is not set.
2019-04-06 19:22:02 +02:00
heinrich5991
e44b1ca986
Use OpenSSL md5 if it is available
...
Fixes #1582 .
2019-04-06 02:56:29 +02:00
12pm
a7ef921e3f
Add playerflags, dnsbl, and ips for non-admins in status
2019-04-03 15:07:05 +02:00
Dennis Felsing
8b68a2859a
Merge pull request #1509 from ddnet/error-checking
...
More error checking in system.c (fixes #1317 )
2019-03-20 07:44:12 +01:00
def
1e4890c499
More error checking in system.c ( fixes #1317 )
2019-03-19 23:16:29 +01:00
12pm
9f4f06e995
Make updating nameban reason work
2019-03-19 22:54:16 +01:00
def
6f9cfd5af1
Increase MAX_PATH_LENGTH to support our own downloadedmaps names
2019-03-12 18:43:03 +01:00
Dennis Felsing
b8c256b602
Merge pull request #1467 from 12pm/nameban_exact
...
Add exact name ban option
2019-03-11 22:50:39 +01:00
12pm
3dcb83778f
Make name more descriptive
2019-03-11 14:48:45 +01:00
bors[bot]
26dc51a272
Merge #1466
...
1466: Add colors for authed players. Deprecates #1299 r=def- a=Learath2
Not sure if a snap item is the best idea for this but it should help with not sending the data more then needed and keeping it properly updated. The colors aren't great now but we can fix that easily.
![image](https://user-images.githubusercontent.com/490500/53680889-607bf780-3cf2-11e9-84a0-579160e9e170.png )
Co-authored-by: Learath <learath2@gmail.com>
2019-03-06 13:44:28 +00:00
def
deb2494692
Don't suggest to downgrade, clean up versioning ( fixes #1440 )
2019-03-03 20:31:23 +01:00
12pm
29592afdb5
Add exact name ban option
2019-03-03 18:29:33 +01:00
Learath
548e9969b2
Add colors for authed players. Deprecates #1299
2019-03-02 13:50:33 +03:00
def
65ce202697
Revert "More SQL fixes"
...
This reverts commit c665cabc27
.
2019-02-28 06:14:30 +01:00
def
f831f27d08
Revert "New SQL locking on each query ( fixes #1430 )"
...
This reverts commit 5ddcf8bd0c
.
2019-02-28 06:14:20 +01:00
Dennis Felsing
6701ae726f
Merge pull request #1434 from ddnet/sql-locking
...
Sql locking
2019-02-27 20:26:24 +01:00
Dennis Felsing
6f3d261b73
Merge pull request #1441 from trml/pr_sync_weapon_input
...
Sync weapon input with other input
2019-02-14 10:27:52 +01:00
ChillerDragon
3f8e9613f7
Fix style
2019-02-06 13:06:28 +01:00
ChillerDragon
03a20d6406
Add IServer::Ban
2019-02-04 23:09:14 +01:00
trml
3f9d30af0f
Sync weapon input with other inputs
2019-01-29 20:58:25 +01:00
def
5ddcf8bd0c
New SQL locking on each query ( fixes #1430 )
2019-01-14 22:28:13 +01:00
Dennis Felsing
c665cabc27
More SQL fixes
...
Should help with some crashes
Still doesn't call thread_init
Still shares statements and connections between threads
2019-01-14 22:18:37 +01:00
def
b1ef2bf864
Don't try to remove non-existing files
...
Causes annoying error messages during map change & server start.
2019-01-14 22:13:51 +01:00
fokkonaut
fe4426b008
fixed ddrace score (time score)
2019-01-14 08:01:20 +01:00
fokkonaut
0e842359ad
Add DDRace Score NETMSG
2019-01-14 08:01:20 +01:00
def
da2fe3cbbc
Revert "More SQL fixes"
...
This reverts commit a58ade137d
.
2019-01-06 10:59:29 +01:00
Dennis Felsing
a58ade137d
More SQL fixes
...
Should help with some crashes
Still doesn't call thread_init
Still shares statements and connections between threads
2018-12-27 14:31:58 +01:00