[GH-ISSUE #2235] Cannot share vpn acces #995

Open
opened 2026-10-13 20:32:33 +00:00 by bsakaguchi · 4 comments
Owner

Originally created by @treapster on GitHub (Feb 17, 2026).
Original GitHub issue: https://github.com/amnezia-vpn/amnezia-client/issues/2235

Describe the bug
When sharing vpn acces as either config file, vpn:// key string or AmneziaWG native format, the shared config produces either ErrorCode 1000: VPN connection error or Unable to import tunnel: syntax error in peer

To Reproduce
Steps to reproduce the behavior:

  1. Go to share tab in AmneziaVPN android app
  2. Click on Share button
  3. Transfer key or config to another android device
  4. On another device, in amneziaVPN select "get started"
  5. Insert key directly or import config file
  6. When pressing Connect, error ErrorCode 1000: VPN connection error will happen
  7. If you use native format and AmneziaWG, error Unable to import tunnel: syntax error in peer happens
    Expected behavior
    The shared key or config works

Smartphone:

  • Device: Xiaomi redmi note 9
  • OS: Android 13
  • Version: 4.8.12.9

Server:

  • OS: Ubuntu 22.04

Additional context
This error was already reported in https://github.com/amnezia-vpn/amnezia-client/issues/1390.

Also, it can be seen in native config that PublicKey and PresharedKey are indeed not set in [Peer] section

Originally created by @treapster on GitHub (Feb 17, 2026). Original GitHub issue: https://github.com/amnezia-vpn/amnezia-client/issues/2235 **Describe the bug** When sharing vpn acces as either config file, `vpn://` key string or AmneziaWG native format, the shared config produces either `ErrorCode 1000: VPN connection error` or `Unable to import tunnel: syntax error in peer` **To Reproduce** Steps to reproduce the behavior: 1. Go to share tab in AmneziaVPN android app 2. Click on Share button 3. Transfer key or config to another android device 4. On another device, in amneziaVPN select "get started" 5. Insert key directly or import config file 6. When pressing Connect, error `ErrorCode 1000: VPN connection error` will happen 7. If you use native format and AmneziaWG, error `Unable to import tunnel: syntax error in peer` happens **Expected behavior** The shared key or config works **Smartphone:** - Device: Xiaomi redmi note 9 - OS: Android 13 - Version: 4.8.12.9 **Server:** - OS: Ubuntu 22.04 **Additional context** This error was already reported in https://github.com/amnezia-vpn/amnezia-client/issues/1390. Also, it can be seen in native config that `PublicKey` and `PresharedKey` are indeed not set in `[Peer]` section
Author
Owner

@cann3v commented on GitHub (Mar 5, 2026):

The same problem. I tried to remove Amnezia from the server using the button in the client, but in reality nothing changed on the server. Then I stopped and removed the container with Amnezia and deleted the image. After that, I reinstalled the server through the client, and this time everything worked: now I can share the connection with other clients.

<!-- gh-comment-id:4006536941 --> @cann3v commented on GitHub (Mar 5, 2026): The same problem. I tried to remove Amnezia from the server using the button in the client, but in reality nothing changed on the server. Then I stopped and removed the container with Amnezia and deleted the image. After that, I reinstalled the server through the client, and this time everything worked: now I can share the connection with other clients.
Author
Owner

@treapster commented on GitHub (Mar 5, 2026):

The same problem. I tried to remove Amnezia from the server using the button in the client, but in reality nothing changed on the server. Then I stopped and removed the container with Amnezia and deleted the image. After that, I reinstalled the server through the client, and this time everything worked: now I can share the connection with other clients.

@cann3v Were you able to share specifically awg2 config, or are you using other protocol? In my case i just started using vless and it worked. It seems like awg2 is not fully supported yet.

<!-- gh-comment-id:4007632324 --> @treapster commented on GitHub (Mar 5, 2026): > The same problem. I tried to remove Amnezia from the server using the button in the client, but in reality nothing changed on the server. Then I stopped and removed the container with Amnezia and deleted the image. After that, I reinstalled the server through the client, and this time everything worked: now I can share the connection with other clients. @cann3v Were you able to share specifically awg2 config, or are you using other protocol? In my case i just started using vless and it worked. It seems like awg2 is not fully supported yet.
Author
Owner

@PodJIgaeFF commented on GitHub (Mar 6, 2026):

In my case, there was a problem with sudo on the server.
Docker-related commands are executed with "sudo docker ..."
No sudo - invalid requests with no errors in the logs.

<!-- gh-comment-id:4012528923 --> @PodJIgaeFF commented on GitHub (Mar 6, 2026): In my case, there was a problem with sudo on the server. Docker-related commands are executed with "sudo docker ..." No sudo - invalid requests with no errors in the logs.
Author
Owner

@cann3v commented on GitHub (Mar 17, 2026):

@cann3v Were you able to share specifically awg2 config, or are you using other protocol? In my case i just started using vless and it worked. It seems like awg2 is not fully supported yet.

@treapster I have only tried awg2.

<!-- gh-comment-id:4072675930 --> @cann3v commented on GitHub (Mar 17, 2026): > @cann3v Were you able to share specifically awg2 config, or are you using other protocol? In my case i just started using vless and it worked. It seems like awg2 is not fully supported yet. @treapster I have only tried awg2.
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
amnezia-vpn/amnezia-client#995
No description provided.