Comments (9)
Hello,
On my side I have configure with azure Entra Id as it :
- provider_name: azuread
display_name: Azure AD
base_url: https://login.microsoftonline.com/<tenant-id>/v2.0
client_id: <your-client-id>
client_secret: <your-secret>
extra_scopes:
- openid
- profile
- email
field_map:
email: email
firstname: name
user_identifier: preferred_username
is_admin: roles
registration_enabled: true
And it's work but the is_admin mapping didn't work because on the ParseUserInfo function of (auth_oidc.go)[https://github.com/h44z/wg-portal/blob/master/internal/app/auth/auth_oidc.go] the identification try to parse a field and microsoft entra Id send most of them as list.
from wg-portal.
For the curious
in the config you should set
callback_url_prefix: https://your-example.com/api/v0
and in the redirect URI of microsoft application
https://your-example.com/api/v0/auth/login/azuread/callback
from wg-portal.
I'm trying with oauth also
auth:
oauth:
- id: Microsoft
provider_name: "azure_activedirectory_v2"
display_name: "Login with</br>AzureAD"
base_url: "https://login.microsoftonline.com/<client-id>/oauth2/v2.0"
auth_url: "https://login.microsoftonline.com/<client-id>/v2.0/authorize"
token_url: "https://login.microsoftonline.com/<client-id>/v2.0/token"
scopes: ["openid", "profile", "email"]
client_id: "<redacted>"
client_secret: "<redacted>"
registration_enabled: true
the button appear in the GUI but the generated link is really strange and result in a 404 error...
from wg-portal.
Could you assist me with this issue? I'm encountering a 404 error, and when attempting to address it using the callback_prefix /auth/login, I'm receiving the error message: "redirect_uri' value must be a valid absolute URI" on Microsoft's page. I suspect this is something that needs adjustment in the configuration file. Could you provide guidance on resolving this? Additionally, could you share a portion of your configuration settings for reference?
from wg-portal.
I use the exact same configuration as @aRobinTNS
it might be an issue with the URL specify on the Microsoft configuration side
from wg-portal.
Could you assist me with this issue? I'm encountering a 404 error, and when attempting to address it using the callback_prefix /auth/login, I'm receiving the error message: "redirect_uri' value must be a valid absolute URI" on Microsoft's page. I suspect this is something that needs adjustment in the configuration file. Could you provide guidance on resolving this? Additionally, could you share a portion of your configuration settings for reference?
I confirm that your issue came from the Microsoft configuration side. The url that you have to put in microsoft is normaly like it : https:///api/v0/auth/login/azuread/callback
from wg-portal.
My redirect url on Microsoft side is: https://<my-domain.com>/api/v0/auth/login/azuread/callback
from wg-portal.
ah yes this is correct.
Is the URL accessible from outside ?
my configuration is the following
core:
admin_user: <admin user name>
admin_password: <thepassword>
import_existing: false
restore_state: true
self_provisioning_allowed: true
web:
external_url: https://<my-url>
request_logging: true
auth:
callback_url_prefix: https://<my-url>/api/v0
oidc:
- provider_name: azuread
display_name: Azure AD
base_url: "https://login.microsoftonline.com/<tenant id>/v2.0"
client_id: "<client-id>"
client_secret: "<secret>"
extra_scopes:
- openid
- profile
- email
field_map:
email: email
firstname: name
user_identifier: preferred_username
is_admin: roles
registration_enabled: true
from wg-portal.
Thanks! Now it works.
On the other hand, when I access with the Microsoft account, I obtain the following when I want to see the default peer's configuration:
Backend Connection Failure
Failed to load peer configuration!
Some ideas?
from wg-portal.
Related Issues (20)
- [v2] Keypairs/PublicKey can not be changed HOT 3
- Deploy and run HOT 1
- Squashed PostUp / PostDown HOT 2
- wg-portal deletes routes HOT 4
- User management
- LDAP disable Peers deleted from ldap HOT 1
- Issue with Postgres database HOT 1
- Redirect traffic to domain HOT 1
- Option to bind webserver to specific interface HOT 1
- Customizing homepage HOT 1
- Instructions/example for `field_map`? HOT 6
- Docker container refuses to find/load config.yml when not mapped directly to the file
- Peers are added to wg0.conf with a mask of /24
- LDAP Login Issue HOT 6
- Doc: Showing prominently config format for current stable version HOT 2
- Error when using mysql as database
- LDAP sync runs every 10 seconds, ldap_sync_interval is ignored
- Sending Wireguard-Config via Postfix Mailserver Fails
- no work with ghcr.io/wg-easy/wg-easy:latest after update HOT 1
- [ Feature Request ] - v2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from wg-portal.