gamax92 3 Posted September 29, 2014 Share Posted September 29, 2014 Description:What OCNetFS allows you to do is mount a folder from an actual server over the internet, as a filesystem component.Server implementations:There are two server implementations so far:Love2D Server: Features the sandbox and love.filesystem api from Love2D, but conf.lua/main.lua will be listed, and cannot specify which folder to host.All required libraries are included.LuaFilesystem Server: Uses an experimental/bad sandbox, and lfs isn't too great, but can run in places without Xorg, and the folder to use is the working directory.Its easy to change the folder, by setting "currentdir" in sanitizePath to a specific location.Configuration:By default it tries to listen to port 14948, but if that fails it allocates a random port.The starting label and ability to modify are listed near the top of the file, as label and change respectivelyThe port itself is in socket.bind, which is still not too far away from the config section.totalspace cannot really be calculated, and modifying it doesn't actually limit, so its just a visual thing.Limitation:ocnetfs does basic argument type checks, but doesn't validate specifics such as (attempting to open a file under mode "apple")Both server unserialize using a custom unserializer to prevent the server from executing error, but the unserializer isn't very robust and may not always be correct. For what OC's serializer produces, it should be validDownloads:If you use oppm, ocnetfs is available from thereElse, it and the server programs can be downloaded from here Quote Link to post Share on other sites
gamax92 3 Posted October 2, 2014 Author Share Posted October 2, 2014 Both servers are now capable of supporting multiple clients! Also improved the security in ocnetfs, where only math.huge is available to the unserializer, and it checks if it compiled. Quote Link to post Share on other sites
scj643 0 Posted December 9, 2014 Share Posted December 9, 2014 One Question: How do I set it up on the host. Quote Link to post Share on other sites
BrisingrAerowing 12 Posted March 15, 2017 Share Posted March 15, 2017 @gamax92 What about using Lua-PhysFS as a backend for a server? I may try to write my own server for this using that. Quote Link to post Share on other sites
BrisingrAerowing 12 Posted March 15, 2017 Share Posted March 15, 2017 I actually was able to get a PhysFS based server working correctly! It can be obtained from my Programs Repository. Quote Link to post Share on other sites
gamax92 3 Posted March 21, 2017 Author Share Posted March 21, 2017 Nice job! Would it be possible for me to include this server in my repo? (with complete credit to you of course) Quote Link to post Share on other sites
BrisingrAerowing 12 Posted March 24, 2017 Share Posted March 24, 2017 @gamax92 Certainly! Go ahead! EDIT: I'm going to update it to allow for mounting multiple paths, which is what PhysFS is designed for. EDIT2: Should be good now. Quote Link to post Share on other sites