mirror of
https://github.com/YGGverse/titanit.git
synced 2026-03-31 17:15:30 +00:00
initial commit
This commit is contained in:
parent
c6f6ec7ba4
commit
86e07f08c7
7 changed files with 408 additions and 0 deletions
49
README.md
49
README.md
|
|
@ -1,2 +1,51 @@
|
|||
# titanit
|
||||
|
||||

|
||||
[](https://deps.rs/repo/github/YGGverse/titanit)
|
||||
[](https://crates.io/crates/titanit)
|
||||
|
||||
File share server for Gemini & Titan protocols
|
||||
|
||||
> [!NOTE]
|
||||
>
|
||||
> Project in development!
|
||||
|
||||
## Install
|
||||
|
||||
``` bash
|
||||
cargo install titanit
|
||||
```
|
||||
|
||||
## Setup
|
||||
|
||||
### Generate PKCS (PFX)
|
||||
|
||||
``` bash
|
||||
openssl genpkey -algorithm RSA -out server.pem -pkeyopt rsa_keygen_bits:2048
|
||||
openssl req -new -key server.pem -out request.csr
|
||||
openssl x509 -req -in request.csr -signkey server.pem -out server.crt -days 365
|
||||
openssl pkcs12 -export -out server.pfx -inkey server.pem -in server.crt
|
||||
```
|
||||
|
||||
## Launch
|
||||
|
||||
### Arguments
|
||||
|
||||
* `--bind`, `-b` required, server `host:port` to listen incoming connections
|
||||
* `--identity`, `-i` required, filepath to server identity in PKCS (PFX) format
|
||||
* `--password`, `-p` optional, unlock encrypted `identity` by passphrase
|
||||
* `--size`, `-s` optional, max size limit in bytes (unlimited by default)
|
||||
* `--mime`, `-m` optional, uploads MIME type whitelist (comma separated, all by default)
|
||||
* `--directory`, `-d` optional, uploads target directory (`public` by default)
|
||||
* `--redirect`, `-r` optional, redirection URL on request handle complete (e.g. `gemini://localhost`)
|
||||
|
||||
### Start
|
||||
|
||||
``` bash
|
||||
titanit --bind 127.0.0.1:1965 \
|
||||
--identity path/to/server.pfx
|
||||
```
|
||||
|
||||
### titan it!
|
||||
|
||||
* `titan://127.0.0.1`
|
||||
Loading…
Add table
Add a link
Reference in a new issue