{"action":"created","comment":{"url":"https://api.github.com/repos/pac4j/pac4j/pulls/comments/46260199","id":46260199,"diff_hunk":"@@ -15,285 +15,155 @@\n  */\n package org.pac4j.saml.client;\n \n-import org.opensaml.saml.common.xml.SAMLConstants;\n-import org.opensaml.xmlsec.config.DefaultSecurityConfigurationBootstrap;\n-import org.opensaml.xmlsec.impl.BasicSignatureSigningConfiguration;\n-import org.pac4j.core.util.CommonHelper;\n-import org.pac4j.saml.storage.EmptyStorageFactory;\n-import org.pac4j.saml.storage.SAMLMessageStorageFactory;\n+import org.pac4j.core.context.WebContext;\n \n-import java.util.ArrayList;\n-import java.util.Collection;\n-import java.util.List;\n \n /**\n  * The {@link SAML2ClientConfiguration} is responsible for...\n  * capturing client settings and passing them around.\n+ * \n+ * This configuration type is intended to be initialized statically, e.g. in Java code or in Spring context.\n  *\n  * @author Misagh Moayyed\n  * @since 1.7\n  */\n-public final class SAML2ClientConfiguration implements Cloneable {\n+public final class SAML2ClientConfiguration extends AbstractSAML2ClientConfiguration {\n \n     private String keystorePath;\n \n-    private String keystorePassword;\n-\n-    private String privateKeyPassword;\n-\n     private String identityProviderMetadataPath;\n \n-    private String identityProviderEntityId;\n-\n-    private String serviceProviderEntityId;\n-\n-    private int maximumAuthenticationLifetime;\n-\n-    private boolean forceAuth = false;\n-\n-    private String comparisonType = null;\n-\n-    private String destinationBindingType = SAMLConstants.SAML2_POST_BINDING_URI;\n-\n-    private String authnContextClassRef = null;\n-\n-    private String nameIdPolicyFormat = null;\n-\n-    private String serviceProviderMetadataPath;\n-\n-    private boolean forceServiceProviderMetadataGeneration;\n-\n-    private SAMLMessageStorageFactory samlMessageStorageFactory = new EmptyStorageFactory();\n \n-    public SAML2ClientConfiguration() {}\n-\n-\n-    private Collection<String> blackListedSignatureSigningAlgorithms;\n-    private List<String> signatureAlgorithms;\n-    private List<String> signatureReferenceDigestMethods;\n-    private String signatureCanonicalizationAlgorithm;\n-\n-    public SAML2ClientConfiguration(final String keystorePath, final String keystorePassword,\n-                                    final String privateKeyPassword, final String identityProviderMetadataPath) {\n-        this(keystorePath, keystorePassword, privateKeyPassword, identityProviderMetadataPath, null, null);\n+    // ------------------------------------------------------------------------------------------------------------------------------------\n+    \n+    \n+    public SAML2ClientConfiguration() {\n+    \tsuper();\n     }\n \n     public SAML2ClientConfiguration(final String keystorePath, final String keystorePassword,\n-                                    final String privateKeyPassword, final String identityProviderMetadataPath,\n-                                    final String identityProviderEntityId, final String serviceProviderEntityId) {\n-        this.keystorePath = keystorePath;\n-        this.keystorePassword = keystorePassword;\n-        this.privateKeyPassword = privateKeyPassword;\n-        this.identityProviderMetadataPath = identityProviderMetadataPath;\n-        this.identityProviderEntityId = identityProviderEntityId;\n-        this.serviceProviderEntityId = serviceProviderEntityId;\n-\n-        CommonHelper.assertNotBlank(\"keystorePath\", this.keystorePath);","path":"pac4j-saml/src/main/java/org/pac4j/saml/client/SAML2ClientConfiguration.java","position":86,"original_position":86,"commit_id":"924476c9a1b20ac28628f3d1ba1482a1b79add79","original_commit_id":"924476c9a1b20ac28628f3d1ba1482a1b79add79","user":{"login":"leleuj","id":1038508,"avatar_url":"https://avatars.githubusercontent.com/u/1038508?v=3","gravatar_id":"","url":"https://api.github.com/users/leleuj","html_url":"https://github.com/leleuj","followers_url":"https://api.github.com/users/leleuj/followers","following_url":"https://api.github.com/users/leleuj/following{/other_user}","gists_url":"https://api.github.com/users/leleuj/gists{/gist_id}","starred_url":"https://api.github.com/users/leleuj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/leleuj/subscriptions","organizations_url":"https://api.github.com/users/leleuj/orgs","repos_url":"https://api.github.com/users/leleuj/repos","events_url":"https://api.github.com/users/leleuj/events{/privacy}","received_events_url":"https://api.github.com/users/leleuj/received_events","type":"User","site_admin":false},"body":"Where / why  are these checks gone?","created_at":"2015-12-01T10:10:49Z","updated_at":"2015-12-01T10:10:49Z","html_url":"https://github.com/pac4j/pac4j/pull/351#discussion_r46260199","pull_request_url":"https://api.github.com/repos/pac4j/pac4j/pulls/351","_links":{"self":{"href":"https://api.github.com/repos/pac4j/pac4j/pulls/comments/46260199"},"html":{"href":"https://github.com/pac4j/pac4j/pull/351#discussion_r46260199"},"pull_request":{"href":"https://api.github.com/repos/pac4j/pac4j/pulls/351"}}},"pull_request":{"url":"https://api.github.com/repos/pac4j/pac4j/pulls/351","id":50266910,"html_url":"https://github.com/pac4j/pac4j/pull/351","diff_url":"https://github.com/pac4j/pac4j/pull/351.diff","patch_url":"https://github.com/pac4j/pac4j/pull/351.patch","issue_url":"https://api.github.com/repos/pac4j/pac4j/issues/351","number":351,"state":"open","locked":false,"title":"New feature: Database configuration of SAML clients","user":{"login":"jkacer","id":8087002,"avatar_url":"https://avatars.githubusercontent.com/u/8087002?v=3","gravatar_id":"","url":"https://api.github.com/users/jkacer","html_url":"https://github.com/jkacer","followers_url":"https://api.github.com/users/jkacer/followers","following_url":"https://api.github.com/users/jkacer/following{/other_user}","gists_url":"https://api.github.com/users/jkacer/gists{/gist_id}","starred_url":"https://api.github.com/users/jkacer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jkacer/subscriptions","organizations_url":"https://api.github.com/users/jkacer/orgs","repos_url":"https://api.github.com/users/jkacer/repos","events_url":"https://api.github.com/users/jkacer/events{/privacy}","received_events_url":"https://api.github.com/users/jkacer/received_events","type":"User","site_admin":false},"body":"Added a new Maven module with SAML clients able to be initialized from a relational database.\r\nThere is quite a lot of duplicate code between PAC4J-SAML and PAC4J-SAML-DB, further changes are assumed that should remove most duplicates.","created_at":"2015-11-10T15:25:39Z","updated_at":"2015-12-01T10:10:49Z","closed_at":null,"merged_at":null,"merge_commit_sha":"5c7bb01450845f47a244b70ab9ffe5fa7df6a52d","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/pac4j/pac4j/pulls/351/commits","review_comments_url":"https://api.github.com/repos/pac4j/pac4j/pulls/351/comments","review_comment_url":"https://api.github.com/repos/pac4j/pac4j/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pac4j/pac4j/issues/351/comments","statuses_url":"https://api.github.com/repos/pac4j/pac4j/statuses/924476c9a1b20ac28628f3d1ba1482a1b79add79","head":{"label":"jkacer:feature/saml-db-cfg","ref":"feature/saml-db-cfg","sha":"924476c9a1b20ac28628f3d1ba1482a1b79add79","user":{"login":"jkacer","id":8087002,"avatar_url":"https://avatars.githubusercontent.com/u/8087002?v=3","gravatar_id":"","url":"https://api.github.com/users/jkacer","html_url":"https://github.com/jkacer","followers_url":"https://api.github.com/users/jkacer/followers","following_url":"https://api.github.com/users/jkacer/following{/other_user}","gists_url":"https://api.github.com/users/jkacer/gists{/gist_id}","starred_url":"https://api.github.com/users/jkacer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jkacer/subscriptions","organizations_url":"https://api.github.com/users/jkacer/orgs","repos_url":"https://api.github.com/users/jkacer/repos","events_url":"https://api.github.com/users/jkacer/events{/privacy}","received_events_url":"https://api.github.com/users/jkacer/received_events","type":"User","site_admin":false},"repo":{"id":23578999,"name":"pac4j","full_name":"jkacer/pac4j","owner":{"login":"jkacer","id":8087002,"avatar_url":"https://avatars.githubusercontent.com/u/8087002?v=3","gravatar_id":"","url":"https://api.github.com/users/jkacer","html_url":"https://github.com/jkacer","followers_url":"https://api.github.com/users/jkacer/followers","following_url":"https://api.github.com/users/jkacer/following{/other_user}","gists_url":"https://api.github.com/users/jkacer/gists{/gist_id}","starred_url":"https://api.github.com/users/jkacer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jkacer/subscriptions","organizations_url":"https://api.github.com/users/jkacer/orgs","repos_url":"https://api.github.com/users/jkacer/repos","events_url":"https://api.github.com/users/jkacer/events{/privacy}","received_events_url":"https://api.github.com/users/jkacer/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jkacer/pac4j","description":"Profile & Authentication Client in Java for CAS, OAuth, OpenID, SAML, HTTP... protocols","fork":true,"url":"https://api.github.com/repos/jkacer/pac4j","forks_url":"https://api.github.com/repos/jkacer/pac4j/forks","keys_url":"https://api.github.com/repos/jkacer/pac4j/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jkacer/pac4j/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jkacer/pac4j/teams","hooks_url":"https://api.github.com/repos/jkacer/pac4j/hooks","issue_events_url":"https://api.github.com/repos/jkacer/pac4j/issues/events{/number}","events_url":"https://api.github.com/repos/jkacer/pac4j/events","assignees_url":"https://api.github.com/repos/jkacer/pac4j/assignees{/user}","branches_url":"https://api.github.com/repos/jkacer/pac4j/branches{/branch}","tags_url":"https://api.github.com/repos/jkacer/pac4j/tags","blobs_url":"https://api.github.com/repos/jkacer/pac4j/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jkacer/pac4j/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jkacer/pac4j/git/refs{/sha}","trees_url":"https://api.github.com/repos/jkacer/pac4j/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jkacer/pac4j/statuses/{sha}","languages_url":"https://api.github.com/repos/jkacer/pac4j/languages","stargazers_url":"https://api.github.com/repos/jkacer/pac4j/stargazers","contributors_url":"https://api.github.com/repos/jkacer/pac4j/contributors","subscribers_url":"https://api.github.com/repos/jkacer/pac4j/subscribers","subscription_url":"https://api.github.com/repos/jkacer/pac4j/subscription","commits_url":"https://api.github.com/repos/jkacer/pac4j/commits{/sha}","git_commits_url":"https://api.github.com/repos/jkacer/pac4j/git/commits{/sha}","comments_url":"https://api.github.com/repos/jkacer/pac4j/comments{/number}","issue_comment_url":"https://api.github.com/repos/jkacer/pac4j/issues/comments{/number}","contents_url":"https://api.github.com/repos/jkacer/pac4j/contents/{+path}","compare_url":"https://api.github.com/repos/jkacer/pac4j/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jkacer/pac4j/merges","archive_url":"https://api.github.com/repos/jkacer/pac4j/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jkacer/pac4j/downloads","issues_url":"https://api.github.com/repos/jkacer/pac4j/issues{/number}","pulls_url":"https://api.github.com/repos/jkacer/pac4j/pulls{/number}","milestones_url":"https://api.github.com/repos/jkacer/pac4j/milestones{/number}","notifications_url":"https://api.github.com/repos/jkacer/pac4j/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jkacer/pac4j/labels{/name}","releases_url":"https://api.github.com/repos/jkacer/pac4j/releases{/id}","created_at":"2014-09-02T13:08:56Z","updated_at":"2014-09-03T08:47:46Z","pushed_at":"2015-11-30T09:51:24Z","git_url":"git://github.com/jkacer/pac4j.git","ssh_url":"git@github.com:jkacer/pac4j.git","clone_url":"https://github.com/jkacer/pac4j.git","svn_url":"https://github.com/jkacer/pac4j","homepage":"http://www.pac4j.org","size":12165,"stargazers_count":0,"watchers_count":0,"language":"Java","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"pac4j:master","ref":"master","sha":"7b0efa40194d888216de82af9c8867b57f54475f","user":{"login":"pac4j","id":7540865,"avatar_url":"https://avatars.githubusercontent.com/u/7540865?v=3","gravatar_id":"","url":"https://api.github.com/users/pac4j","html_url":"https://github.com/pac4j","followers_url":"https://api.github.com/users/pac4j/followers","following_url":"https://api.github.com/users/pac4j/following{/other_user}","gists_url":"https://api.github.com/users/pac4j/gists{/gist_id}","starred_url":"https://api.github.com/users/pac4j/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pac4j/subscriptions","organizations_url":"https://api.github.com/users/pac4j/orgs","repos_url":"https://api.github.com/users/pac4j/repos","events_url":"https://api.github.com/users/pac4j/events{/privacy}","received_events_url":"https://api.github.com/users/pac4j/received_events","type":"Organization","site_admin":false},"repo":{"id":3291848,"name":"pac4j","full_name":"pac4j/pac4j","owner":{"login":"pac4j","id":7540865,"avatar_url":"https://avatars.githubusercontent.com/u/7540865?v=3","gravatar_id":"","url":"https://api.github.com/users/pac4j","html_url":"https://github.com/pac4j","followers_url":"https://api.github.com/users/pac4j/followers","following_url":"https://api.github.com/users/pac4j/following{/other_user}","gists_url":"https://api.github.com/users/pac4j/gists{/gist_id}","starred_url":"https://api.github.com/users/pac4j/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pac4j/subscriptions","organizations_url":"https://api.github.com/users/pac4j/orgs","repos_url":"https://api.github.com/users/pac4j/repos","events_url":"https://api.github.com/users/pac4j/events{/privacy}","received_events_url":"https://api.github.com/users/pac4j/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/pac4j/pac4j","description":"Security engine for Java (authentication, authorization, multi frameworks)","fork":false,"url":"https://api.github.com/repos/pac4j/pac4j","forks_url":"https://api.github.com/repos/pac4j/pac4j/forks","keys_url":"https://api.github.com/repos/pac4j/pac4j/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pac4j/pac4j/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pac4j/pac4j/teams","hooks_url":"https://api.github.com/repos/pac4j/pac4j/hooks","issue_events_url":"https://api.github.com/repos/pac4j/pac4j/issues/events{/number}","events_url":"https://api.github.com/repos/pac4j/pac4j/events","assignees_url":"https://api.github.com/repos/pac4j/pac4j/assignees{/user}","branches_url":"https://api.github.com/repos/pac4j/pac4j/branches{/branch}","tags_url":"https://api.github.com/repos/pac4j/pac4j/tags","blobs_url":"https://api.github.com/repos/pac4j/pac4j/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pac4j/pac4j/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pac4j/pac4j/git/refs{/sha}","trees_url":"https://api.github.com/repos/pac4j/pac4j/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pac4j/pac4j/statuses/{sha}","languages_url":"https://api.github.com/repos/pac4j/pac4j/languages","stargazers_url":"https://api.github.com/repos/pac4j/pac4j/stargazers","contributors_url":"https://api.github.com/repos/pac4j/pac4j/contributors","subscribers_url":"https://api.github.com/repos/pac4j/pac4j/subscribers","subscription_url":"https://api.github.com/repos/pac4j/pac4j/subscription","commits_url":"https://api.github.com/repos/pac4j/pac4j/commits{/sha}","git_commits_url":"https://api.github.com/repos/pac4j/pac4j/git/commits{/sha}","comments_url":"https://api.github.com/repos/pac4j/pac4j/comments{/number}","issue_comment_url":"https://api.github.com/repos/pac4j/pac4j/issues/comments{/number}","contents_url":"https://api.github.com/repos/pac4j/pac4j/contents/{+path}","compare_url":"https://api.github.com/repos/pac4j/pac4j/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pac4j/pac4j/merges","archive_url":"https://api.github.com/repos/pac4j/pac4j/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pac4j/pac4j/downloads","issues_url":"https://api.github.com/repos/pac4j/pac4j/issues{/number}","pulls_url":"https://api.github.com/repos/pac4j/pac4j/pulls{/number}","milestones_url":"https://api.github.com/repos/pac4j/pac4j/milestones{/number}","notifications_url":"https://api.github.com/repos/pac4j/pac4j/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pac4j/pac4j/labels{/name}","releases_url":"https://api.github.com/repos/pac4j/pac4j/releases{/id}","created_at":"2012-01-28T17:04:12Z","updated_at":"2015-11-23T04:08:27Z","pushed_at":"2015-11-30T14:03:24Z","git_url":"git://github.com/pac4j/pac4j.git","ssh_url":"git@github.com:pac4j/pac4j.git","clone_url":"https://github.com/pac4j/pac4j.git","svn_url":"https://github.com/pac4j/pac4j","homepage":"http://www.pac4j.org","size":17122,"stargazers_count":403,"watchers_count":403,"language":"Java","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":144,"mirror_url":null,"open_issues_count":24,"forks":144,"open_issues":24,"watchers":403,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pac4j/pac4j/pulls/351"},"html":{"href":"https://github.com/pac4j/pac4j/pull/351"},"issue":{"href":"https://api.github.com/repos/pac4j/pac4j/issues/351"},"comments":{"href":"https://api.github.com/repos/pac4j/pac4j/issues/351/comments"},"review_comments":{"href":"https://api.github.com/repos/pac4j/pac4j/pulls/351/comments"},"review_comment":{"href":"https://api.github.com/repos/pac4j/pac4j/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pac4j/pac4j/pulls/351/commits"},"statuses":{"href":"https://api.github.com/repos/pac4j/pac4j/statuses/924476c9a1b20ac28628f3d1ba1482a1b79add79"}}}}