add a readme and MIT license
This commit is contained in:
parent
b624be932b
commit
abca20a12c
2 changed files with 59 additions and 0 deletions
21
LICENSE.txt
Normal file
21
LICENSE.txt
Normal file
|
@ -0,0 +1,21 @@
|
|||
MIT License
|
||||
|
||||
Copyright (c) 2023 Rasmus Moorats
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
in the Software without restriction, including without limitation the rights
|
||||
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
||||
copies of the Software, and to permit persons to whom the Software is
|
||||
furnished to do so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
38
README.txt
Normal file
38
README.txt
Normal file
|
@ -0,0 +1,38 @@
|
|||
open redirector
|
||||
|
||||
usage:
|
||||
|
||||
* /[url] - redirect to an URL
|
||||
* /?url=[url] - redirect to an URL
|
||||
* /base64 - redirect to a base64-encoded URL
|
||||
|
||||
Redirect to any location using the `Location` header.
|
||||
Supply the `code` query with a valid 3xx HTTP status
|
||||
code to use a specific one. Otherwise, `302 Found` is used
|
||||
|
||||
|
||||
examples:
|
||||
|
||||
* http://redir.ee/file:///etc/shadow
|
||||
- redirects to file:///etc/shadow
|
||||
|
||||
* http://redir.ee/?url=http://example.com
|
||||
- redirects to http://example.com
|
||||
|
||||
* http://redir.ee/base64?url=aHR0cDovL2V4YW1wbGUuY29t&code=303
|
||||
- redirects to http://example.com with HTTP code 303
|
||||
|
||||
|
||||
pre-defined shortcuts (`code` works here too):
|
||||
|
||||
* /metadata - http://169.254.169.254/latest/meta-data/
|
||||
* /metadata6 - http://[fd00:ec2::254]/latest/meta-data/
|
||||
* /localhost - http://127.0.0.1
|
||||
* /localhost6 - http://[::1]
|
||||
* /zeroes - http://0.0.0.0
|
||||
* /passwd - file:///etc/passwd
|
||||
* /services - file:///etc/services
|
||||
* /env - file:///proc/self/environ
|
||||
|
||||
|
||||
source code: https://git.dog/xx/redir
|
Loading…
Reference in a new issue