• [6.10.0-rc5] VPNmanager bug importing config file


    Skitals
    • Solved Minor

    Using the "import tunnel" feature, I was following the instructions for Configuring “VPN tunneled access for docker” which states "There are no settings to change, except perhaps to give it a local name. Click Apply."

     

    However, the Apply button is greyed out unless you make a change. If you import a config and make no changes the tunnel WILL NOT WORK. If you click the activate slider, it immediately deactivates.

     

    If you give it a local name and click apply, activate now works. In fact, you can import a config, create a name, apply, remove the name, apply, it will also work.

     

    So the local name is indeed optional, but you must make some change any change for the tunnel to work when importing a config file.




    User Feedback

    Recommended Comments

    Making a change is optional, and tunnel should work after importing.

    Can you share your file (remove keys content)

     

    Link to comment
    11 minutes ago, bonienl said:

    Making a change is optional, and tunnel should work after importing.

    Can you share your file (remove keys content)

     

     

    [Interface]
    Address = 10.11.153.11
    PrivateKey = 
    DNS = 10.0.0.243,10.0.0.242
    
    [Peer]
    PublicKey = 
    Endpoint = 199.36.223.205:1337
    AllowedIPs = 0.0.0.0/0
    PersistentKeepalive = 25

     

    I was able to reproduce this bug multiple times, tunnel would not work until making any change and hitting apply.

    Link to comment

    I see multiple changes are made to both /boot/config/wireguard/wg2.cfg and /boot/config/wireguard/wg2.conf after setting a name, hitting apply, removing the name, hitting apply.

     

    Here is wg2.cfg after importing:

     

    Endpoint:0=""
    PROT:0=""
    Network:0="10.11.153.0/24"
    PublicKey:0=""
    UPNP:0="no"
    NAT:0="no"
    Address:1=""
    TYPE:1="8"

     

    Here is wg2.cfg after making/reverting a change and clicking Apply:

     

    PublicKey:0=""
    PROT:0=""
    Network:0="10.11.153.0/24"
    Endpoint:0=""
    UPNP:0="no"
    DROP:0=""
    RULE:0=""
    TYPE:1="8"
    Address:1=""

     

    Here is wg2.conf after importing:

     

    [Interface]
    PrivateKey=
    Address=10.11.153.11
    PostUp=ip -4 route flush table 202
    PostUp=ip -4 route add default via 10.11.153.11 table 202
    PostUp=ip -4 route add 192.168.84.0/22 via 192.168.86.1 table 202
    PostDown=ip -4 route flush table 202
    PostDown=ip -4 route add unreachable default table 202
    PostDown=ip -4 route add 192.168.84.0/22 via 192.168.86.1 table 202
    
    [Peer]
    AllowedIPs=0.0.0.0/0
    Endpoint=199.36.223.205:1337
    =25
    PublicKey=
    

     

    Here is wg2.conf after making/reverting a change and clicking Apply:

     

    [Interface]
    PrivateKey=
    Address=10.11.153.11
    PostUp=logger -t wireguard 'Tunnel WireGuard-wg2 started'
    PostDown=logger -t wireguard 'Tunnel WireGuard-wg2 stopped'
    PostUp=ip -4 route flush table 202
    PostUp=ip -4 route add default via 10.11.153.11 table 202
    PostUp=ip -4 route add 192.168.84.0/22 via 192.168.86.1 table 202
    PostDown=ip -4 route flush table 202
    PostDown=ip -4 route add unreachable default table 202
    PostDown=ip -4 route add 192.168.84.0/22 via 192.168.86.1 table 202
    
    [Peer]
    PublicKey=
    Endpoint=199.36.223.205:1337
    AllowedIPs=0.0.0.0/0

     

     

    Link to comment

    Okay, so analyzing the above I see the error is how it imports "PersistentKeepalive = 25" from my wg config file. It gets cleaned up when you make a change and hit Apply. If I import and remove the "=25" line it works without having to apply any changes.

    Edited by Skitals
    Link to comment
    37 minutes ago, bonienl said:

    rc5 does not completely import all key values, this is fixed in upcoming version rc6.

     

     

    Thanks, I tested the latest update.wireguard.php from github and it is importing my file properly, including the PersistentKeepalive value.

    • Like 1
    Link to comment


    Join the conversation

    You can post now and register later. If you have an account, sign in now to post with your account.
    Note: Your post will require moderator approval before it will be visible.

    Guest
    Add a comment...

    ×   Pasted as rich text.   Restore formatting

      Only 75 emoji are allowed.

    ×   Your link has been automatically embedded.   Display as a link instead

    ×   Your previous content has been restored.   Clear editor

    ×   You cannot paste images directly. Upload or insert images from URL.


  • Status Definitions

     

    Open = Under consideration.

     

    Solved = The issue has been resolved.

     

    Solved version = The issue has been resolved in the indicated release version.

     

    Closed = Feedback or opinion better posted on our forum for discussion. Also for reports we cannot reproduce or need more information. In this case just add a comment and we will review it again.

     

    Retest = Please retest in latest release.


    Priority Definitions

     

    Minor = Something not working correctly.

     

    Urgent = Server crash, data loss, or other showstopper.

     

    Annoyance = Doesn't affect functionality but should be fixed.

     

    Other = Announcement or other non-issue.