patch WireGuard.js WireGuard.js.patch
Created
February 26, 2022 17:16
-
-
Save ffoxin/85d24fdae8aa7ae4e8df701bcd92cb73 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- WireGuard.js.old 2022-01-31 11:08:43.178581074 +0000 | |
+++ WireGuard.js.fixed 2022-01-31 11:10:12.487859150 +0000 | |
@@ -95,7 +95,7 @@ | |
[Peer] | |
PublicKey = ${client.publicKey} | |
PresharedKey = ${client.preSharedKey} | |
-AllowedIPs = ${client.address}/32`; | |
+AllowedIPs = ${client.allowedIPs}`; | |
} | |
debug('Saving config...'); | |
@@ -235,6 +235,8 @@ | |
publicKey, | |
preSharedKey, | |
+ allowedIPs: `${address}/32`, | |
+ | |
createdAt: new Date(), | |
updatedAt: new Date(), | |
@@ -290,6 +292,7 @@ | |
} | |
client.address = address; | |
+ client.allowedIPs = `${address}/32`; | |
client.updatedAt = new Date(); | |
await this.saveConfig(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment