Open nomi-san opened 1 week ago
Have you tried passing null
instead of an empty string?
Yeah, both null and empty string will produce this read access violation. Tested on both v1.4.5.1 and v1.2.37.1 wgbooster.
Fatal error. System.AccessViolationException: Attempted to read or write protected memory.
This is often an indication that other memory is corrupt.
Yes, you are right, this is the bug in wgbooster.dll. It will be fixed in the next update. Thanks for reporting this.
I see the struct
WgbPeer
sayspreshared_key
is optional, but setting it as empty value when callingwgb_create_tunnel(...)
will produceread access violation
. Callingwgb_create_tunnel_from_file_w(...)
with emptyPresharedKey
should be fine, I'm sure the function will parse the config first and set this value as empty when the key is missing.In summary, the field
preshared_key
must be specified a real key, so when my peer server does not use PresharedKey, they could not decrypt packets.