From owner-freebsd-ports-bugs@freebsd.org Sun Feb 23 07:03:54 2020 Return-Path: Delivered-To: freebsd-ports-bugs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 9183E25B1F1 for ; Sun, 23 Feb 2020 07:03:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.nyi.freebsd.org (mailman.nyi.freebsd.org [IPv6:2610:1c1:1:606c::50:13]) by mx1.freebsd.org (Postfix) with ESMTP id 48QGQ23QTyz4chb for ; Sun, 23 Feb 2020 07:03:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.nyi.freebsd.org (Postfix) id 7547725B1F0; Sun, 23 Feb 2020 07:03:54 +0000 (UTC) Delivered-To: ports-bugs@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7507725B1EF for ; Sun, 23 Feb 2020 07:03:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 48QGQ21L97z4chQ for ; Sun, 23 Feb 2020 07:03:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 0E8CA8A72 for ; Sun, 23 Feb 2020 07:03:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 01N73rBA070999 for ; Sun, 23 Feb 2020 07:03:53 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 01N73rf5070998 for ports-bugs@FreeBSD.org; Sun, 23 Feb 2020 07:03:53 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f From: bugzilla-noreply@freebsd.org To: ports-bugs@FreeBSD.org Subject: [Bug 244330] net/wireguard wg-quick remote IP address assignment is incorrect Date: Sun, 23 Feb 2020 07:03:53 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: peter@libassi.se X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: decke@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter flagtypes.name Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 23 Feb 2020 07:03:54 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D244330 Bug ID: 244330 Summary: net/wireguard wg-quick remote IP address assignment is incorrect Product: Ports & Packages Version: Latest Hardware: Any OS: Any Status: New Severity: Affects Only Me Priority: --- Component: Individual Port(s) Assignee: decke@FreeBSD.org Reporter: peter@libassi.se Flags: maintainer-feedback?(decke@FreeBSD.org) Assignee: decke@FreeBSD.org local wg interface does not respond due to the wg-quick script sets up the interface by reusing the local address as the remote address in the ifconfig command: root@bsd2:~ # wg-quick up wg0 [#] wireguard-go wg0 INFO: (wg0) 2020/02/20 09:45:16 Starting wireguard-go version 0.0.20200121 [#] wg setconf wg0 /tmp/tmp.87viEAsK/sh-np.YdRfI6 [#] ifconfig wg0 inet 192.168.2.2 192.168.2.2 alias On linux setting up an IP address on a tun interface does not require a rem= ote address: [root@vpn2 wireguard]# wg-quick up wg0 [#] ip link add wg0 type wireguard [#] wg setconf wg0 /dev/fd/63 [#] ip -4 address add 192.168.2.2/24 dev wg0 In the wg-quick script function add_addr() is where the assignment is made: cmd ifconfig "$INTERFACE" inet "$1" "${1%%/*}" alias I verifed this by replacing remote address with localhost: cmd ifconfig "$INTERFACE" inet "$1" "127.0.0.1" alias Now local ping works. You can give any address I suppose since the =E2=80= =9Dremote address=E2=80=9D of the ifconfig of a tun interface is not really used by w= ireguard. --=20 You are receiving this mail because: You are the assignee for the bug.=