Security issue: oauth client secret is passed to frontend #2092

Open
opened 2025-11-20 06:12:38 -05:00 by saavagebueno · 1 comment
Owner

Originally created by @AbsurdlySuspicious on GitHub (Jul 21, 2025).

Describe the problem

Oauth client secret is embedded in frontend package of netbird (dashboard) within js chunks, and requests to oauth token endpoint are performed from frontend for some reason which also exposes client_secret in network tab

To Reproduce

Steps to reproduce the behavior:

  1. Setup selfhosted netbird according to official guide
  2. Go to netbird domain you've set up and open network tab in devtools

Expected behavior

Authorization code from oauth redirect is passed to backend and actual request to token endpoint happens on backend, client_secret is not exposed to browser

Are you using NetBird Cloud?

Self-hosted

NetBird version

0.51.1

Is any other VPN software installed?

No

Debug output

N/A

Screenshots

N/A

Additional context

N/A

Have you tried these troubleshooting steps?

  • Reviewed client troubleshooting (if applicable)
  • Checked for newer NetBird versions
  • Searched for similar issues on GitHub (including closed ones)
  • Restarted the NetBird client
  • Disabled other VPN software
  • Checked firewall settings
Originally created by @AbsurdlySuspicious on GitHub (Jul 21, 2025). **Describe the problem** Oauth client secret is embedded in frontend package of netbird (dashboard) within js chunks, and requests to oauth token endpoint are performed from frontend for some reason which also exposes client_secret in network tab **To Reproduce** Steps to reproduce the behavior: 1. Setup selfhosted netbird according to official guide 2. Go to netbird domain you've set up and open network tab in devtools **Expected behavior** Authorization code from oauth redirect is passed to backend and actual request to token endpoint happens on backend, client_secret is not exposed to browser **Are you using NetBird Cloud?** Self-hosted **NetBird version** `0.51.1` **Is any other VPN software installed?** No **Debug output** N/A **Screenshots** N/A **Additional context** N/A **Have you tried these troubleshooting steps?** - [x] Reviewed [client troubleshooting](https://docs.netbird.io/how-to/troubleshooting-client) (if applicable) - [x] Checked for newer NetBird versions - [x] Searched for similar issues on GitHub (including closed ones) - [x] Restarted the NetBird client - [x] Disabled other VPN software - [x] Checked firewall settings
saavagebueno added the securitytriage-neededself-hosting labels 2025-11-20 06:12:38 -05:00
Author
Owner

@sk-shakeel commented on GitHub (Aug 26, 2025):

Addon: To reproduce the issue, search "authClientSecret" in the network tab.

Also Its only in case if your provider is Google Workspace.

@sk-shakeel commented on GitHub (Aug 26, 2025): **Addon:** To reproduce the issue, search "authClientSecret" in the network tab. Also Its only in case if your provider is Google Workspace.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: SVI/netbird#2092