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

NetBird v0.36.5 with Zitadel: Account Login Success but Device Registration and Peer Login Failures #3280

Open
xiaojueshi opened this issue Feb 4, 2025 · 1 comment

Comments

@xiaojueshi
Copy link

Describe the problem

During the use of the system, when using Zitadel for authentication, users can successfully log in to their accounts. However, they encounter issues when registering devices, preventing the devices from completing the registration process. Additionally, there are abnormal situations during client (peer) login, with two main types of error messages:

  1. Missing authentication method: The system prompts "no peer auth method provided, please use a setup key or interactive SSO login", indicating that when the client attempts to log in, it fails to provide a valid authentication method. The system requires the use of a setup key or interactive Single - Sign - On (SSO) for authentication.
    For example:
2025-02-04T15:06:43Z WARN [context: GRPC, requestID: f89d69cb-2d88-499f-90ca-35b2de7b2309, accountID: UNKNOWN, peerID: iarZZO5xA9gTip3+Pubd42ub1IoyNdevhZxgcAoW8F0=] management/server/grpcserver.go:473: failed logging in peer iarZZO5xA9gTip3+Pubd42ub1IoyNdevhZxgcAoW8F0=: no peer auth method provided, please use a setup key or interactive SSO login
  1. Account not found: The system prompts "failed adding new peer: account not found", meaning that when the client attempts to add a new peer, the system cannot find the corresponding account information.
    For example:
2025-02-04T15:06:44Z WARN [context: GRPC, requestID: a3db5f0a-812f-4058-a8dc-2649e4eb480d, accountID: UNKNOWN, peerID: iarZZO5xA9gTip3+Pubd42ub1IoyNdevhZxgcAoW8F0=] management/server/grpcserver.go:473: failed logging in peer iarZZO5xA9gTip3+Pubd42ub1IoyNdevhZxgcAoW8F0=: failed adding new peer: account not found

These errors prevent the client from logging in normally and the device from completing the registration.

To Reproduce

Since the specific operation steps are not clearly indicated in the logs, the possible steps to reproduce are speculated as follows:

  1. Start the NetBird management server. The server begins to load configuration information, as shown in the logs:
2025-02-04T15:05:59Z INFO [context: SYSTEM] management/cmd/management.go:514: loading OIDC configuration from the provided IDP configuration endpoint https://auth.lzwnas.cn/.well-known/openid-configuration
2025-02-04T15:05:59Z INFO [context: SYSTEM] management/server/telemetry/app_metrics.go:193: enabled application metrics and exposing on http://0.0.0.0:9090
2025-02-04T15:05:59Z INFO [context: SYSTEM] management/server/store/store.go:241: using SQLite store engine
  1. Log in to the account through Zitadel. This step can be completed successfully.
  2. Attempt to perform the device registration operation.
  3. The client fails to provide a valid authentication method or uses non - existent account information when attempting to log in for device registration.
  4. The system outputs the corresponding warning messages, indicating login failure and device registration failure, as shown in the log examples described in the error information above.
@xiaojueshi xiaojueshi changed the title NetBird with Zitadel: Account Login Success but Device Registration and Peer Login Failures NetBird v0.36.5 with Zitadel: Account Login Success but Device Registration and Peer Login Failures Feb 4, 2025
@bcmmbaga
Copy link
Contributor

bcmmbaga commented Feb 4, 2025

Hello @xiaojueshi , could you clarify how you are registering the new peer? Specifically, do you specify your self-hosted management URL during the registration process? If not you can try running:

netbird up --management-url <YOUR_MANAGEMENT_URL>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants