Coder Social home page Coder Social logo

desjoerd / authservices Goto Github PK

View Code? Open in Web Editor NEW

This project forked from pggmteam5/authservices

0.0 2.0 0.0 6.97 MB

Saml2 Authentication services for ASP.NET

License: GNU Lesser General Public License v3.0

C# 87.45% Smalltalk 0.25% CSS 1.38% ASP 0.01% JavaScript 10.74% PowerShell 0.17%

authservices's Introduction

Build status Coverage Status Join the chat at https://gitter.im/Susatinsys/Saml2 Sustainsys.Saml2

The Sustainsys.Saml2 library adds SAML2P support to ASP.NET web sites, allowing the web site to act as a SAML2 Service Provider (SP). The library is undergoing a rename from the former name Kentor.AuthServices.

Kentor.AuthServices is open sourced and contributions are welcome, please see contributing guidelines for info on coding standards etc.

Using

The AuthServices library can be used through three different ways:

  • An Http Module, loaded into the IIS pipeline. The module is compatible with ASP.NET web forms sites.
  • An ASP.NET MVC Controller for better integration and error handling in ASP.NET Applications.
  • An Owin Middleware to use with the Owin Pipeline or for integration with ASP.NET Identity.

Note that this last usage scenario enables SAML identity providers to be integrated within IdentityServer3 package. Review this document to see how to configure AuthServices with IdentityServer3 and Okta to add Okta as an identity provider to an IdentityServer3 project. There is also a SampleIdentityServer3 project in the AuthServices repository.

There are four nuget packages available. The core Kentor.AuthServices contains the core functionality. The Kentor.AuthServices.HttpModule contains an IIS Http Module (previously this was included in the core package). The Kentor.AuthServices.Mvc package contains the MVC controller and the Kentor.AuthServices.Owin package contains the Owin middleware.

Once the nuget packages are installed you must provide configuration either through code or through web.config sections. See configuration for details.

Troubleshooting

  • Check the issues archive.
  • Check the SAML2 specification, starting with the core section.
  • Log your actual SAML2 conversation with SAML Chrome Panel or SAML Tracer for Firefox.
  • Connect an ILoggerAdapter to your SPOptions.Logger. If you are using the OWIN middleware this is done for you automatically and you can see the output in the OWIN/Katana logging.
  • Last but not least, download the AuthServices source and check out what's really happening.

Saml2AuthenticationModule

The Saml2AuthenticationModule is modeled after the WSFederationAuthenticationModule to provide Saml2 authentication to IIS web sites. In many cases it should just be configured in and work without any code written in the application at all (even though providing an own ClaimsAuthenticationManager for claims translation is highly recommended).

Mvc Controller

The MVC package contains an MVC controller that will be accessible in your application just by installing the package in the application. For MVC applications a controller is preferred over using the authentication module as it integrates with MVC's error handling.

Owin Middleware

The Owin middleware is modeled after the external authentication modules for social login (such as Google, Facebook, Twitter). This allows easy integration with ASP.NET Identity for keeping application specific user and role information. See the Owin Middleware page for information on how to set up and use the middleware.

Stub Idp

The solution also contains a stub (i.e. dummy) identity provider that can be used for testing. Download the solution, or use the instance that's provided for free at http://stubidp.kentor.se.

Protocol Classes

The protocol handling classes are available as a public API as well, making it possible to reuse some of the internals for writing your own service provider or identity provider.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.