Got ready for publication #7
|
@ -2,6 +2,10 @@
|
||||||
name = "e2e-irc"
|
name = "e2e-irc"
|
||||||
version = "3.0.0"
|
version = "3.0.0"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
license = "GPL-3.0"
|
||||||
|
keywords = ["irc", "encryption"]
|
||||||
|
description = "An IRC bouncer that can send encrypted messages"
|
||||||
|
repository = "https://forgejo.vanten-s.com/vanten-s/e2e-irc/"
|
||||||
|
|
||||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||||
|
|
||||||
|
@ -10,7 +14,7 @@ argparse = "0.2.2"
|
||||||
base64 = "0.21.4"
|
base64 = "0.21.4"
|
||||||
dirs = "5.0.1"
|
dirs = "5.0.1"
|
||||||
eyre = "0.6.8"
|
eyre = "0.6.8"
|
||||||
ircparser = { git = "https://forgejo.vanten-s.com/vanten-s/ircparser" }
|
ircparser-vanten = "0.2.1"
|
||||||
openssl = "0.10"
|
openssl = "0.10"
|
||||||
pgp = "0.10.2"
|
pgp = "0.10.2"
|
||||||
rand = "0.8.5"
|
rand = "0.8.5"
|
||||||
|
|
|
@ -136,7 +136,7 @@ fn main() -> Result<()> {
|
||||||
&writer_channel_rx,
|
&writer_channel_rx,
|
||||||
&listener_channel_tx,
|
&listener_channel_tx,
|
||||||
&listener_channel_rx,
|
&listener_channel_rx,
|
||||||
&mut state,
|
&state,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
Err(error) => match error {
|
Err(error) => match error {
|
||||||
|
|
|
@ -26,7 +26,7 @@ pub fn handle_message_from_server(
|
||||||
writer_channel_rx: &Receiver<String>,
|
writer_channel_rx: &Receiver<String>,
|
||||||
listener_channel_tx: &Sender<String>,
|
listener_channel_tx: &Sender<String>,
|
||||||
_listener_channel_rx: &Receiver<String>,
|
_listener_channel_rx: &Receiver<String>,
|
||||||
state: &mut State,
|
state: &State,
|
||||||
) -> Result<()> {
|
) -> Result<()> {
|
||||||
let recieved_parsed = &unwrap_or_return_result!(ircparser::parse(recieved))[0];
|
let recieved_parsed = &unwrap_or_return_result!(ircparser::parse(recieved))[0];
|
||||||
|
|
||||||
|
@ -39,7 +39,7 @@ pub fn handle_message_from_server(
|
||||||
|
|
||||||
if recieved_parsed.command != "PRIVMSG"
|
if recieved_parsed.command != "PRIVMSG"
|
||||||
|| reciever.starts_with('#')
|
|| reciever.starts_with('#')
|
||||||
|| state.nicks_without_encryption.contains(&reciever)
|
|| state.nicks_without_encryption.contains(reciever)
|
||||||
{
|
{
|
||||||
forward(recieved, listener_channel_tx, server)?;
|
forward(recieved, listener_channel_tx, server)?;
|
||||||
return Ok(());
|
return Ok(());
|
||||||
|
|
|
@ -18,7 +18,7 @@ pub fn write_to_server(
|
||||||
|
|
||||||
let connector = SslConnector::builder(SslMethod::tls()).unwrap().build();
|
let connector = SslConnector::builder(SslMethod::tls()).unwrap().build();
|
||||||
let mut stream = connector
|
let mut stream = connector
|
||||||
.connect(&server, &tcp_stream)
|
.connect(server, &tcp_stream)
|
||||||
.expect("Couldn't start TLS");
|
.expect("Couldn't start TLS");
|
||||||
|
|
||||||
stream
|
stream
|
||||||
|
|
Loading…
Reference in a new issue