Re: help me to create hostname.wg

2020-10-30 Thread Sonic
On Fri, Oct 30, 2020 at 12:07 PM kasak  wrote:
> $ wg showconf wg0
> [Interface]
> ListenPort = 9022
>
> why the keys is not configured?

You're not root.



Re: help me to create hostname.wg

2020-10-30 Thread kasak



30.10.2020 19:18, Josh Grosse пишет:

On Fri, Oct 30, 2020 at 07:05:51PM +0300, kasak wrote:

hello misc. I'm trying to create wg interface, but have no luck.

Here is my /etc/hostname.wg0:

$ cat /etc/hostname.wg0
inet 10.0.0.1/24
wgkey 
wgpeer  wgaip 10.0.0.2

after running doas sh /etc/netstart wg0 i have:

$ ifconfig wg0

wg0: flags=80c3 mtu 1420
?? index 6 priority 0 llprio 3
?? wgport 9022
?? groups: wg
?? inet 10.0.0.1 netmask 0xff00 broadcast 10.0.0.255

and:

$ wg showconf wg0
[Interface]
ListenPort = 9022

why the keys is not configured?

The keys only show in ifconfig(8) output when you run it as the superuser.

Brilliant! It works! Thank you :)



help me to create hostname.wg

2020-10-30 Thread kasak

hello misc. I'm trying to create wg interface, but have no luck.

Here is my /etc/hostname.wg0:

$ cat /etc/hostname.wg0
inet 10.0.0.1/24
wgkey 
wgpeer  wgaip 10.0.0.2

after running doas sh /etc/netstart wg0 i have:

$ ifconfig wg0

wg0: flags=80c3 mtu 1420
    index 6 priority 0 llprio 3
    wgport 9022
    groups: wg
    inet 10.0.0.1 netmask 0xff00 broadcast 10.0.0.255

and:

$ wg showconf wg0
[Interface]
ListenPort = 9022

why the keys is not configured?