Fix path security bug and added features
This commit is contained in:
@@ -5,25 +5,48 @@
|
||||
# License
|
||||
Starting with 1.0.3.9 this library will use GPL-3.0
|
||||
If you can not use GPL either use 1.0.3.8 or use another library
|
||||
<br>
|
||||
|
||||
A TcpListener HTTP Server
|
||||
|
||||
WARNING: use at least version 1.0.4.2 because of security issue with paths
|
||||
|
||||
To make your life easier, install [Tesses.WebServer.EasyServer](https://www.nuget.org/packages/Tesses.WebServer.EasyServer) alongside [Tesses.WebServer](https://www.nuget.org/packages/Tesses.WebServer) and use this code:
|
||||
|
||||
```csharp
|
||||
using Tesses.WebServer;
|
||||
using Tesses.WebServer.EasyServer;
|
||||
|
||||
...
|
||||
|
||||
StaticServer server=new StaticServer(""); //or any server
|
||||
|
||||
...
|
||||
|
||||
server.StartServer(9500); //or any port number
|
||||
//and it will print your ips to console with
|
||||
//the message Almost ready to Listen
|
||||
```
|
||||
|
||||
# Currently Supports
|
||||
- GET+HEAD+POST Requests
|
||||
- Seekable Video Files (Using Range)
|
||||
- Can Send Json To Client with helper function (uses Newtonsoft.Json)
|
||||
- Seekable Video Files (or any file) (Using Range)
|
||||
- Can Send/Receive Json To/From Client with helper functions (uses Newtonsoft.Json)
|
||||
- Cors Header
|
||||
- Chunked encoding
|
||||
- Tesses.IVirtualFileSystem support (Work in progress and buggy)
|
||||
- wii-linux-ngx using this copy of [mono](https://tesses.net/apps/tytd/2022/wii.php)
|
||||
|
||||
# Classes To Make It Easier
|
||||
- Static Website Class (Can pass in other class (instead of 404 when file doesnt exist) can choose other names other than index.html, index.htm, default.html, default.htm)
|
||||
- 404 Not Found Class
|
||||
- Mount class (So you could use Multiple Apis, And Static Sites If you want)
|
||||
- Basic Auth Class
|
||||
- Route Class (Just like dajuric/simple-http)
|
||||
- Host Name Class (like Mount Class but is used for hostnames/ip addresses like tesses.cf, 192.168.0.142, demilovato.com, ebay.com)
|
||||
- Route Class (Just like dajuric/simple-http, except it uses query parameters)
|
||||
- Host Name Class (like Mount Class but is used for hostnames/ip addresses like tesses.net, 192.168.0.142, demilovato.com, ebay.com, tessesstudios.com, godworldwide.org)
|
||||
- Path Value Class (can handle paths like this /user/Jehovah/files where Jehovah is the path element)
|
||||
|
||||
# Might Happen But not sure
|
||||
- WebDav Class
|
||||
- WebDav Class (and may be used in a seperate library)
|
||||
- Reverse Proxy (in a seperate library)
|
||||
|
||||
> Note: Range code, POST code and Route Class is not mine its a modified version of the code from ( [dajuric/simple-http](https://github.com/dajuric/simple-http/blob/master/Source/SimpleHTTP/Extensions/Response/ResponseExtensions.PartialStream.cs "dajuric/simple-http"))
|
||||
|
||||
Reference in New Issue
Block a user