Enable WebAuthn tests for Firefox (#30374)
Closes #22075 Signed-off-by: Martin Bartoš <mabartos@redhat.com>
This commit is contained in:
parent
bb4d2ecf92
commit
5ad3abaa96
23 changed files with 54 additions and 20 deletions
2
.github/workflows/ci.yml
vendored
2
.github/workflows/ci.yml
vendored
|
@ -686,7 +686,7 @@ jobs:
|
||||||
matrix:
|
matrix:
|
||||||
browser:
|
browser:
|
||||||
- chrome
|
- chrome
|
||||||
# - firefox disabled until https://github.com/keycloak/keycloak/issues/20777 is resolved
|
- firefox
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
|
@ -35,6 +35,7 @@ import org.keycloak.representations.idm.RequiredActionProviderRepresentation;
|
||||||
import org.keycloak.representations.idm.UserSessionRepresentation;
|
import org.keycloak.representations.idm.UserSessionRepresentation;
|
||||||
import org.keycloak.testsuite.actions.AbstractAppInitiatedActionTest;
|
import org.keycloak.testsuite.actions.AbstractAppInitiatedActionTest;
|
||||||
import org.keycloak.testsuite.admin.ApiUtil;
|
import org.keycloak.testsuite.admin.ApiUtil;
|
||||||
|
import org.keycloak.testsuite.arquillian.annotation.IgnoreBrowserDriver;
|
||||||
import org.keycloak.testsuite.pages.LoginUsernameOnlyPage;
|
import org.keycloak.testsuite.pages.LoginUsernameOnlyPage;
|
||||||
import org.keycloak.testsuite.pages.PasswordPage;
|
import org.keycloak.testsuite.pages.PasswordPage;
|
||||||
import org.keycloak.testsuite.updaters.RealmAttributeUpdater;
|
import org.keycloak.testsuite.updaters.RealmAttributeUpdater;
|
||||||
|
@ -46,6 +47,7 @@ import org.keycloak.testsuite.webauthn.authenticators.UseVirtualAuthenticators;
|
||||||
import org.keycloak.testsuite.webauthn.authenticators.VirtualAuthenticatorManager;
|
import org.keycloak.testsuite.webauthn.authenticators.VirtualAuthenticatorManager;
|
||||||
import org.keycloak.testsuite.webauthn.pages.WebAuthnRegisterPage;
|
import org.keycloak.testsuite.webauthn.pages.WebAuthnRegisterPage;
|
||||||
import org.openqa.selenium.WebDriver;
|
import org.openqa.selenium.WebDriver;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
@ -165,11 +167,13 @@ public class AppInitiatedActionWebAuthnTest extends AbstractAppInitiatedActionTe
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void proceedSetupWebAuthnLogoutOtherSessionsChecked() throws IOException {
|
public void proceedSetupWebAuthnLogoutOtherSessionsChecked() throws IOException {
|
||||||
testWebAuthnLogoutOtherSessions(true);
|
testWebAuthnLogoutOtherSessions(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void proceedSetupWebAuthnLogoutOtherSessionsNotChecked() throws IOException {
|
public void proceedSetupWebAuthnLogoutOtherSessionsNotChecked() throws IOException {
|
||||||
testWebAuthnLogoutOtherSessions(false);
|
testWebAuthnLogoutOtherSessions(false);
|
||||||
}
|
}
|
||||||
|
|
|
@ -39,7 +39,7 @@ import static org.hamcrest.MatcherAssert.assertThat;
|
||||||
*
|
*
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class VirtualAuthenticatorsManagerTest extends AbstractWebAuthnVirtualTest {
|
public class VirtualAuthenticatorsManagerTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Drone
|
@Drone
|
||||||
|
|
|
@ -61,7 +61,7 @@ import static org.keycloak.testsuite.webauthn.utils.PropertyRequirement.YES;
|
||||||
import static org.openqa.selenium.virtualauthenticator.VirtualAuthenticatorOptions.Protocol;
|
import static org.openqa.selenium.virtualauthenticator.VirtualAuthenticatorOptions.Protocol;
|
||||||
import static org.openqa.selenium.virtualauthenticator.VirtualAuthenticatorOptions.Transport;
|
import static org.openqa.selenium.virtualauthenticator.VirtualAuthenticatorOptions.Transport;
|
||||||
|
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class WebAuthnIdlessTest extends AbstractWebAuthnVirtualTest {
|
public class WebAuthnIdlessTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Rule
|
@Rule
|
||||||
|
|
|
@ -43,10 +43,10 @@ import static org.keycloak.testsuite.webauthn.utils.PropertyRequirement.YES;
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class WebAuthnPropertyTest extends AbstractWebAuthnVirtualTest {
|
public class WebAuthnPropertyTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
|
||||||
public void residentKey() throws IOException {
|
public void residentKey() throws IOException {
|
||||||
getVirtualAuthManager().useAuthenticator(DEFAULT_RESIDENT_KEY.getOptions());
|
getVirtualAuthManager().useAuthenticator(DEFAULT_RESIDENT_KEY.getOptions());
|
||||||
|
|
||||||
|
@ -82,7 +82,6 @@ public class WebAuthnPropertyTest extends AbstractWebAuthnVirtualTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
|
||||||
public void timeout() throws IOException {
|
public void timeout() throws IOException {
|
||||||
final Integer TIMEOUT = 3; //seconds
|
final Integer TIMEOUT = 3; //seconds
|
||||||
|
|
||||||
|
@ -106,7 +105,6 @@ public class WebAuthnPropertyTest extends AbstractWebAuthnVirtualTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
|
||||||
public void changeAuthenticatorProperties() throws IOException {
|
public void changeAuthenticatorProperties() throws IOException {
|
||||||
getVirtualAuthManager().useAuthenticator(DEFAULT_RESIDENT_KEY.getOptions());
|
getVirtualAuthManager().useAuthenticator(DEFAULT_RESIDENT_KEY.getOptions());
|
||||||
|
|
||||||
|
|
|
@ -39,6 +39,7 @@ import org.keycloak.representations.idm.RealmRepresentation;
|
||||||
import org.keycloak.representations.idm.UserRepresentation;
|
import org.keycloak.representations.idm.UserRepresentation;
|
||||||
import org.keycloak.testsuite.admin.AbstractAdminTest;
|
import org.keycloak.testsuite.admin.AbstractAdminTest;
|
||||||
import org.keycloak.testsuite.admin.ApiUtil;
|
import org.keycloak.testsuite.admin.ApiUtil;
|
||||||
|
import org.keycloak.testsuite.arquillian.annotation.IgnoreBrowserDriver;
|
||||||
import org.keycloak.testsuite.pages.AppPage.RequestType;
|
import org.keycloak.testsuite.pages.AppPage.RequestType;
|
||||||
import org.keycloak.testsuite.pages.ErrorPage;
|
import org.keycloak.testsuite.pages.ErrorPage;
|
||||||
import org.keycloak.testsuite.pages.LoginUsernameOnlyPage;
|
import org.keycloak.testsuite.pages.LoginUsernameOnlyPage;
|
||||||
|
@ -49,6 +50,7 @@ import org.keycloak.testsuite.util.FlowUtil;
|
||||||
import org.keycloak.testsuite.webauthn.pages.WebAuthnAuthenticatorsList;
|
import org.keycloak.testsuite.webauthn.pages.WebAuthnAuthenticatorsList;
|
||||||
import org.keycloak.testsuite.webauthn.updaters.WebAuthnRealmAttributeUpdater;
|
import org.keycloak.testsuite.webauthn.updaters.WebAuthnRealmAttributeUpdater;
|
||||||
import org.keycloak.util.JsonSerialization;
|
import org.keycloak.util.JsonSerialization;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
|
@ -97,6 +99,7 @@ public class WebAuthnRegisterAndLoginTest extends AbstractWebAuthnVirtualTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void registerUserSuccess() throws IOException {
|
public void registerUserSuccess() throws IOException {
|
||||||
String username = "registerUserSuccess";
|
String username = "registerUserSuccess";
|
||||||
String password = "password";
|
String password = "password";
|
||||||
|
@ -193,6 +196,7 @@ public class WebAuthnRegisterAndLoginTest extends AbstractWebAuthnVirtualTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void webAuthnPasswordlessAlternativeWithWebAuthnAndPassword() throws IOException {
|
public void webAuthnPasswordlessAlternativeWithWebAuthnAndPassword() throws IOException {
|
||||||
String userId = null;
|
String userId = null;
|
||||||
|
|
||||||
|
|
|
@ -36,7 +36,7 @@ import static org.keycloak.testsuite.webauthn.authenticators.DefaultVirtualAuthO
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class WebAuthnTransportsTest extends AbstractWebAuthnVirtualTest {
|
public class WebAuthnTransportsTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -45,7 +45,7 @@ public class WebAuthnErrorTest extends AbstractWebAuthnAccountTest {
|
||||||
protected WebAuthnErrorPage webAuthnErrorPage;
|
protected WebAuthnErrorPage webAuthnErrorPage;
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void errorPageWithTimeout() throws IOException {
|
public void errorPageWithTimeout() throws IOException {
|
||||||
final int timeoutSec = 3;
|
final int timeoutSec = 3;
|
||||||
final String authenticatorLabel = "authenticator";
|
final String authenticatorLabel = "authenticator";
|
||||||
|
|
|
@ -26,9 +26,11 @@ import org.keycloak.authentication.requiredactions.WebAuthnRegisterFactory;
|
||||||
import org.keycloak.models.credential.WebAuthnCredentialModel;
|
import org.keycloak.models.credential.WebAuthnCredentialModel;
|
||||||
import org.keycloak.representations.idm.CredentialRepresentation;
|
import org.keycloak.representations.idm.CredentialRepresentation;
|
||||||
import org.keycloak.representations.idm.RequiredActionProviderRepresentation;
|
import org.keycloak.representations.idm.RequiredActionProviderRepresentation;
|
||||||
|
import org.keycloak.testsuite.arquillian.annotation.IgnoreBrowserDriver;
|
||||||
import org.keycloak.testsuite.webauthn.pages.SigningInPage;
|
import org.keycloak.testsuite.webauthn.pages.SigningInPage;
|
||||||
import org.keycloak.testsuite.webauthn.pages.WebAuthnAuthenticatorsList;
|
import org.keycloak.testsuite.webauthn.pages.WebAuthnAuthenticatorsList;
|
||||||
import org.keycloak.theme.DateTimeFormatterUtil;
|
import org.keycloak.theme.DateTimeFormatterUtil;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
|
|
||||||
import java.io.Closeable;
|
import java.io.Closeable;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
@ -73,16 +75,19 @@ public class WebAuthnSigningInTest extends AbstractWebAuthnAccountTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void twoFactorWebAuthnTest() {
|
public void twoFactorWebAuthnTest() {
|
||||||
testWebAuthn(false);
|
testWebAuthn(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void passwordlessWebAuthnTest() {
|
public void passwordlessWebAuthnTest() {
|
||||||
testWebAuthn(true);
|
testWebAuthn(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void createWebAuthnSameUserLabel() {
|
public void createWebAuthnSameUserLabel() {
|
||||||
final String SAME_LABEL = "key123";
|
final String SAME_LABEL = "key123";
|
||||||
|
|
||||||
|
@ -117,6 +122,7 @@ public class WebAuthnSigningInTest extends AbstractWebAuthnAccountTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void multipleSecurityKeys() {
|
public void multipleSecurityKeys() {
|
||||||
final String LABEL = "SecurityKey#";
|
final String LABEL = "SecurityKey#";
|
||||||
|
|
||||||
|
@ -173,6 +179,7 @@ public class WebAuthnSigningInTest extends AbstractWebAuthnAccountTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void displayAvailableAuthenticators() {
|
public void displayAvailableAuthenticators() {
|
||||||
addWebAuthnCredential("authenticator#1");
|
addWebAuthnCredential("authenticator#1");
|
||||||
addWebAuthnCredential("authenticator#2");
|
addWebAuthnCredential("authenticator#2");
|
||||||
|
@ -197,6 +204,7 @@ public class WebAuthnSigningInTest extends AbstractWebAuthnAccountTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void notDisplayAvailableAuthenticatorsPasswordless() {
|
public void notDisplayAvailableAuthenticatorsPasswordless() {
|
||||||
addWebAuthnCredential("authenticator#1", true);
|
addWebAuthnCredential("authenticator#1", true);
|
||||||
addWebAuthnCredential("authenticator#2", true);
|
addWebAuthnCredential("authenticator#2", true);
|
||||||
|
@ -218,6 +226,7 @@ public class WebAuthnSigningInTest extends AbstractWebAuthnAccountTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void availableAuthenticatorsAfterRemove(){
|
public void availableAuthenticatorsAfterRemove(){
|
||||||
addWebAuthnCredential("authenticator#1");
|
addWebAuthnCredential("authenticator#1");
|
||||||
addWebAuthnCredential("authenticator#2");
|
addWebAuthnCredential("authenticator#2");
|
||||||
|
@ -338,6 +347,7 @@ public class WebAuthnSigningInTest extends AbstractWebAuthnAccountTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void userAuthenticatorTimeLocale() throws IOException {
|
public void userAuthenticatorTimeLocale() throws IOException {
|
||||||
Consumer<String> checkCreatedAtLabels = (requiredLabel) ->
|
Consumer<String> checkCreatedAtLabels = (requiredLabel) ->
|
||||||
webAuthnLoginPage.getAuthenticators()
|
webAuthnLoginPage.getAuthenticators()
|
||||||
|
|
|
@ -47,7 +47,7 @@ import static org.keycloak.testsuite.webauthn.authenticators.DefaultVirtualAuthO
|
||||||
*
|
*
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class WebAuthnTransportLocaleTest extends AbstractWebAuthnAccountTest {
|
public class WebAuthnTransportLocaleTest extends AbstractWebAuthnAccountTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -19,11 +19,14 @@ package org.keycloak.testsuite.webauthn.passwordless;
|
||||||
|
|
||||||
import org.junit.Ignore;
|
import org.junit.Ignore;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
|
import org.keycloak.testsuite.arquillian.annotation.IgnoreBrowserDriver;
|
||||||
import org.keycloak.testsuite.webauthn.WebAuthnPropertyTest;
|
import org.keycloak.testsuite.webauthn.WebAuthnPropertyTest;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class WebAuthnPwdLessPropertyTest extends WebAuthnPropertyTest {
|
public class WebAuthnPwdLessPropertyTest extends WebAuthnPropertyTest {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -40,6 +40,7 @@ import static org.keycloak.testsuite.webauthn.authenticators.DefaultVirtualAuthO
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class AttestationConveyanceRegisterTest extends AbstractWebAuthnVirtualTest {
|
public class AttestationConveyanceRegisterTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@ -64,21 +65,18 @@ public class AttestationConveyanceRegisterTest extends AbstractWebAuthnVirtualTe
|
||||||
|
|
||||||
@Ignore("invalid cert path")
|
@Ignore("invalid cert path")
|
||||||
@Test
|
@Test
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
|
||||||
public void attestationConveyancePreferenceNone() {
|
public void attestationConveyancePreferenceNone() {
|
||||||
assertAttestationConveyance(true, AttestationConveyancePreference.NONE);
|
assertAttestationConveyance(true, AttestationConveyancePreference.NONE);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Ignore("invalid cert path")
|
@Ignore("invalid cert path")
|
||||||
@Test
|
@Test
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
|
||||||
public void attestationConveyancePreferenceIndirect() {
|
public void attestationConveyancePreferenceIndirect() {
|
||||||
assertAttestationConveyance(true, AttestationConveyancePreference.INDIRECT);
|
assertAttestationConveyance(true, AttestationConveyancePreference.INDIRECT);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Ignore("invalid cert path")
|
@Ignore("invalid cert path")
|
||||||
@Test
|
@Test
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
|
||||||
public void attestationConveyancePreferenceDirect() {
|
public void attestationConveyancePreferenceDirect() {
|
||||||
getVirtualAuthManager().useAuthenticator(DEFAULT.getOptions().setHasResidentKey(true).setIsUserConsenting(true).setHasUserVerification(true));
|
getVirtualAuthManager().useAuthenticator(DEFAULT.getOptions().setHasResidentKey(true).setIsUserConsenting(true).setHasUserVerification(true));
|
||||||
assertAttestationConveyance(true, AttestationConveyancePreference.DIRECT);
|
assertAttestationConveyance(true, AttestationConveyancePreference.DIRECT);
|
||||||
|
|
|
@ -38,7 +38,7 @@ import static org.keycloak.testsuite.webauthn.authenticators.DefaultVirtualAuthO
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class AuthAttachmentRegisterTest extends AbstractWebAuthnVirtualTest {
|
public class AuthAttachmentRegisterTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -21,11 +21,14 @@ import org.hamcrest.Matchers;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.junit.Ignore;
|
import org.junit.Ignore;
|
||||||
import org.keycloak.representations.idm.CredentialRepresentation;
|
import org.keycloak.representations.idm.CredentialRepresentation;
|
||||||
|
import org.keycloak.testsuite.arquillian.annotation.IgnoreBrowserDriver;
|
||||||
import org.keycloak.testsuite.webauthn.AbstractWebAuthnVirtualTest;
|
import org.keycloak.testsuite.webauthn.AbstractWebAuthnVirtualTest;
|
||||||
import org.keycloak.testsuite.webauthn.pages.WebAuthnAuthenticatorsList;
|
import org.keycloak.testsuite.webauthn.pages.WebAuthnAuthenticatorsList;
|
||||||
import org.keycloak.testsuite.webauthn.updaters.AbstractWebAuthnRealmUpdater;
|
import org.keycloak.testsuite.webauthn.updaters.AbstractWebAuthnRealmUpdater;
|
||||||
import org.keycloak.testsuite.webauthn.utils.WebAuthnRealmData;
|
import org.keycloak.testsuite.webauthn.utils.WebAuthnRealmData;
|
||||||
import org.keycloak.utils.StringUtil;
|
import org.keycloak.utils.StringUtil;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxOptions;
|
||||||
|
|
||||||
import java.io.Closeable;
|
import java.io.Closeable;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
@ -51,6 +54,7 @@ public class PolicyJsInjectionTest extends AbstractWebAuthnVirtualTest {
|
||||||
protected final String REDIRECT_SCRIPT = "required\"; window.location.href = \"http://www.keycloak.org\";\"";
|
protected final String REDIRECT_SCRIPT = "required\"; window.location.href = \"http://www.keycloak.org\";\"";
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void relyingPartyEntityName() {
|
public void relyingPartyEntityName() {
|
||||||
verifyInjection((updater) -> updater.setWebAuthnPolicyRpEntityName(REDIRECT_SCRIPT),
|
verifyInjection((updater) -> updater.setWebAuthnPolicyRpEntityName(REDIRECT_SCRIPT),
|
||||||
WebAuthnRealmData::getRpEntityName,
|
WebAuthnRealmData::getRpEntityName,
|
||||||
|
@ -105,6 +109,7 @@ public class PolicyJsInjectionTest extends AbstractWebAuthnVirtualTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void requireResidentKey() {
|
public void requireResidentKey() {
|
||||||
// requireResidentKey is set to 'false' and the value is ignored -> success
|
// requireResidentKey is set to 'false' and the value is ignored -> success
|
||||||
verifyInjection((updater) -> updater.setWebAuthnPolicyRequireResidentKey(PROMPT_SCRIPT),
|
verifyInjection((updater) -> updater.setWebAuthnPolicyRequireResidentKey(PROMPT_SCRIPT),
|
||||||
|
@ -126,6 +131,7 @@ public class PolicyJsInjectionTest extends AbstractWebAuthnVirtualTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void injectUserLabel() {
|
public void injectUserLabel() {
|
||||||
final String originalLabel = "label'`;window.prompt(\"another\");'";
|
final String originalLabel = "label'`;window.prompt(\"another\");'";
|
||||||
|
|
||||||
|
|
|
@ -20,9 +20,11 @@ import com.webauthn4j.data.attestation.authenticator.COSEKey;
|
||||||
import com.webauthn4j.data.attestation.statement.COSEAlgorithmIdentifier;
|
import com.webauthn4j.data.attestation.statement.COSEAlgorithmIdentifier;
|
||||||
import org.junit.Test;
|
import org.junit.Test;
|
||||||
import org.keycloak.models.credential.dto.WebAuthnCredentialData;
|
import org.keycloak.models.credential.dto.WebAuthnCredentialData;
|
||||||
|
import org.keycloak.testsuite.arquillian.annotation.IgnoreBrowserDriver;
|
||||||
import org.keycloak.testsuite.webauthn.AbstractWebAuthnVirtualTest;
|
import org.keycloak.testsuite.webauthn.AbstractWebAuthnVirtualTest;
|
||||||
import org.keycloak.testsuite.webauthn.utils.WebAuthnDataWrapper;
|
import org.keycloak.testsuite.webauthn.utils.WebAuthnDataWrapper;
|
||||||
import org.keycloak.testsuite.webauthn.utils.WebAuthnRealmData;
|
import org.keycloak.testsuite.webauthn.utils.WebAuthnRealmData;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
|
|
||||||
import java.io.Closeable;
|
import java.io.Closeable;
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
|
@ -41,6 +43,7 @@ import static org.keycloak.crypto.Algorithm.RS512;
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class PubKeySignRegisterTest extends AbstractWebAuthnVirtualTest {
|
public class PubKeySignRegisterTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -42,7 +42,7 @@ import static org.keycloak.testsuite.webauthn.authenticators.DefaultVirtualAuthO
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class ResidentKeyRegisterTest extends AbstractWebAuthnVirtualTest {
|
public class ResidentKeyRegisterTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -37,7 +37,7 @@ import static org.hamcrest.MatcherAssert.assertThat;
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class UserVerificationRegisterTest extends AbstractWebAuthnVirtualTest {
|
public class UserVerificationRegisterTest extends AbstractWebAuthnVirtualTest {
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
|
|
@ -65,6 +65,7 @@ public class WebAuthnOtherSettingsTest extends AbstractWebAuthnVirtualTest {
|
||||||
protected AppPage appPage;
|
protected AppPage appPage;
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void defaultValues() {
|
public void defaultValues() {
|
||||||
registerDefaultUser("webauthn");
|
registerDefaultUser("webauthn");
|
||||||
|
|
||||||
|
@ -113,7 +114,7 @@ public class WebAuthnOtherSettingsTest extends AbstractWebAuthnVirtualTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void timeout() throws IOException {
|
public void timeout() throws IOException {
|
||||||
final Integer TIMEOUT = 3; //seconds
|
final Integer TIMEOUT = 3; //seconds
|
||||||
|
|
||||||
|
@ -156,6 +157,7 @@ public class WebAuthnOtherSettingsTest extends AbstractWebAuthnVirtualTest {
|
||||||
}
|
}
|
||||||
|
|
||||||
@Test
|
@Test
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public void excludeCredentials() throws IOException {
|
public void excludeCredentials() throws IOException {
|
||||||
List<String> acceptableAaguids = Collections.singletonList(ALL_ONE_AAGUID);
|
List<String> acceptableAaguids = Collections.singletonList(ALL_ONE_AAGUID);
|
||||||
|
|
||||||
|
|
|
@ -17,11 +17,14 @@
|
||||||
|
|
||||||
package org.keycloak.testsuite.webauthn.registration.passwordless;
|
package org.keycloak.testsuite.webauthn.registration.passwordless;
|
||||||
|
|
||||||
|
import org.keycloak.testsuite.arquillian.annotation.IgnoreBrowserDriver;
|
||||||
import org.keycloak.testsuite.webauthn.registration.AttestationConveyanceRegisterTest;
|
import org.keycloak.testsuite.webauthn.registration.AttestationConveyanceRegisterTest;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class PwdLessAttestationRegTest extends AttestationConveyanceRegisterTest {
|
public class PwdLessAttestationRegTest extends AttestationConveyanceRegisterTest {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -24,7 +24,7 @@ import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class PwdLessAuthAttachmentRegTest extends AuthAttachmentRegisterTest {
|
public class PwdLessAuthAttachmentRegTest extends AuthAttachmentRegisterTest {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -17,11 +17,14 @@
|
||||||
|
|
||||||
package org.keycloak.testsuite.webauthn.registration.passwordless;
|
package org.keycloak.testsuite.webauthn.registration.passwordless;
|
||||||
|
|
||||||
|
import org.keycloak.testsuite.arquillian.annotation.IgnoreBrowserDriver;
|
||||||
import org.keycloak.testsuite.webauthn.registration.PubKeySignRegisterTest;
|
import org.keycloak.testsuite.webauthn.registration.PubKeySignRegisterTest;
|
||||||
|
import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class PwdLessPubKeySignRegTest extends PubKeySignRegisterTest {
|
public class PwdLessPubKeySignRegTest extends PubKeySignRegisterTest {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -24,7 +24,7 @@ import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class PwdLessResidentKeyRegTest extends ResidentKeyRegisterTest {
|
public class PwdLessResidentKeyRegTest extends ResidentKeyRegisterTest {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -24,7 +24,7 @@ import org.openqa.selenium.firefox.FirefoxDriver;
|
||||||
/**
|
/**
|
||||||
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
* @author <a href="mailto:mabartos@redhat.com">Martin Bartos</a>
|
||||||
*/
|
*/
|
||||||
@IgnoreBrowserDriver(FirefoxDriver.class)
|
@IgnoreBrowserDriver(FirefoxDriver.class) // See https://github.com/keycloak/keycloak/issues/10368
|
||||||
public class PwdLessUserVerRegTest extends UserVerificationRegisterTest {
|
public class PwdLessUserVerRegTest extends UserVerificationRegisterTest {
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
Loading…
Reference in a new issue