auth0-samples / auth0-winformswpf-oidc-samples Goto Github PK
View Code? Open in Web Editor NEWAuth0 OIDC Client with Windows Forms / WPF applications
License: MIT License
Auth0 OIDC Client with Windows Forms / WPF applications
License: MIT License
Is it possible to update the Microsoft.IdentityModel.Protocols.OpenIdConnect dependency in the Auth0.OidcClient.Core project.(https://www.nuget.org/packages/Microsoft.IdentityModel.Protocols.OpenIdConnect/7.2.0#supportedframeworks-body-tab)
This to avoid to have to update this ourselfs and make this a "top-level" package instead of "transitive" package in our projects.
The current version that is targeted (6.12..2 has vulnerabilities)
Thank you.
Install the package and view dependencies or view dependencies in Nuget.org
No response
No response
If you are reporting a bug, please fill the sections below (if they are applicable), otherwise feel free to delete those that don't apply. Thank you! ππΌ
What are you reporting?
NuGet Package "Auth0.OidcClient.WinForms" Version="3.2.7" does not work.
When you build the .NET Core 6.0 version you, get the build error as soon as you add the nuget package, even before you add any code to empty WinForms .NET Core Project.
Works fine with .NET Full Fat Framework 4.8
Severity Code Description Project File Line Suppression State
Error NETSDK1135 SupportedOSPlatformVersion 10.0.18362.0 cannot be higher than TargetPlatformVersion 7.0. WinFormsAppCore6 C:\Program Files\dotnet\sdk\7.0.100\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.TargetFrameworkInference.targets 188
Tell us what actually happens.
As above.
Tell us what we should do to reproduce the issue.
As Above.
<PropertyGroup>
<OutputType>WinExe</OutputType>
<TargetFramework>net6.0-windows</TargetFramework>
<Nullable>enable</Nullable>
<UseWindowsForms>true</UseWindowsForms>
<ImplicitUsings>enable</ImplicitUsings>
</PropertyGroup>
OS Name: Microsoft Windows 11 Pro
OS Version: 10.0.22621 N/A Build 22621
OS Manufacturer: Microsoft Corporation
OS Configuration: Member Workstation
OS Build Type: Multiprocessor Free
None.
After cloning the repo I opened and build the WPFSample solution successfully. Then I tried to Start a debug session and gett the following error:
When I try to run the WPFSample.exe manually:
I have sufficient permissions:
Clone repo, open in VS 2019, build and press F5
I am receiving the following error when using the Auth0.OidcClient.WinForms assembly (3.2.8) in a ASP.NET Web Application targeting .NET 4.8:
Error Loading discovery document: Issuer name is missing
It's a simple implementation of the example code:
private Auth0Client client;
client = new Auth0Client(new Auth0ClientOptions
{
Domain = "{DOMAIN}",
ClientId = "{CLIENTID}"
});
await client.LoginAsync(); // this is where it fails
Is this a known issue? Are there any resolutions?
can not use login with google
it transfering to :https://support.google.com/accounts/answer/7675428
login with some random gmail account - it looks like gmail enforce the new policy on specific accounts..
As you may have seen some time ago, we communicated the fact that we are gradually working on improving your developer experience inside any repo in this org!
If you go to the readme file of this repository, in the first section you can see a note that this repo is supported and maintained by Community Developers, not Auth0. Despite the fact that we have limited bandwidth inside Auth0 Community Team and are not able to effectively review issues and PRs you submit, we want to improve your experience here one step at a time! That's why you should keep reading!
If you feel like joining us on a mission to make other developers contributions here more comfortable, here are the links you should visit!
We're aiming at your successful developer experience in the long term that's why we introduced a few improvements in the meantime and are looking forward to make even more impact!
Think it's all?! Nah! We ain't stoppin here! β¨
Let us know what you think! We're super stoked for your feedback! You can share it here or email us at [email protected]. We know there's a long way ahead of us to make this environment friendly and sustainable but we strongly believe that getting aboard together will let us reach the final destination!
You have to add
extraParameters.Add("scope", "openid offline_access");
before you call LoginAsync or you will get error "id token not contained in result"
Note the "openid" parameter which is not mentioned anywhere in the documentation.
With the upcoming deprecation of AuthZ Extension, we're looking to move our WPF Application over to using Auth0 Core/Groups. I've followed along with documentation with a completely barebones, stand-alone WPF app that just contains the Auth0.Oidc.WPF
nuget client and I'm able to get a successful authentication of my access token and returned user token with Individual
login option, but the moment I switch to Organization
the scope seems to be completely missing and I get an unauthenticated error return code (openid profile email
are all missing in the logs when I switch to orgs).
Here's a general overview of how I'm setting up the client:
var auth0Client = new Auth0Client(new Auth0ClientOptions
{
Domain = "{my_domain}",
ClientId = "{my_clientId}",
Scope = "openid email profile",
});
loginResult = await auth0Client.LoginAsync(new { audience = "{my_audience}" });
Again, this works fine for individual login, but fails the moment I switch to orgs, which leaves me scratching my head. I am using the most up-to-date nuget package available, and only have these lines for my entire test app. Any help would be appreciated, thank you!
When using the LoginAsync call, an Auth0User is successfully returned, along with a valid IdToken, however the IdTokenExpiresAt doesn't match the IdToken's embedded expiration date and time.
Call
Dim myUser As Global.Auth0.Windows.Auth0User = Await client.LoginAsync(ParentForm,, , myParams, True, strDevice)
Partial Results (myUser serialized to Json)
"Auth0AccessToken": "Fam1mw..",
"IdToken": "eyJ0eXAiOiJKV...",
"IdTokenExpiresAt": "9999-12-31T23:59:59.9999999",
"Profile": {
It looks like a default value versus a populated value.
Is this an issue you see?
thx
Chris
What's going wrong is that the application, WindowsFormSample, is stuck after calling LoginAsync
var result = await client.LoginAsync();
It does not give an error or any kind of result. This happens only when I use Visual Studio 2019 as an admin. If I don't use Visual Studio as an admin it works fine. You might expect it to be the otherway around, but a collegue tested it as well and got the same result.
I cloned the WindowsFormSample and updated the .Net version to 4.7.2. Then I updated the Nuget Package Auth0.OidcClient.WinForms to version 3.1.2.
When I downgrade Auth0.OidcClient.WinForms to 2.4.1. it works fine, admin or no admin.
I'd appreciate any help on this.
I need to build a desktop application for existing website made using React frontend and Node Backend.
I need to make Http Request to a Server written in NodeJs but it throws an error 401(Unauthorized) when I try to get Token from the website The accesstoken is different
The AccessToken which I get using the example is showing Invalid Signature when I try to verify it using jwt.io
(AUTH-4147)
Samples doesn't contain readme.md file.
I am trying to get the Auth0 client to prefill the email field by passing a dictionary to the Task LoginAsync(object extraParameters = null) according to this https://auth0.com/docs/libraries/lock/lock-configuration#params-object it should be possible, but its unclear how to achieve this within c# wpf.
I have tried using the following as the "extraParameters":
But neither have any impact, is there a way to do this?
How to store extra user data like expiry date? and how to check it when user login is in process(In guess in Rules)?
And will it be possible to restrict Multiple login from same credentials? means if user is logged in Terminal A, and if again he tries to log in Terminal B, he should be logged in, but Terminal A should be logout automatically.
Activation of user should be done after Admin allows, not right after SignUp
i am trying in WPF
If you are reporting a bug, please fill the sections below (if they are applicable), otherwise feel free to delete those that don't apply. Thank you! ππΌ
Hi ,
I am using native winform application from here to login to my web page . Auth0 WPF / Winforms SDK Quickstarts: Login.
If I run the application normally everything works fine and I am getting token from my web server. but if I run the application in admin mode , it hangs after this call forever,
await client.LoginAsync(extraParameters: extraParameters).
Can anyone please help me with this.
It should login and return token.
It hangs forever.
Create exe out of winform application with required credentials for login. run the exe in normal mode . It will work fine . Run the exe in admin mode "Run as Administrator" it hangs forever.
1 .Net version 4.6.2
Filling this, you're helping yourself and repo maintainers in solving your issues quicker! Teamwork makes the dreamwork π€πΌπ€π»
If you are reporting a bug, please fill the sections below (if they are applicable), otherwise feel free to delete those that don't apply. Thank you! ππΌ
When running the sample WindowsFormsSample application by plugging in my Domain and ClientID and selecting any of the connection options, I get back an "invalid_request" response. No other information is provided and I can't track down what the problem is. I've re-created my Auth0 native application through their dashboard, added the allowed callback URL, and triple checked the domain and client id.
Login window should display.
Error is thrown "invalid_request."
Run the WindowsFormsSample app in this repository.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.