diff --git a/Cargo.lock b/Cargo.lock index 9658db7..16b31cd 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -2581,7 +2581,7 @@ dependencies = [ [[package]] name = "rustpad" -version = "0.1.16" +version = "0.1.17" dependencies = [ "argon2", "aws-config", @@ -2597,6 +2597,7 @@ dependencies = [ "lettre", "mime_guess", "rand_core 0.6.4", + "rustls 0.23.42", "serde", "serde_json", "sha2 0.10.9", diff --git a/Cargo.toml b/Cargo.toml index db53c2d..96b8b48 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "rustpad" -version = "0.1.16" +version = "0.1.17" edition = "2024" rust-version = "1.94" description = "Collaborative Markdown notepad built with Axum, WebSockets and SQLite, PostgreSQL and MySQL" @@ -21,6 +21,7 @@ lettre = { version = "0.11", default-features = false, features = ["builder", "s ldap3 = { version = "0.12", default-features = false, features = ["tls-rustls-ring"] } sha2 = "0.10" rand_core = { version = "0.6", features = ["getrandom"] } +rustls = { version = "0.23", default-features = false, features = ["ring", "std"] } serde = { version = "1", features = ["derive"] } serde_json = "1" slug = "0.1.6" diff --git a/src/main.rs b/src/main.rs index 04a6c3a..ce6f1e5 100644 --- a/src/main.rs +++ b/src/main.rs @@ -23,6 +23,10 @@ use tracing_subscriber::{layer::SubscriberExt, util::SubscriberInitExt}; #[tokio::main] async fn main() -> Result<(), Box> { + rustls::crypto::ring::default_provider() + .install_default() + .map_err(|_| "failed to install rustls ring CryptoProvider")?; + dotenvy::dotenv().ok(); let cli = parse_command()?; init_tracing(); diff --git a/static/home.html b/static/home.html index d884962..37ce5d3 100644 --- a/static/home.html +++ b/static/home.html @@ -98,8 +98,8 @@
- +
@@ -127,17 +127,24 @@
-

Profile

Manage your local RustPad account.

+
+

Profile

+

Manage your local RustPad account.

+

- + - - - + + +
diff --git a/static/pad.html b/static/pad.html index 26f05b6..9a1ccfc 100644 --- a/static/pad.html +++ b/static/pad.html @@ -13,27 +13,30 @@
-
RustPad +
RustPad

__PAD_TITLE__

- + type="color" aria-label="Override color for this note">
-
@@ -51,7 +54,8 @@
😀 Emoji
- +
@@ -92,9 +96,10 @@
+ class="line-toggle"> Editor + lines
-
@@ -115,9 +121,12 @@
-
@@ -186,11 +196,12 @@ guest
- + - - - + + + - Connecting… + Connecting…