fix using the wrong listen ip
This commit is contained in:
parent
ccefec16a2
commit
a1693b1ff7
3 changed files with 3 additions and 3 deletions
2
Cargo.lock
generated
2
Cargo.lock
generated
|
@ -86,7 +86,7 @@ dependencies = [
|
||||||
|
|
||||||
[[package]]
|
[[package]]
|
||||||
name = "revpfw3"
|
name = "revpfw3"
|
||||||
version = "0.4.0"
|
version = "0.4.1"
|
||||||
dependencies = [
|
dependencies = [
|
||||||
"enum-ordinalize",
|
"enum-ordinalize",
|
||||||
"serial",
|
"serial",
|
||||||
|
|
|
@ -3,7 +3,7 @@ name = "revpfw3"
|
||||||
repository = "https://github.com/tudbut/revpfw3"
|
repository = "https://github.com/tudbut/revpfw3"
|
||||||
description = "A tool to bypass portforwarding restrictions using some cheap VServer"
|
description = "A tool to bypass portforwarding restrictions using some cheap VServer"
|
||||||
license = "MIT"
|
license = "MIT"
|
||||||
version = "0.4.1"
|
version = "0.4.2"
|
||||||
edition = "2021"
|
edition = "2021"
|
||||||
|
|
||||||
# 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
|
||||||
|
|
|
@ -36,7 +36,7 @@ pub fn server(port: u16, key: &str, sleep_delay_ms: u64) {
|
||||||
let mut buf8 = [0u8; 8];
|
let mut buf8 = [0u8; 8];
|
||||||
let mut buf16 = [0u8; 16];
|
let mut buf16 = [0u8; 16];
|
||||||
let mut buf = [0; 1024];
|
let mut buf = [0; 1024];
|
||||||
let tcpl = TcpListener::bind(("::1", port)).unwrap();
|
let tcpl = TcpListener::bind(("::0", port)).unwrap();
|
||||||
let mut tcp = loop {
|
let mut tcp = loop {
|
||||||
let Ok(mut tcp) = tcpl.accept() else { continue };
|
let Ok(mut tcp) = tcpl.accept() else { continue };
|
||||||
let Ok(()) = tcp.0.read_exact(&mut buf4) else {
|
let Ok(()) = tcp.0.read_exact(&mut buf4) else {
|
||||||
|
|
Loading…
Add table
Reference in a new issue