summaryrefslogtreecommitdiff
path: root/src/network
Commit message (Collapse)AuthorAge
* Mitigate formspec exploits by verifying that the formspec was shown to the ↵red-0012018-02-18
| | | | | user by the server. (#6878) This doesn't check the fields in anyway whatsoever so it should only be seen as a way to mitigate exploits, a last line of defense to make it harder to exploit bugs in mods, not as a reason to not do all the usually checks.
* Remove legacy chat network code. (#6954)red-0012018-02-17
|
* Add `on_auth_fail` callback (#7039)red-0012018-02-15
| | | Called when a client fails to supply the correct password for the account it's attempting to login as.
* Fix issues with earlier CSM HUD commit (#6940)red-0012018-01-26
| | | The CSM HUD PR caused some strange behavior including aborts due to parts of it using some slightly hacky code, the event refactor changing how events are processed and a minor oversight.
* [CSM] Add functions to create particles and particlespawners. (#6072)red-0012018-01-20
|
* [CSM] Add basic HUD manipulation. (#6067)red-0012018-01-20
| | | | | | * [CSM] Add basic HUD manipulation. Workaround for on_connect not working right now.
* Add confirmation on new player registration (#6849)Muhammad Rifqi Priyo Susanto2018-01-13
| | | | | | | | | | | | | | * Attempt to add registration confirmation Using SRP auth mechanism, if server sent AUTH_MECHANISM_FIRST_SRP that means the player isn't exist. Also tell player about the server and chosen username. Local game has localhost as IP address of the server. Add RenderingEngine::draw_menu_scene() to draw GUI and clouds background. aborted -> connection_aborted * Rewrite information message text Client::promptConfirmRegister() -> Client::promptConfirmRegistration()
* Connected Nodeboxes: Add `disconnected` boxesThomas--S2018-01-03
| | | | | | | | | | | | | | | The `disconnected_*` boxes are the opposites of the `connect_*` ones, i.e. when a node has no suitable neighbours on the respective side, the according disconnected box is drawn. * disconnected_top * disconnected_bottom * disconnected_front * disconnected_left * disconnected_back * disconnected_right * disconnected (when there is *no* neighbour) * disconnected_sides (when there are *no* neighbours to the sides)
* Fix undefined behaviour on getting pointer to data in empty vectornOOb31672017-12-22
| | | | `&vector[0]` is undefined if vector.empty(), causing build failure on MSVC
* CSM fixes: load mods after flavours & add flavour to block mod loading (#6738)Loïc Blot2017-12-11
| | | | | | | | | | | | | | * CSM fixes: load mods after flavours & add flavour to block mod loading * Don't permit to load mods twice * Prepare builtin integrity global algorithm * Add missing doc & use a nicer byteflag for LOAD_CLIENT_MODS flavour * flag typo fix * Invert CSM_FL_LOOKUP_NODES & CSM_FL_LOAD_CLIENT_MODS ids
* Damage: Remove damage ignore timerSmallJoker2017-12-10
|
* Zoom: Set zoom FOV per-player using a player object propertyparamat2017-12-04
| | | | | | | | | | | | | Remove player object property 'can zoom'. Add player object property 'zoom fov'. Remove clientside setting for 'zoom fov'. Object property default is 15 degrees in creative mode, zoom disabled in survival mode. Needed due to zoom now loading and/or generating distant world according to zoom FOV. Update object properties serialisation version to 3.
* Inventory: Restrict access from too far awaySmallJoker2017-11-24
|
* Move files to subdirectories (#6599)Vitaliy2017-11-08
| | | | * Move files around
* Initial Haiku support (#6568)miqlas2017-10-30
| | | | * Iitial Haiku support
* Allow overriding tool capabilities through itemstack metadataraymoo2017-10-29
| | | | | This makes it possible to modify the tool capabilities of individual itemstacks by calling a method on itemstack metadata references.
* Fix strict_protocol_version_checking functionality after ee9a442SmallJoker2017-10-16
|
* Real global textures (#6105)Vitaliy2017-10-15
| | | | | | | | * Real global textures * Add world-aligned textures * Update minimal to support world-aligned tiles * Update minimal
* NetworkPacket::putRawPacket: resize m_data to datasize + memcpyLoic Blot2017-10-10
| | | | | | In some cases NetworkPacket was created using default constructor and m_data is not properly sized. This fixed out of bounds memory copy Also use memcpy instead of std::vector affectation to enhance packet creation
* Travis: Update clang from 4.0 to 5.0 (#6467)Loïc Blot2017-10-09
| | | | * Update clang from 4.0 to 5.0
* Lint fixLoic Blot2017-09-27
|
* Add session_t typedef + remove unused functions (#6470)Loïc Blot2017-09-27
| | | | | | * Add session_t typedef + remove unused functions u16 peer_id is used everywhere, to be more consistent and permit some evolutions on this type in the future (i'm working on a PoC), uniformize u16 peer_id to SessionId peer_id
* Implement mod communication channels (#6351)Loïc Blot2017-09-26
| | | | | | | | | | Implement network communication for channels * Implement ModChannel manager server side to route incoming messages from clients to other clients * Add signal handler switch on client & ModChannelMgr on client to handle channels * Add Lua API bindings + client packet sending + unittests * Implement server message sending * Add callback from received message handler to Lua API using registration method
* Fix compile error in openbsd (#6430)jcalve2017-09-20
| | | Include the header that defines AF_INET and AF_INET6
* ServerEnv: Clean up object lifecycle handling (#6414)sfan52017-09-15
| | | | * ServerEnv: Clean up object lifecycle handling
* Object properties: Add 'glow', disables light's effect if negativeRob Blanckaert2017-09-14
| | | | | | The 'glow' value is added to the ambient light value. Negative 'glow' disables light's effect on object colour, for faking self-lighting, UI-style entities, or programmatic colouring in mods.
* Network: Fix logging into older worlds with base64 hashesSmallJoker2017-09-12
|
* Network: Remove large parts of deprecated legacy code (#6404)SmallJoker2017-09-12
| | | | Also remove the setting 'send_pre_v25_init' Keep old enum entries for obsolete commands
* Fix failing linter (travis)sfan52017-09-12
|
* Use a Buffer instead of SharedBuffer in ConnectionCommandLoic Blot2017-09-05
| | | | This fixes #6373
* Network protocol documentation: Add 'can_zoom' to version 36paramat2017-09-05
|
* Implement minetest.register_can_bypass_userlimit (#6369)Loïc Blot2017-09-04
| | | | | | | | | * Implement minetest.register_on_userlimit_check This new callback permits to bypass the max_users parameter with new mods condition, based on player name or IP Only one mod needs to permit it. Move core part for builtin privileges checks to builtin
* Re-apply previous commit with a typo fixLoïc Blot2017-09-04
|
* Revert "Network: fix a concurrency problem, by re-adding a copy in ↵Loïc Blot2017-09-04
| | | | | | ConnectionCommand" This reverts commit 5b04f5e7d231437b534f4cad39da78624d97c584.
* Network: fix a concurrency problem, by re-adding a copy in ConnectionCommandLoïc Blot2017-09-04
|
* Network part requires SharedBuffers to be pass as valueLoic Blot2017-09-03
| | | | | | This can trigger unreproductible crashes due to concurrency problem on SharedBuffers This fixes #6354
* Network proto handlers/container fixes (#6334)Loïc Blot2017-08-29
| | | | | | | | | | * Fix HP transport + some double <-> float problems TOCLIENT_HP transport u16 hp as a u8, use u16 HP, this prevent HP over 255 to overflow across network * Fix more double/float problem in serverpackethandler & remove implicit struct type for TileAnimationParams * Fix connection unittests container
* Bump minimal protocol version to 36 (#6319)SmallJoker2017-08-29
| | | | | | | * Bump minimal protocol version to 36 Item/Node/TileDef, NodeBox, TileAnimation: Remove old compat code * Accept future serialisation versions
* Clientevent refactor (#6320)Loïc Blot2017-08-28
| | | | | | | | | | * Refactor clientevent structure * Move structure outside of client header * Create client events on heap not stack, this remove the ClientEvent object copy * Use clientEventHandler to route events
* Pass SharedBuffer as value to increment reference countLoïc Blot2017-08-28
| | | | | This should fix #6332 Refcount is not increased due to reference, it can make this refcount incorrect in a multithread context
* Network cleanup (#6310)Loïc Blot2017-08-25
| | | | | | | | | | | | | | * Move Connection threads to dedicated files + various cleanups * ConnectionReceiveThread::processPacket now uses function pointer table to route MT packet types * Various code style fixes * Code style with clang-format * Various SharedBuffer copy removal * SharedBuffer cannot be copied anymore using Buffer * Fix many SharedBuffer copy (thanks to delete operator)
* Add clientside translations.Ekdohibs2017-08-24
|
* Network cleanup (#6302)Loïc Blot2017-08-24
| | | | | | | | | | | | | | | | | | | | | | | * Cleanup network headers * Move peerhandler to a specific header to reduce compilation times * Move socket.cpp/h to network folder * More work * Network code cleanups * Move socket.{cpp,h} to network folder * Move Address object to network/address.{cpp,h} * Move network exceptions to network/networkexceptions.h * Client: use unique_ptr for Connection * Server/ClientIface: use shared_ptr for Connection * Format fixes * Remove socket.cpp socket.h from clang-format whitelist * Also fix NetworkPacket code style & make it under clang-format
* Fix OSX builds (closes #6289, fixes #6270) (#6306)Pavel Puchkin2017-08-24
| | | | Of course, this is not ideal solution, but we want our users to be happy in the first place, right?
* Minimap: Add new HUD flag for minimap radar modeparamat2017-08-20
| | | | | Flag default is true to not change default behaviour. The existing minimap HUD flag remains the master control for minimap.
* Modernize source code: last part (#6285)Loïc Blot2017-08-20
| | | | | | | | | | | * Modernize source code: last par * Use empty when needed * Use emplace_back instead of push_back when needed * For range-based loops * Initializers fixes * constructors, destructors default * c++ C stl includes
* Code modernization: subfolders (#6283)Loïc Blot2017-08-19
| | | | | | | | | | | | | * Code modernization: subfolders Modernize various code on subfolders client, network, script, threading, unittests, util * empty function * default constructor/destructor * for range-based loops * use emplace_back instead of push_back * C++ STL header style * Make connection.cpp readable in a pointed place + typo
* Optimize headers (part 2) (#6272)Loïc Blot2017-08-18
| | | | | | | | | | | | | | * Optimize headers (part 2) * less debug.h in headers * less remoteplayer.h for everybody * Cleanup (part 2) * camera.h: mesh.h * mapgen.h: mapnode.h * serverenvironment.h: mapblock.h * nodedef.h: shader.h
* Add missing ctime include (#6269)adrido2017-08-18
|
* C++ modernize: Pragma once (#6264)Loïc Blot2017-08-17
| | | | * Migrate cpp headers to pragma once