diff options
Diffstat (limited to 'web/assets')
| -rw-r--r-- | web/assets/js/model/outbound.js | 4 | ||||
| -rw-r--r-- | web/assets/js/model/xray.js | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/web/assets/js/model/outbound.js b/web/assets/js/model/outbound.js index 0191c4a4..42fb50a1 100644 --- a/web/assets/js/model/outbound.js +++ b/web/assets/js/model/outbound.js @@ -915,7 +915,7 @@ Outbound.HttpSettings = class extends CommonClass { Outbound.WireguardSettings = class extends CommonClass { constructor( mtu=1420, secretKey=Wireguard.generateKeypair().privateKey, - address='', workers=2, domainStrategy='', reserved='', + address=[''], workers=2, domainStrategy='ForceIPv6v4', reserved='', peers=[new Outbound.WireguardSettings.Peer()], kernelMode=false) { super(); this.mtu = mtu; @@ -965,7 +965,7 @@ Outbound.WireguardSettings = class extends CommonClass { }; Outbound.WireguardSettings.Peer = class extends CommonClass { - constructor(publicKey='', psk='', allowedIPs=['0.0.0.0/0','::/0'], endpoint='', keepAlive=0) { + constructor(publicKey=Wireguard.generateKeypair().publicKey, psk='', allowedIPs=['0.0.0.0/0','::/0'], endpoint='', keepAlive=0) { super(); this.publicKey = publicKey; this.psk = psk; diff --git a/web/assets/js/model/xray.js b/web/assets/js/model/xray.js index b2c8a2e5..e9676252 100644 --- a/web/assets/js/model/xray.js +++ b/web/assets/js/model/xray.js @@ -2297,7 +2297,7 @@ Inbound.WireguardSettings = class extends XrayCommonClass { }; Inbound.WireguardSettings.Peer = class extends XrayCommonClass { - constructor(publicKey='', psk='', allowedIPs=['0.0.0.0/0','::/0'], keepAlive=0) { + constructor(publicKey=Wireguard.generateKeypair().publicKey, psk='', allowedIPs=['0.0.0.0/0','::/0'], keepAlive=0) { super(); this.publicKey = publicKey; this.psk = psk; |
