Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect generation of server public key #58

Closed
mnil opened this issue Jul 7, 2020 · 6 comments
Closed

Incorrect generation of server public key #58

mnil opened this issue Jul 7, 2020 · 6 comments

Comments

@mnil
Copy link

mnil commented Jul 7, 2020

The client key generates to AAA...AA= but after the QR code is gone, the public key is not AAA...AA=.
image

My docker-compose

  wg-access-server:
    image: place1/wg-access-server
    container_name: wg-access-server
    environment:
      - ADMIN_USER=
      - ADMIN_PASSWORD=
    cap_add:
      - NET_ADMIN
    volumes:
      - "./wg-access-server/data:/data"
      - "./wg-access-server/config.yaml:/config.yaml"
    ports:
      - "8000:8000/tcp"
      - "51820:51820/udp"
    devices:
      - "/dev/net/tun:/dev/net/tun"
loglevel: info
disableMetadata: false
port: 8000
storage: "file:///data/"
wireguard:
  interfaceName: wgserver
  privateKey: "<...>="
  externalHost: ""
  port: 51820
vpn:
  cidr: "10.45.0.0/24"
  gatewayInterface: "eno1"
  allowedIPs:
    - "0.0.0.0/0"
dns:
  enabled: true
  upstream:  
    - "1.1.1.1"
auth:
  basic:
    users: ["user:pass"]
@arctica
Copy link

arctica commented Jul 7, 2020

AAA...AA= is a base64 encoding of an array only zero bytes. This is the server public key. You have that a bit confused.

The client private key seems fine from the little piece in your screenshot. Seems like the server pub key got wrongly generated.

@mnil
Copy link
Author

mnil commented Jul 7, 2020

@arctica where do I enter the server pub key? I only entered a private key by:

wireguard:
  privateKey: "<...>QkE="

@mnil mnil changed the title Incorrect generation of client key Incorrect generation of server public key Jul 7, 2020
@arctica
Copy link

arctica commented Jul 7, 2020

@mnil the public keys are generated from the private keys, you don't enter them anywhere. In terms of keys all you specify is the server's private key. How did you generate that one?

@mnil
Copy link
Author

mnil commented Jul 8, 2020

@arctica I generated it by wg genkey and pasted that key in the config.

@Place1
Copy link
Owner

Place1 commented Jul 18, 2020

Hey @mnil sorry for the slow reply. I'm unable to reproduce this so far but I did identify some issues with how wg-access-server reports configuration problems that might have caused this.

Could you give the new version 0.2.4 a go and let me know :)

@mnil
Copy link
Author

mnil commented Sep 9, 2020

@Place1 I tested the latest image the other day with the same problem. I have since switched to using just wg and since you can't reproduce the problem I will close this issue. Keep up with the good project though! 🎉

@mnil mnil closed this as completed Sep 9, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants