Skip to content

Add Lichess provider #511

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

Merged
merged 20 commits into from
Jan 31, 2021
Merged

Add Lichess provider #511

merged 20 commits into from
Jan 31, 2021

Conversation

tanczosm
Copy link
Contributor

  • Added Lichess provider and unit test
  • Update README.md
  • Added documentation

This provider is one of the world's largest chess sites.

Copy link
Member

@martincostello martincostello left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just a few minor comments.

@tanczosm
Copy link
Contributor Author

All suggestions have been merged. Thanks for catching those.

@martincostello martincostello added this to the 3.1.7 milestone Jan 31, 2021
@martincostello martincostello merged commit 0e1799c into aspnet-contrib:dev Jan 31, 2021
@martincostello
Copy link
Member

Thanks for you contribution @tanczosm! 🥳

The provider will be released to NuGet.org within the next week or so once I've got some admin tasks on the repository completed.

In the meantime, you can consume a prerelease version of the provider from our MyGet feed once the CI is completed: https://www.myget.org/gallery/aspnet-contrib

martincostello added a commit to martincostello/AspNet.Security.OAuth.Providers that referenced this pull request Jan 31, 2021
* Add Lichess Provider

* Fixed indentation issue with documentation

* Adding refresh token and accurate expires_in to bundle.json

* Fixed PreferencesWrite scope name

* Reverted to original Tests project definition

* Fixed naming issue

* Cleaned up code formatting issue

* Updated documentation to reflect correct property type for Scope

Co-authored-by: Martin Costello <[email protected]>

* Renamed payloadEmail to emailPayload

Co-authored-by: Martin Costello <[email protected]>

* Comment casing typo corrected

Co-authored-by: Martin Costello <[email protected]>

* Changed comment regarding backchannel request

Co-authored-by: Martin Costello <[email protected]>

* Added Async to name of asynchronous method

Co-authored-by: Martin Costello <[email protected]>

* Code formatting fix

Co-authored-by: Martin Costello <[email protected]>

* Added nuget link to README

* Renamed LichessAuthenticationConstants

* Corrected one remaining CHANGEME reference

* Fixed issues from renaming from suggestions

* Fixed test reference

Co-authored-by: Martin Costello <[email protected]>
martincostello added a commit that referenced this pull request Jan 31, 2021
* Update to ASP.NET 5

Updates to support ASP.NET 5, using preview 6.
Remove obsolete members.

* Update to ASP.NET 5 preview 7

Update to preview 5 of ASP.NET 5.

* Update to ASP.NET 5 preview 8

Update to preview 8 of ASP.NET 5.

* Align with AspNetCore previews

Update the version metadata to align with ASP.NET Core, so we generate prerelease labels like "preview.8." or "rc.1.".

* Update to ASP.NET 5 RC1

Update to RC1 of ASP.NET 5.

* Use HashData() and ToHexString() methods

Use new HashData() methods for SHA256 and MD5.
Use Convert.ToHexString().

* Fix sign out in sample

Fix sign out in the sample not working as it was overriding a method that is decorated with [NonAction].

* Use <DebugType>portable</DebugType> to avoid embedding the PDBs in the assemblies

* Handle user cancelling LinkedIn sign in

Handle the user cancelling login or denying permissions during LinkedIn sign in.
Resolves #480.

* Add Kloudless provider (#479)

* WIP : Add kloudless provider

* Add kloudless provider

* Add entry in readme

* Add commented example

* Add more unit tests. Explicit error

* Fix exception usage

* Add missing punctuation

* Add kloudless doc. Specify default scope and add possible scopes.

* remove example in MVC project

* Fix convention issue on constant. Add comment.

* Update Kloudless provider to .NET 5

Updates to the Kloudless provider to support .NET 5.

* Update to ASP.NET 5 RC2

Update to RC2 of ASP.NET 5.

* Use IMemoryCache for Apple client secrets

Use an IMemoryCache for Apple client secrets to support multiple keys in use at once for a mult-tenant application.

Co-Authored-By: SeongChan Lee <[email protected]>

* Add unit test for key caching

Add a unit test to verify that keys are cached according to their options and vary according to different client/team/key Ids.

* Use structured logging

Use structured logging if client secret generation fails.

* Remove JwtSecurityTokenHandler from DI

Remove the configuration of JwtSecurityTokenHandler from the DI container and instead make it a property on AppleAuthenticationOptions.

* Do not overlap with existing CryptoProviderFactory

Rather than using an existing CryptoProviderFactory if one is registered with DI, which could potentially create a conflict between other usage and ours, explicitly use a custom implementation that ensures the cache is disabled.

* Move JwtSecurityTokenHandler setup to post-configure

Setup the JwtSecurityTokenHandler as a post-configure options implementation, rather than null-checking each time it's used.

* Move Apple provider's services out of DI

Move the services for the Apple provider out of DI and instead make them options on the AppleAuthenticationOptions class instead.

* Remove !

Remove ! as it doesn't trigger a compiler error anymore since RC2.

* Update staging subdomain for SuperOffice (#490)

Co-authored-by: SuperOfficeDevNet <[email protected]>

* Add email claim for Yahoo provider (#488)

Email is a mandatory claim. Add it by default to claims.

* Add email to Yahoo tests

Add a test for the email claim for the Yahoo provider.
Relates to #488.

* Add KakaoTalk provider (#493)

Add KakaoTalk provider and unit tests

* Update KakaoTalk provider for .NET 5

Update the KakaoTalk provider to support .NET 5.

* Use new syntax to set environment variable

Use new syntax to set environment variable value.
See https://docs.github.com/en/free-pro-team@latest/actions/reference/workflow-commands-for-github-actions#setting-an-environment-variable.

* Use Write-Output

Use Write-Output instead of Write-Host.

* Use GITHUB_ENV not GITHUB_PATH

That's what happens when the example of how to do one thing is in the section about how to do something else.

* Update to ASP.NET 5

Update to the final release of ASP.NET 5.
Update NuGet packages to their latest versions.

* Bump version to 5.0.1

Bump version to 5.0.1 for next release.
Revert prerelease label to preview.

* Add UnionId claim for QQ provider (#509)

* Add claim for 'UnionId' of QQ platform, and other optimizations for details

* Update unittest&doc

* Update unitest for UnionID

* Fix doc & code style by suggestions of review

* Use built-in SDK analyzers

Use the code analyzers built into the .NET 5.0 SDK.

* Use new ReadAs*() overloads

Use new overloads for reading content which take a CancellationToken.

* Add amoCRM provider (#507)

* Add amoCRM provider

* - Rename constants;
- Change exception message;
- Add test for surnamt claim type.

* README change

* Add amocrm.md

* amoCRM required props description.

* Add Lichess provider (#511)

* Add Lichess Provider

* Fixed indentation issue with documentation

* Adding refresh token and accurate expires_in to bundle.json

* Fixed PreferencesWrite scope name

* Reverted to original Tests project definition

* Fixed naming issue

* Cleaned up code formatting issue

* Updated documentation to reflect correct property type for Scope

Co-authored-by: Martin Costello <[email protected]>

* Renamed payloadEmail to emailPayload

Co-authored-by: Martin Costello <[email protected]>

* Comment casing typo corrected

Co-authored-by: Martin Costello <[email protected]>

* Changed comment regarding backchannel request

Co-authored-by: Martin Costello <[email protected]>

* Added Async to name of asynchronous method

Co-authored-by: Martin Costello <[email protected]>

* Code formatting fix

Co-authored-by: Martin Costello <[email protected]>

* Added nuget link to README

* Renamed LichessAuthenticationConstants

* Corrected one remaining CHANGEME reference

* Fixed issues from renaming from suggestions

* Fixed test reference

Co-authored-by: Martin Costello <[email protected]>

* Update amoCrm and Lichess providers to .NET 5

Update the amoCRM and Lichess providers to support .NET 5.0.

* Add missing XML documentation

For completeness, add missing XML documentation to the Lichess handler.

* Fix parameter name

Change "schema" to "scheme".

* Stop using NuGet's Central Package Version Management feature

* Add UnionId claim for QQ provider (#509)

* Add claim for 'UnionId' of QQ platform, and other optimizations for details

* Update unittest&doc

* Update unitest for UnionID

* Fix doc & code style by suggestions of review

* Fix incorrect type

Document the scopes as a collection, not a single string.

* Update Pull Request template

* Add note about package ownership for new providers.
* Add note that creating issues for pull requests is optional.

Co-authored-by: Kévin Chalet <[email protected]>
Co-authored-by: Yann <[email protected]>
Co-authored-by: SeongChan Lee <[email protected]>
Co-authored-by: Anthony Yates <[email protected]>
Co-authored-by: SuperOfficeDevNet <[email protected]>
Co-authored-by: Faraj Farook <[email protected]>
Co-authored-by: Donghyeon Kim <[email protected]>
Co-authored-by: LeaFrock <[email protected]>
Co-authored-by: Denis Ivanov <[email protected]>
Co-authored-by: tanczosm <[email protected]>
@martincostello
Copy link
Member

Thanks again for your contribution @tanczosm - the provider is now available from NuGet.org as versions 3.1.7 and 5.0.1.

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

Successfully merging this pull request may close these issues.

2 participants