[JBoss JIRA] (ELY-1453) Sigtest: In public API non public class RealmDefiniteOutcomeAuthenticationEvent is used
by Martin Choma (JIRA)
[ https://issues.jboss.org/browse/ELY-1453?page=com.atlassian.jira.plugin.s... ]
Martin Choma updated ELY-1453:
------------------------------
Description:
SigTest check reveals:
{noformat}
Hidden class found:
org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
in method public
{org.wildfly.security.auth.server.event.RealmEventVisitor%1}
org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
in class org.wildfly.security.auth.server.event.RealmEventVisitor
{noformat}
Fix could be as easy as make RealmDefiniteOutcomeAuthenticationEvent public.
But I still left for developers judgement if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public originally.
was:
SigTest check reveals:
{noformat}
Hidden class found:
org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
in method public
{org.wildfly.security.auth.server.event.RealmEventVisitor%1}
org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
in class org.wildfly.security.auth.server.event.RealmEventVisitor
{noformat}
Fix could be as easy as make RealmDefiniteOutcomeAuthenticationEvent public.
But I still left for developers justification if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public originally.
> Sigtest: In public API non public class RealmDefiniteOutcomeAuthenticationEvent is used
> ---------------------------------------------------------------------------------------
>
> Key: ELY-1453
> URL: https://issues.jboss.org/browse/ELY-1453
> Project: WildFly Elytron
> Issue Type: Bug
> Components: API / SPI
> Affects Versions: 1.2.0.Beta10
> Reporter: Martin Choma
>
> SigTest check reveals:
> {noformat}
> Hidden class found:
> org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
> in method public
> {org.wildfly.security.auth.server.event.RealmEventVisitor%1}
> org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
> in class org.wildfly.security.auth.server.event.RealmEventVisitor
> {noformat}
> Fix could be as easy as make RealmDefiniteOutcomeAuthenticationEvent public.
> But I still left for developers judgement if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public originally.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 5 months
[JBoss JIRA] (ELY-1453) Sigtest: In public API non public class RealmDefiniteOutcomeAuthenticationEvent is used
by Martin Choma (JIRA)
[ https://issues.jboss.org/browse/ELY-1453?page=com.atlassian.jira.plugin.s... ]
Martin Choma updated ELY-1453:
------------------------------
Description:
SigTest check reveals:
{noformat}
Hidden class found:
org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
in method public
{org.wildfly.security.auth.server.event.RealmEventVisitor%1}
org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
in class org.wildfly.security.auth.server.event.RealmEventVisitor
{noformat}
Fix could be as easy as make RealmDefiniteOutcomeAuthenticationEvent public.
But I still left for developers justification if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public originaly.
was:
SigTest check reveals:
{noformat}
Hidden class found:
org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
in method public
{org.wildfly.security.auth.server.event.RealmEventVisitor%1}
org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
in class org.wildfly.security.auth.server.event.RealmEventVisitor
{noformat}
Fix could be easy as make RealmDefiniteOutcomeAuthenticationEvent public.
But I still left for developers justification if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public.
> Sigtest: In public API non public class RealmDefiniteOutcomeAuthenticationEvent is used
> ---------------------------------------------------------------------------------------
>
> Key: ELY-1453
> URL: https://issues.jboss.org/browse/ELY-1453
> Project: WildFly Elytron
> Issue Type: Bug
> Components: API / SPI
> Affects Versions: 1.2.0.Beta10
> Reporter: Martin Choma
>
> SigTest check reveals:
> {noformat}
> Hidden class found:
> org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
> in method public
> {org.wildfly.security.auth.server.event.RealmEventVisitor%1}
> org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
> in class org.wildfly.security.auth.server.event.RealmEventVisitor
> {noformat}
> Fix could be as easy as make RealmDefiniteOutcomeAuthenticationEvent public.
> But I still left for developers justification if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public originaly.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 5 months
[JBoss JIRA] (ELY-1453) Sigtest: In public API non public class RealmDefiniteOutcomeAuthenticationEvent is used
by Martin Choma (JIRA)
[ https://issues.jboss.org/browse/ELY-1453?page=com.atlassian.jira.plugin.s... ]
Martin Choma updated ELY-1453:
------------------------------
Description:
SigTest check reveals:
{noformat}
Hidden class found:
org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
in method public
{org.wildfly.security.auth.server.event.RealmEventVisitor%1}
org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
in class org.wildfly.security.auth.server.event.RealmEventVisitor
{noformat}
Fix could be as easy as make RealmDefiniteOutcomeAuthenticationEvent public.
But I still left for developers justification if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public originally.
was:
SigTest check reveals:
{noformat}
Hidden class found:
org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
in method public
{org.wildfly.security.auth.server.event.RealmEventVisitor%1}
org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
in class org.wildfly.security.auth.server.event.RealmEventVisitor
{noformat}
Fix could be as easy as make RealmDefiniteOutcomeAuthenticationEvent public.
But I still left for developers justification if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public originaly.
> Sigtest: In public API non public class RealmDefiniteOutcomeAuthenticationEvent is used
> ---------------------------------------------------------------------------------------
>
> Key: ELY-1453
> URL: https://issues.jboss.org/browse/ELY-1453
> Project: WildFly Elytron
> Issue Type: Bug
> Components: API / SPI
> Affects Versions: 1.2.0.Beta10
> Reporter: Martin Choma
>
> SigTest check reveals:
> {noformat}
> Hidden class found:
> org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
> in method public
> {org.wildfly.security.auth.server.event.RealmEventVisitor%1}
> org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
> in class org.wildfly.security.auth.server.event.RealmEventVisitor
> {noformat}
> Fix could be as easy as make RealmDefiniteOutcomeAuthenticationEvent public.
> But I still left for developers justification if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public originally.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 5 months
[JBoss JIRA] (ELY-1453) Sigtest: In public API non public class RealmDefiniteOutcomeAuthenticationEvent is used
by Martin Choma (JIRA)
Martin Choma created ELY-1453:
---------------------------------
Summary: Sigtest: In public API non public class RealmDefiniteOutcomeAuthenticationEvent is used
Key: ELY-1453
URL: https://issues.jboss.org/browse/ELY-1453
Project: WildFly Elytron
Issue Type: Bug
Components: API / SPI
Affects Versions: 1.2.0.Beta10
Reporter: Martin Choma
SigTest check reveals:
{noformat}
Hidden class found:
org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent
in method public
{org.wildfly.security.auth.server.event.RealmEventVisitor%1}
org.wildfly.security.auth.server.event.RealmEventVisitor.handleDefiniteOutcomeAuthenticationEvent(org.wildfly.security.auth.server.event.RealmDefiniteOutcomeAuthenticationEvent,{org.wildfly.security.auth.server.event.RealmEventVisitor%0})
in class org.wildfly.security.auth.server.event.RealmEventVisitor
{noformat}
Fix could be easy as make RealmDefiniteOutcomeAuthenticationEvent public.
But I still left for developers justification if make constructor of RealmDefiniteOutcomeAuthenticationEvent package private. Thus RealmDefiniteOutcomeAuthenticationEvent can't be inherited from. If that was reason for not marking this class as public.
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 5 months
[JBoss JIRA] (WFLY-9561) WildFly - Elytron - Programmatic login
by Martin Choma (JIRA)
[ https://issues.jboss.org/browse/WFLY-9561?page=com.atlassian.jira.plugin.... ]
Martin Choma commented on WFLY-9561:
------------------------------------
+1 for test first strategy fixes :)
> WildFly - Elytron - Programmatic login
> --------------------------------------
>
> Key: WFLY-9561
> URL: https://issues.jboss.org/browse/WFLY-9561
> Project: WildFly
> Issue Type: Bug
> Components: Security, Web (Undertow)
> Affects Versions: 11.0.0.Final
> Reporter: Stanislav Grushevskiy
> Assignee: Darran Lofthouse
> Fix For: 12.0.0.Alpha1
>
> Attachments: test.zip
>
>
> If Elytron security domain (in WildFly 11, default "standalone.xml") is used for programmatic login, cookie "JSESSIONID" is not set in response. So following requests are sent without "JSESSIONID".
> @Path("login")
> public class LoginService {
> @Context
> private HttpServletRequest request;
> @POST
> public void login(LoginForm form) throws ServletException {
> request.login(form.getLogin(), form.getPassword());
> }
> }
> <?xml version="1.0" encoding="UTF-8"?>
> <jboss-web>
> <security-domain>application-security-domain</security-domain>
> </jboss-web>
> If I add manual interaction with Session in login method, "JSESSIONID" is set.
> OR
> If I delete "jboss-web.xml" and default old "ApplicationRealm" is used, "JSESSIONID" is set.
> "JSESSIONID" is set in WildFly 10.0.0.Final and in 10.1.0.Final, because there is no Elytron there and "ApplicationRealm" is used.
> Test project is attached, create application user (add-user.sh) with username "wildfly" and password "wildfly".
> Run "mvn wildfly:deploy".
> Go to http://localhost:8080/test/test.html and press "Login" button and then "Check Auth".
> In this project you can uncomment code below (// uncomment the row below to get it working with elytron) to add session interaction or comment code below (<!-- comment the row below to use default ApplicationRealm from old security system, not elytron -->) to use old "ApplicationRealm".
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 5 months
[JBoss JIRA] (WFLY-9561) WildFly - Elytron - Programmatic login
by Darran Lofthouse (JIRA)
[ https://issues.jboss.org/browse/WFLY-9561?page=com.atlassian.jira.plugin.... ]
Darran Lofthouse commented on WFLY-9561:
----------------------------------------
Sure I was going to start by looking at a test case first, looks like that may be the one to change but I was the test to be executed during normal test runs and not the -Delytron test run.
> WildFly - Elytron - Programmatic login
> --------------------------------------
>
> Key: WFLY-9561
> URL: https://issues.jboss.org/browse/WFLY-9561
> Project: WildFly
> Issue Type: Bug
> Components: Security, Web (Undertow)
> Affects Versions: 11.0.0.Final
> Reporter: Stanislav Grushevskiy
> Assignee: Darran Lofthouse
> Fix For: 12.0.0.Alpha1
>
> Attachments: test.zip
>
>
> If Elytron security domain (in WildFly 11, default "standalone.xml") is used for programmatic login, cookie "JSESSIONID" is not set in response. So following requests are sent without "JSESSIONID".
> @Path("login")
> public class LoginService {
> @Context
> private HttpServletRequest request;
> @POST
> public void login(LoginForm form) throws ServletException {
> request.login(form.getLogin(), form.getPassword());
> }
> }
> <?xml version="1.0" encoding="UTF-8"?>
> <jboss-web>
> <security-domain>application-security-domain</security-domain>
> </jboss-web>
> If I add manual interaction with Session in login method, "JSESSIONID" is set.
> OR
> If I delete "jboss-web.xml" and default old "ApplicationRealm" is used, "JSESSIONID" is set.
> "JSESSIONID" is set in WildFly 10.0.0.Final and in 10.1.0.Final, because there is no Elytron there and "ApplicationRealm" is used.
> Test project is attached, create application user (add-user.sh) with username "wildfly" and password "wildfly".
> Run "mvn wildfly:deploy".
> Go to http://localhost:8080/test/test.html and press "Login" button and then "Check Auth".
> In this project you can uncomment code below (// uncomment the row below to get it working with elytron) to add session interaction or comment code below (<!-- comment the row below to use default ApplicationRealm from old security system, not elytron -->) to use old "ApplicationRealm".
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 5 months
[JBoss JIRA] (WFLY-9561) WildFly - Elytron - Programmatic login
by Martin Choma (JIRA)
[ https://issues.jboss.org/browse/WFLY-9561?page=com.atlassian.jira.plugin.... ]
Martin Choma commented on WFLY-9561:
------------------------------------
Could fix contain also test for it:
{noformat}
diff --git a/testsuite/integration/web/src/test/java/org/jboss/as/test/integration/web/security/servlet3/WebSecurityProgrammaticLoginTestCase.java b/testsuite/integration/web/src/test/java/org/jboss/as/test/integration/web/security/servlet3/WebSecurityProgrammaticLoginTestCase.java
index 3685ca7..c381fa1 100644
--- a/testsuite/integration/web/src/test/java/org/jboss/as/test/integration/web/security/servlet3/WebSecurityProgrammaticLoginTestCase.java
+++ b/testsuite/integration/web/src/test/java/org/jboss/as/test/integration/web/security/servlet3/WebSecurityProgrammaticLoginTestCase.java
@@ -75,6 +75,8 @@ public class WebSecurityProgrammaticLoginTestCase extends WebSecurityPasswordBas
try (CloseableHttpClient httpclient = HttpClients.createDefault()) {
HttpResponse res = httpclient.execute(new HttpGet(managementClient.getWebUri() + "/" + getContextPath() +
"/login/?username=" + user + "&password=" + pass));
+ Assert.assertNotNull(res.getFirstHeader("Set-Cookie"));
+ Assert.assertTrue(res.getFirstHeader("Set-Cookie").getValue().contains("JSESSIONID"));
Assert.assertEquals(expectedStatusCode, res.getStatusLine().getStatusCode());
}
}
{noformat}
> WildFly - Elytron - Programmatic login
> --------------------------------------
>
> Key: WFLY-9561
> URL: https://issues.jboss.org/browse/WFLY-9561
> Project: WildFly
> Issue Type: Bug
> Components: Security, Web (Undertow)
> Affects Versions: 11.0.0.Final
> Reporter: Stanislav Grushevskiy
> Assignee: Darran Lofthouse
> Fix For: 12.0.0.Alpha1
>
> Attachments: test.zip
>
>
> If Elytron security domain (in WildFly 11, default "standalone.xml") is used for programmatic login, cookie "JSESSIONID" is not set in response. So following requests are sent without "JSESSIONID".
> @Path("login")
> public class LoginService {
> @Context
> private HttpServletRequest request;
> @POST
> public void login(LoginForm form) throws ServletException {
> request.login(form.getLogin(), form.getPassword());
> }
> }
> <?xml version="1.0" encoding="UTF-8"?>
> <jboss-web>
> <security-domain>application-security-domain</security-domain>
> </jboss-web>
> If I add manual interaction with Session in login method, "JSESSIONID" is set.
> OR
> If I delete "jboss-web.xml" and default old "ApplicationRealm" is used, "JSESSIONID" is set.
> "JSESSIONID" is set in WildFly 10.0.0.Final and in 10.1.0.Final, because there is no Elytron there and "ApplicationRealm" is used.
> Test project is attached, create application user (add-user.sh) with username "wildfly" and password "wildfly".
> Run "mvn wildfly:deploy".
> Go to http://localhost:8080/test/test.html and press "Login" button and then "Check Auth".
> In this project you can uncomment code below (// uncomment the row below to get it working with elytron) to add session interaction or comment code below (<!-- comment the row below to use default ApplicationRealm from old security system, not elytron -->) to use old "ApplicationRealm".
--
This message was sent by Atlassian JIRA
(v7.5.0#75005)
8 years, 5 months