diff --git a/Cargo.lock b/Cargo.lock index 1c5bd601..ab295d30 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1663,6 +1663,16 @@ dependencies = [ [[package]] name = "crc64fast-nvme" version = "1.1.1" +name = "crond" +version = "0.7.19" +dependencies = [ + "revolt-database", + "revolt-files", +] + +[[package]] +name = "crossbeam-channel" +version = "0.5.13" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d5e2ee08013e3f228d6d2394116c4549a6df77708442c62d887d83f68ef2ee37" dependencies = [ diff --git a/Cargo.toml b/Cargo.toml index 57b4459c..0eaad88c 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -7,8 +7,7 @@ members = [ "crates/core/*", "crates/services/*", "crates/bindings/*", - "crates/daemons/pushd", - "crates/daemons/voice-ingress" + "crates/daemons/*", ] [patch.crates-io] diff --git a/crates/core/database/src/models/users/model.rs b/crates/core/database/src/models/users/model.rs index d85801e7..6768258e 100644 --- a/crates/core/database/src/models/users/model.rs +++ b/crates/core/database/src/models/users/model.rs @@ -153,7 +153,7 @@ pub static DISCRIMINATOR_SEARCH_SPACE: Lazy> = Lazy::new(|| { .collect::>(); for discrim in [ - 123, 1234, 1111, 2222, 3333, 4444, 5555, 6666, 7777, 8888, 9999, + 123, 1234, 1111, 2222, 3333, 4444, 5555, 6666, 7777, 8888, 9999, 1488, ] { set.remove(&format!("{:0>4}", discrim)); } @@ -294,7 +294,14 @@ impl User { } // Ensure none of the following substrings show up in the username - const BLOCKED_SUBSTRINGS: &[&str] = &["```"]; + const BLOCKED_SUBSTRINGS: &[&str] = &[ + "```", + "discord.gg", + "rvlt.gg", + "guilded.gg", + "https://", + "http://", + ]; for substr in BLOCKED_SUBSTRINGS { if username_lowercase.contains(substr) { diff --git a/crates/daemons/crond/Cargo.toml b/crates/daemons/crond/Cargo.toml new file mode 100644 index 00000000..85ec4349 --- /dev/null +++ b/crates/daemons/crond/Cargo.toml @@ -0,0 +1,14 @@ +[package] +name = "crond" +version = "0.7.19" +license = "AGPL-3.0-or-later" +authors = ["Paul Makles "] +edition = "2021" +description = "Revolt Daemon Service: Timed data clean up tasks" + +# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html + +[dependencies] +# Core +revolt-database = { version = "0.7.19", path = "../../core/database" } +revolt-files = { version = "0.7.19", path = "../../core/files" } diff --git a/crates/daemons/crond/src/main.rs b/crates/daemons/crond/src/main.rs new file mode 100644 index 00000000..e7a11a96 --- /dev/null +++ b/crates/daemons/crond/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + println!("Hello, world!"); +}