SocialAuthentication.NET
1.0.0
dotnet add package SocialAuthentication.NET --version 1.0.0
NuGet\Install-Package SocialAuthentication.NET -Version 1.0.0
<PackageReference Include="SocialAuthentication.NET" Version="1.0.0" />
<PackageVersion Include="SocialAuthentication.NET" Version="1.0.0" />
<PackageReference Include="SocialAuthentication.NET" />
paket add SocialAuthentication.NET --version 1.0.0
#r "nuget: SocialAuthentication.NET, 1.0.0"
#:package SocialAuthentication.NET@1.0.0
#addin nuget:?package=SocialAuthentication.NET&version=1.0.0
#tool nuget:?package=SocialAuthentication.NET&version=1.0.0
About Package
This package demonstrates how to integrate OAuth 2.0 authentication with OpenID Providers (OPs) such as Google, Apple, Microsoft, and Facebook. It allows individuals to use single sign-on (SSO) to access relying party sites using OpenID Providers (OPs).
Badges
Stable release Version:
Nuget Package Downloads:
Tech Stack
C#, .NET6.0
Requirements
Basic understanding of .NET NuGet packages, c#
Getting Started
Using the .NET CLI
To install this package using the .NET CLI, run the following code:
dotnet add package FluidProperties --version 1.0.0
Installation using Visual Studio
First, install NuGet. Then, install CountryRegion from the package manager console:
NuGet\Install-Package SocialAuthentication.NET -Version 1.0.10
Finally, import it into the file
using SocialAuthentication.NET;
Features
- OAuth 2.0 Authentication:
- Apple
- Microsoft
- User login and retrieval of user profile.
Sample Usage
OpenIdConfiguration openConfiguration = new OpenIdConfiguration(token);
- Output
| Type |
|---|
| OpenIdConfiguration |
Validate Token with Google
openConfiguration.googleIdConfiguration.ValidateGoogleToken("your-app-audience");
- Input
| Parameters | Type | Description |
|---|---|---|
| app-audience | string | Required. The application audience from your registered app on Google Api |
- Output
| Type | Description |
|---|---|
| JSON | Payload of user information |
Validate Token with Microsoft
string microsoftUser = openConfiguration.microsoftIdConfiguration.ValidateMicrosoftToken("your-app-audience", "your-app-tenantid");
- Input
| Parameters | Type | Description |
|---|---|---|
| app-audience | string | Required. The application audience from your registered app on Azure AD |
| app-tenantId | string | Required. The application tenantId from your registered app on Azure AD |
- Output
| Type | Description |
|---|---|
| JSON | Payload of user information |
Validate Token with Apple
string appleUser = openConfiguration.appleIdConfiguration.ValidateAppleToken("your-app-audience");
- Input
| Parameters | Type | Description |
|---|---|---|
| app-audience | string | Required. The application audience from your registered app on Apple |
- Output
| Type | Description |
|---|---|
| JSON | Payload of user information |
Validate Token with Facebook
string fecebookUser = openConfiguration.facebookIdConfiguration.ValidateFacebookToken("your-app-id", "your-app-secret");
- Input
| Parameters | Type | Description |
|---|---|---|
| app-id | string | Required. The application identity from your registered app on Meta |
| app-secret | string | Required. The application secret from your registered app on Meta |
Contibutions
I would appreciate your contributions, complaints, and other feedback.
See contributing.md for ways to get started.
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net6.0 is compatible. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net6.0
- Microsoft.IdentityModel.Tokens (>= 8.3.0)
- Newtonsoft.Json (>= 13.0.3)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 1.0.0 | 229 | 12/26/2024 |