This is a simple implementation of SSCSM. How it works
Server mods register CSMs by calling minetest.register_csm(modname,code).
A client connects...
All registered CSMs are sent in order of registration (So if your mod depends on a mod, your mod's CSMs will be loaded after that mod's CSMs). They are sent through modchannel sscsm_<playername>, so no protocol changes are involved.
This zip file contains all changed files (from Minetest 5.1.0-dev). To apply the patch, just copy-paste contents of this archive's src dir to your src dir and re-compile Minetest.