Coder Social home page Coder Social logo

gtiwari333 / spring-security-saml-test-identity-provider-and-service-provider Goto Github PK

View Code? Open in Web Editor NEW
27.0 5.0 15.0 55 KB

SAML Identity Provider and Service Provider for testing purpose. Powered by Spring Boot.

Home Page: http://ganeshtiwaridotcomdotnp.blogspot.com/

Java 82.63% HTML 17.37%
java spring spring-security saml2 saml-service-provider saml-identity-provider

spring-security-saml-test-identity-provider-and-service-provider's Introduction

Spring Security SAML example

This project demonstrates both IDP initiated and SP initiated SSO flows.

Modules

Identity Provider

Service Provider

Service Provider SB3

How to Test

Look at UserUtils class to generate custom SAML attributes

  • Usernames: user002@email, user003@email
  • password: pass

generate a private key with the correct length

openssl genrsa -out pk.key 1024

generate corresponding public key

openssl pkcs8 -topk8 -inform pem -in pk.key -outform pem -nocrypt -out pk.pem

optional: create a self-signed certificate

openssl req -new -x509 -key pk.pem -out cert.pem -days 360

spring-security-saml-test-identity-provider-and-service-provider's People

Contributors

gtiwari333 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

spring-security-saml-test-identity-provider-and-service-provider's Issues

Custom Attributes not working

The Custom Attribute are not working. It is because of different method signature of the the overridden getAssertion method.

I want to configure sso url.

In IDP , application yaml file, there is no option to configure sso url where the service providers will land to the login page of idp?.

The following error occurred while the server was running.

Failed to bind properties under 'saml2.identity-provider' to org.springframework.security.saml.provider.identity.config.LocalIdentityProviderConfiguration:

Property: saml2.identity-provider.sign-assertions
Value: "true"
Origin: class path resource [application.yml] - 37:22
Reason: java.lang.reflect.InaccessibleObjectException: Unable to make field private final java.lang.String java.lang.Enum.name accessible: module java.base does not "opens java.lang" to unnamed module @7526515b

Failed to bind properties under 'saml2.service-provider' to org.springframework.security.saml.provider.service.config.LocalServiceProviderConfiguration:

Property: saml2.service-provider.name-ids[1]
Value: "urn:oasis:names:tc:SAML:1.1:nameid-format:emailAddress"
Origin: class path resource [application.yml] - 45:9
Reason: java.lang.reflect.InaccessibleObjectException: Unable to make field private final java.lang.String java.lang.Enum.name accessible: module java.base does not "opens java.lang" to unnamed module @78e4deb0

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.