Forssux
1
Hi there,
I belive there's a small error in the code .
when key's are generated ...the WG_PUB="$(cat wgclient.pub)" should be WG_PUB="$(cat wgserver.pub)"
WG_PUB="$(cat wgclient.pub)" will give error
# Generate and exchange the keys
umask u=rw,g=,o=
wg genkey | tee wgserver.key | wg pubkey > wgserver.pub
wg genpsk > wg.psk
WG_KEY="$(cat wgserver.key)"
WG_PSK="$(cat wg.psk)"
WG_PUB="$(cat wgclient.pub)"
Forssux
3
because there isn't a wgclient.pub generated
darksky
4
No, to which code do you refer? Link?
That's because you have to provide the client's public key that was generated by it.
OpenWrt cannot guess or generate the remote client's Public Key as it's based on the client's Private Key.
So, did you copy over or paste the peer's Public Key into a wgclient.pub file - as the instructions state?
Forssux
6
OK. I tested for this thread:
- I read the page you linked (hence I sent you a screenshot - before you responded to @darksky)
- I performed all steps
- the last line works! (except if I do not exchange keys and provide
wgclient.pub from the peer)
Perhaps you should install the LuCI web app and setup your peers from there.