refactored webapp authentication component

app-mgt-restructure
Amalka Subasinghe 2 years ago
parent baf7661e9d
commit 7215c2f827

@ -125,7 +125,7 @@
<!-- Webapp authenticator framework component related properties -->
<webapp.authenticatore.frmework>
${basedir}/../webapp-authenticator-framework/org.wso2.carbon.webapp.authenticator.framework
${basedir}/../webapp-authenticator-framework/io.entgra.device.mgt.core.webapp.authenticator.framework
</webapp.authenticatore.frmework>
</properties>

@ -27,7 +27,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>io.entgra.device.mgt.core</groupId>
<artifactId>org.wso2.carbon.webapp.authenticator.framework</artifactId>
<artifactId>io.entgra.device.mgt.core.webapp.authenticator.framework</artifactId>
<packaging>bundle</packaging>
<name>WSO2 Carbon - Web Application Authenticator Framework Bundle</name>
<description>WSO2 Carbon - Web Application Authenticator Framework Bundle</description>
@ -48,11 +48,11 @@
<Bundle-SymbolicName>${project.artifactId}</Bundle-SymbolicName>
<Bundle-Name>${project.artifactId}</Bundle-Name>
<Private-Package>
org.wso2.carbon.webapp.authenticator.framework.internal
io.entgra.device.mgt.core.webapp.authenticator.framework.internal
</Private-Package>
<Export-Package>
!org.wso2.carbon.webapp.authenticator.framework.internal,
org.wso2.carbon.webapp.authenticator.framework.*
!io.entgra.device.mgt.core.webapp.authenticator.framework.internal,
io.entgra.device.mgt.core.webapp.authenticator.framework.*
</Export-Package>
<Import-Package>
com.nimbusds.jose;version="${nimbus.orbit.version.range}",
@ -284,6 +284,10 @@
<version>4.6.3-m5</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.wso2.carbon.identity.inbound.auth.oauth2</groupId>
<artifactId>org.wso2.carbon.identity.oauth.stub</artifactId>
</dependency>
</dependencies>
<!-- TODO -->
<properties>

@ -15,7 +15,7 @@
* specific language governing permissions and limitations
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import org.apache.catalina.connector.Request;
import org.apache.catalina.connector.Response;
@ -28,7 +28,7 @@ import org.wso2.carbon.user.api.UserRealm;
import org.wso2.carbon.user.api.UserStoreException;
import org.wso2.carbon.user.core.service.RealmService;
import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import javax.xml.XMLConstants;
import javax.xml.parsers.DocumentBuilder;

@ -16,9 +16,9 @@
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
/**
* DTO class to hold the information of authenticated user AND STATUS.

@ -16,8 +16,10 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.Utils;
package io.entgra.device.mgt.core.webapp.authenticator.framework.Utils;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthConstants;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import org.apache.axis2.AxisFault;
import org.apache.axis2.client.Options;
import org.apache.axis2.client.ServiceClient;
@ -31,11 +33,7 @@ import org.apache.commons.httpclient.params.HttpConnectionManagerParams;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.commons.pool.PoolableObjectFactory;
import org.apache.http.conn.HttpClientConnectionManager;
import org.apache.http.impl.conn.PoolingHttpClientConnectionManager;
import org.wso2.carbon.identity.oauth2.stub.OAuth2TokenValidationServiceStub;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthConstants;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import java.util.ArrayList;
import java.util.List;

@ -16,7 +16,7 @@
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.Utils;
package io.entgra.device.mgt.core.webapp.authenticator.framework.Utils;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@ -26,13 +26,13 @@ import org.wso2.carbon.user.api.TenantManager;
import org.wso2.carbon.user.api.UserStoreException;
import org.wso2.carbon.user.core.service.RealmService;
import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationException;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthValidatorFactory;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthValidatorFactory;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import java.util.Properties;
import java.util.regex.Matcher;

@ -16,7 +16,7 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import com.google.gson.Gson;
import org.apache.catalina.Context;
@ -32,9 +32,9 @@ import org.wso2.carbon.tomcat.ext.valves.CompositeValve;
import org.wso2.carbon.user.api.Tenant;
import org.wso2.carbon.user.api.UserStoreException;
import org.wso2.carbon.user.core.service.RealmService;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import org.wso2.carbon.webapp.authenticator.framework.authorizer.PermissionAuthorizer;
import org.wso2.carbon.webapp.authenticator.framework.authorizer.WebappTenantAuthorizer;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authorizer.PermissionAuthorizer;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authorizer.WebappTenantAuthorizer;
import javax.servlet.http.HttpServletResponse;
import java.net.InetAddress;

@ -16,11 +16,11 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import org.apache.catalina.connector.Request;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import java.util.Map;

@ -16,11 +16,10 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import java.util.HashMap;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

@ -16,7 +16,7 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.axiom.om.OMElement;
import org.apache.axiom.om.impl.builder.StAXBuilder;
@ -30,12 +30,12 @@ import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.coyote.InputBuffer;
import org.apache.tomcat.util.buf.ByteChunk;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationException;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.Utils.Utils;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Utils.Utils;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import javax.xml.stream.XMLStreamException;
import javax.xml.stream.XMLStreamReader;

@ -16,7 +16,7 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.connector.Request;
import org.apache.catalina.connector.Response;
@ -27,11 +27,11 @@ import org.apache.tomcat.util.buf.MessageBytes;
import org.wso2.carbon.user.api.UserStoreException;
import org.wso2.carbon.user.api.UserStoreManager;
import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationException;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import org.wso2.carbon.webapp.authenticator.framework.Constants;
import org.wso2.carbon.webapp.authenticator.framework.Utils.Utils;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Constants;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Utils.Utils;
import java.nio.charset.Charset;
import java.util.Base64;

@ -17,7 +17,7 @@
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.connector.Request;
import org.apache.catalina.connector.Response;
@ -31,10 +31,10 @@ import org.wso2.carbon.certificate.mgt.core.scep.TenantedDeviceWrapper;
import org.wso2.carbon.device.mgt.common.DeviceIdentifier;
import org.wso2.carbon.device.mgt.common.DeviceManagementConstants;
import org.wso2.carbon.device.mgt.common.EnrolmentInfo;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationException;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import org.wso2.carbon.webapp.authenticator.framework.Utils.Utils;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Utils.Utils;
import java.security.cert.X509Certificate;
import java.util.Properties;

@ -16,7 +16,7 @@
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import com.nimbusds.jose.JWSVerifier;
import com.nimbusds.jose.crypto.RSASSAVerifier;
@ -35,8 +35,8 @@ import org.wso2.carbon.user.api.UserStoreException;
import org.wso2.carbon.user.api.UserStoreManager;
import org.wso2.carbon.utils.CarbonUtils;
import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import java.io.FileInputStream;
import java.security.KeyStore;

@ -16,20 +16,20 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.connector.Response;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.apache.tomcat.util.buf.ByteChunk;
import org.apache.tomcat.util.buf.MessageBytes;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationException;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.Constants;
import org.wso2.carbon.webapp.authenticator.framework.Utils.Utils;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Constants;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Utils.Utils;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import java.util.Properties;
import java.util.StringTokenizer;

@ -15,17 +15,17 @@
* specific language governing permissions and limitations
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.connector.Response;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.wso2.carbon.device.mgt.common.otp.mgt.dto.OneTimePinDTO;
import org.wso2.carbon.device.mgt.common.spi.OTPManagementService;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.Constants;
import org.wso2.carbon.webapp.authenticator.framework.Utils.Utils;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Constants;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Utils.Utils;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import java.util.Properties;

@ -16,11 +16,11 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.connector.Request;
import org.apache.catalina.connector.Response;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import java.util.Properties;

@ -15,7 +15,7 @@
* specific language governing permissions and limitations
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth;
/**
* Declares the contract for OAuth2TokenValidator implementations.

@ -15,7 +15,7 @@
* specific language governing permissions and limitations
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth;
/**
* This class holds the authenticated user information after the OAuth2 token is validated.

@ -15,10 +15,10 @@
* specific language governing permissions and limitations
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.impl.LocalOAuthValidator;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.impl.RemoteOAuthValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.impl.LocalOAuthValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.impl.RemoteOAuthValidator;
import java.util.Properties;

@ -15,17 +15,17 @@
* specific language governing permissions and limitations
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.impl;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.impl;
import org.wso2.carbon.identity.oauth2.dto.OAuth2TokenValidationRequestDTO;
import org.wso2.carbon.identity.oauth2.dto.OAuth2TokenValidationResponseDTO;
import org.wso2.carbon.utils.multitenancy.MultitenantConstants;
import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthConstants;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthConstants;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
/**
* Handles the OAuth2 token validation from the same server using OSGi services.

@ -15,7 +15,7 @@
* specific language governing permissions and limitations
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.impl;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.impl;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@ -26,10 +26,10 @@ import org.wso2.carbon.identity.oauth2.stub.dto.OAuth2TokenValidationRequestDTO_
import org.wso2.carbon.identity.oauth2.stub.dto.OAuth2TokenValidationRequestDTO_TokenValidationContextParam;
import org.wso2.carbon.identity.oauth2.stub.dto.OAuth2TokenValidationResponseDTO;
import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
import org.wso2.carbon.webapp.authenticator.framework.Utils.OAuthTokenValidationStubFactory;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Utils.OAuthTokenValidationStubFactory;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthTokenValidationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuthValidationResponse;
import java.rmi.RemoteException;
import java.util.Properties;

@ -15,7 +15,7 @@
* specific language governing permissions and limitations
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authorizer;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authorizer;
import org.apache.catalina.connector.Request;
import org.apache.commons.logging.Log;
@ -24,10 +24,10 @@ import org.wso2.carbon.device.mgt.common.permission.mgt.Permission;
import org.wso2.carbon.device.mgt.common.permission.mgt.PermissionManagementException;
import org.wso2.carbon.device.mgt.common.permission.mgt.PermissionManagerService;
import org.wso2.carbon.device.mgt.core.permission.mgt.PermissionManagerServiceImpl;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationException;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationFrameworkUtil;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationFrameworkUtil;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import java.util.ArrayList;
import java.util.List;

@ -16,11 +16,11 @@
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authorizer;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authorizer;
import org.apache.catalina.connector.Request;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
/**
* This class represents the methods that are used to authorize requests based on the tenant subscription.

@ -16,7 +16,7 @@
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.config;
package io.entgra.device.mgt.core.webapp.authenticator.framework.config;
/**
* This defines the contract for AuthenticatorConfigService to expose authenticator configs in webapp-authenticators.xml.

@ -16,25 +16,21 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.config;
package io.entgra.device.mgt.core.webapp.authenticator.framework.config;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.w3c.dom.Document;
import org.wso2.carbon.utils.CarbonUtils;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationFrameworkUtil;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticatorFrameworkException;
import org.xml.sax.SAXException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationFrameworkUtil;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticatorFrameworkException;
import javax.xml.XMLConstants;
import javax.xml.bind.JAXBContext;
import javax.xml.bind.JAXBException;
import javax.xml.bind.Unmarshaller;
import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlElementWrapper;
import javax.xml.bind.annotation.XmlRootElement;
import javax.xml.validation.Schema;
import javax.xml.validation.SchemaFactory;
import java.io.File;
import java.util.List;

@ -16,12 +16,12 @@
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.config.impl;
package io.entgra.device.mgt.core.webapp.authenticator.framework.config.impl;
import org.wso2.carbon.webapp.authenticator.framework.config.AuthenticatorConfig;
import org.wso2.carbon.webapp.authenticator.framework.config.AuthenticatorConfigService;
import org.wso2.carbon.webapp.authenticator.framework.config.InvalidConfigurationStateException;
import org.wso2.carbon.webapp.authenticator.framework.config.WebappAuthenticatorConfig;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.AuthenticatorConfig;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.AuthenticatorConfigService;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.InvalidConfigurationStateException;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.WebappAuthenticatorConfig;
import java.util.List;

@ -16,7 +16,7 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.internal;
package io.entgra.device.mgt.core.webapp.authenticator.framework.internal;
import org.wso2.carbon.certificate.mgt.core.scep.SCEPManager;
import org.wso2.carbon.certificate.mgt.core.service.CertificateManagementService;
@ -25,7 +25,7 @@ import org.wso2.carbon.identity.oauth2.OAuth2TokenValidationService;
import org.wso2.carbon.registry.core.service.TenantRegistryLoader;
import org.wso2.carbon.registry.indexing.service.TenantIndexingLoader;
import org.wso2.carbon.user.core.service.RealmService;
import org.wso2.carbon.webapp.authenticator.framework.WebappAuthenticatorRepository;
import io.entgra.device.mgt.core.webapp.authenticator.framework.WebappAuthenticatorRepository;
public class AuthenticatorFrameworkDataHolder {

@ -17,7 +17,7 @@
*
*/
package org.wso2.carbon.webapp.authenticator.framework.internal;
package io.entgra.device.mgt.core.webapp.authenticator.framework.internal;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@ -32,13 +32,13 @@ import org.wso2.carbon.registry.indexing.service.TenantIndexingLoader;
import org.wso2.carbon.tomcat.ext.valves.CarbonTomcatValve;
import org.wso2.carbon.tomcat.ext.valves.TomcatValveContainer;
import org.wso2.carbon.user.core.service.RealmService;
import org.wso2.carbon.webapp.authenticator.framework.WebappAuthenticationValve;
import org.wso2.carbon.webapp.authenticator.framework.WebappAuthenticatorRepository;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import org.wso2.carbon.webapp.authenticator.framework.config.AuthenticatorConfig;
import org.wso2.carbon.webapp.authenticator.framework.config.AuthenticatorConfigService;
import org.wso2.carbon.webapp.authenticator.framework.config.WebappAuthenticatorConfig;
import org.wso2.carbon.webapp.authenticator.framework.config.impl.AuthenticatorConfigServiceImpl;
import io.entgra.device.mgt.core.webapp.authenticator.framework.WebappAuthenticationValve;
import io.entgra.device.mgt.core.webapp.authenticator.framework.WebappAuthenticatorRepository;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.AuthenticatorConfig;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.AuthenticatorConfigService;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.WebappAuthenticatorConfig;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.impl.AuthenticatorConfigServiceImpl;
import java.util.ArrayList;
import java.util.List;

@ -16,7 +16,7 @@
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import org.testng.annotations.BeforeSuite;
@ -35,9 +35,9 @@ import org.wso2.carbon.user.api.UserStoreException;
import org.wso2.carbon.user.api.UserStoreManager;
import org.wso2.carbon.user.core.service.RealmService;
import org.wso2.carbon.utils.multitenancy.MultitenantConstants;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import org.wso2.carbon.webapp.authenticator.framework.util.TestTenantIndexingLoader;
import org.wso2.carbon.webapp.authenticator.framework.util.TestTenantRegistryLoader;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.util.TestTenantIndexingLoader;
import io.entgra.device.mgt.core.webapp.authenticator.framework.util.TestTenantRegistryLoader;
import java.io.File;
import java.io.InputStream;

@ -17,7 +17,7 @@
*
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import org.apache.catalina.Context;
import org.apache.catalina.connector.Connector;
@ -31,7 +31,7 @@ import org.testng.Assert;
import org.testng.annotations.BeforeClass;
import org.testng.annotations.Test;
import org.wso2.carbon.tomcat.ext.valves.CompositeValve;
import org.wso2.carbon.webapp.authenticator.framework.util.TestRequest;
import io.entgra.device.mgt.core.webapp.authenticator.framework.util.TestRequest;
import javax.servlet.http.HttpServletResponse;
import java.lang.reflect.Field;

@ -16,17 +16,18 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticatorFrameworkException;
import org.testng.Assert;
import org.testng.annotations.AfterClass;
import org.testng.annotations.BeforeClass;
import org.testng.annotations.Test;
import org.wso2.carbon.utils.ServerConstants;
import org.wso2.carbon.webapp.authenticator.framework.config.AuthenticatorConfig;
import org.wso2.carbon.webapp.authenticator.framework.config.AuthenticatorConfigService;
import org.wso2.carbon.webapp.authenticator.framework.config.WebappAuthenticatorConfig;
import org.wso2.carbon.webapp.authenticator.framework.config.impl.AuthenticatorConfigServiceImpl;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.AuthenticatorConfig;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.AuthenticatorConfigService;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.WebappAuthenticatorConfig;
import io.entgra.device.mgt.core.webapp.authenticator.framework.config.impl.AuthenticatorConfigServiceImpl;
import java.util.List;
@ -62,7 +63,7 @@ public class WebappAuthenticatorConfigTest {
Assert.assertNotNull(authenticatorConfig,
"Added authenticator config for the BasicAuth authenticator cannot be retrieved successfully");
Assert.assertEquals(authenticatorConfig.getClassName(),
"org.wso2.carbon.webapp.authenticator.framework" + ".authenticator.BasicAuthAuthenticator",
"io.entgra.device.mgt.core.webapp.authenticator.framework" + ".authenticator.BasicAuthAuthenticator",
"Class name related with Basic Auth does not match with "
+ "the class name specified in the configuration");
authenticatorConfig = authenticatorConfigService.getAuthenticatorConfig(null);

@ -16,7 +16,7 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
@ -25,7 +25,7 @@ import org.apache.commons.pool.impl.GenericObjectPool;
import org.testng.Assert;
import org.testng.annotations.Test;
import org.wso2.carbon.identity.oauth2.stub.OAuth2TokenValidationServiceStub;
import org.wso2.carbon.webapp.authenticator.framework.Utils.OAuthTokenValidationStubFactory;
import io.entgra.device.mgt.core.webapp.authenticator.framework.Utils.OAuthTokenValidationStubFactory;
import java.util.Properties;

@ -16,13 +16,14 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework;
package io.entgra.device.mgt.core.webapp.authenticator.framework;
import io.entgra.device.mgt.core.webapp.authenticator.framework.WebappAuthenticatorRepository;
import org.testng.Assert;
import org.testng.annotations.Test;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import org.wso2.carbon.webapp.authenticator.framework.util.MalformedAuthenticator;
import org.wso2.carbon.webapp.authenticator.framework.util.TestWebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.util.MalformedAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.util.TestWebappAuthenticator;
public class WebappAuthenticatorRepositoryTest {

@ -17,7 +17,7 @@
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.Context;
import org.apache.catalina.connector.Request;
@ -33,10 +33,10 @@ import org.wso2.carbon.base.MultitenantConstants;
import org.wso2.carbon.identity.oauth2.OAuth2TokenValidationService;
import org.wso2.carbon.identity.oauth2.dto.OAuth2ClientApplicationDTO;
import org.wso2.carbon.identity.oauth2.dto.OAuth2TokenValidationResponseDTO;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import org.wso2.carbon.webapp.authenticator.framework.util.TestInputBuffer;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.OAuth2TokenValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.util.TestInputBuffer;
import java.io.File;
import java.io.IOException;

@ -17,7 +17,7 @@
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.Context;
import org.apache.catalina.connector.Request;
@ -30,8 +30,8 @@ import org.testng.annotations.BeforeClass;
import org.testng.annotations.BeforeTest;
import org.testng.annotations.Test;
import org.wso2.carbon.utils.multitenancy.MultitenantConstants;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.BaseWebAppAuthenticatorFrameworkTest;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.BaseWebAppAuthenticatorFrameworkTest;
import java.lang.reflect.Field;
import java.lang.reflect.InvocationTargetException;

@ -17,7 +17,7 @@
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.Context;
import org.apache.catalina.connector.Request;
@ -49,9 +49,9 @@ import org.wso2.carbon.device.mgt.common.Device;
import org.wso2.carbon.device.mgt.common.exceptions.DeviceManagementException;
import org.wso2.carbon.device.mgt.common.EnrolmentInfo;
import org.wso2.carbon.device.mgt.core.config.DeviceConfigurationManager;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import org.wso2.carbon.webapp.authenticator.framework.util.TestCertificateGenerator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.internal.AuthenticatorFrameworkDataHolder;
import io.entgra.device.mgt.core.webapp.authenticator.framework.util.TestCertificateGenerator;
import javax.sql.DataSource;
import java.io.File;

@ -16,7 +16,7 @@
* under the License.
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.connector.Request;
import org.apache.tomcat.util.buf.MessageBytes;
@ -28,7 +28,7 @@ import org.wso2.carbon.base.MultitenantConstants;
import org.wso2.carbon.identity.jwt.client.extension.dto.JWTConfig;
import org.wso2.carbon.identity.jwt.client.extension.exception.JWTClientException;
import org.wso2.carbon.identity.jwt.client.extension.util.JWTClientUtil;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import java.io.File;
import java.io.FileInputStream;

@ -17,7 +17,7 @@
*
*/
package org.wso2.carbon.webapp.authenticator.framework.authenticator;
package io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator;
import org.apache.catalina.connector.Request;
import org.apache.commons.pool.impl.GenericObjectPool;
@ -31,13 +31,12 @@ import org.wso2.carbon.core.security.AuthenticatorsConfiguration;
import org.wso2.carbon.identity.oauth2.stub.OAuth2TokenValidationServiceStub;
import org.wso2.carbon.identity.oauth2.stub.dto.OAuth2ClientApplicationDTO;
import org.wso2.carbon.identity.oauth2.stub.dto.OAuth2TokenValidationResponseDTO;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.BaseWebAppAuthenticatorFrameworkTest;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.oauth.impl.RemoteOAuthValidator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.BaseWebAppAuthenticatorFrameworkTest;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.oauth.impl.RemoteOAuthValidator;
import java.lang.reflect.Field;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;
import java.util.Properties;
/**

@ -16,12 +16,12 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.util;
package io.entgra.device.mgt.core.webapp.authenticator.framework.util;
import org.apache.catalina.connector.Request;
import org.apache.catalina.connector.Response;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import java.util.Properties;

@ -17,7 +17,7 @@
*
*/
package org.wso2.carbon.webapp.authenticator.framework.util;
package io.entgra.device.mgt.core.webapp.authenticator.framework.util;
import org.bouncycastle.cert.X509v3CertificateBuilder;
import org.bouncycastle.cert.jcajce.JcaX509CertificateConverter;

@ -16,7 +16,7 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.util;
package io.entgra.device.mgt.core.webapp.authenticator.framework.util;
import org.wso2.carbon.registry.core.exceptions.RegistryException;
import org.wso2.carbon.registry.core.service.TenantRegistryLoader;

@ -16,12 +16,12 @@
* under the License.
*
*/
package org.wso2.carbon.webapp.authenticator.framework.util;
package io.entgra.device.mgt.core.webapp.authenticator.framework.util;
import org.apache.catalina.connector.Request;
import org.apache.catalina.connector.Response;
import org.wso2.carbon.webapp.authenticator.framework.AuthenticationInfo;
import org.wso2.carbon.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import io.entgra.device.mgt.core.webapp.authenticator.framework.AuthenticationInfo;
import io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.WebappAuthenticator;
import java.util.Properties;

@ -2,7 +2,7 @@
<Authenticators>
<Authenticator>
<Name>OAuth</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.OAuthAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.OAuthAuthenticator</ClassName>
<Parameters>
<Parameter Name="TokenValidationEndpointUrl">https://localhost:9443</Parameter>
<Parameter Name="Username">admin</Parameter>
@ -14,19 +14,19 @@
</Authenticator>
<Authenticator>
<Name>BasicAuth</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.BasicAuthAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.BasicAuthAuthenticator</ClassName>
</Authenticator>
<Authenticator>
<Name>JWT</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.JWTAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.JWTAuthenticator</ClassName>
</Authenticator>
<Authenticator>
<Name>CertificateAuth</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.CertificateAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.CertificateAuthenticator</ClassName>
</Authenticator>
<Authenticator>
<Name>OTPAuth</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.OneTimeTokenAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.OneTimeTokenAuthenticator</ClassName>
</Authenticator>
</Authenticators>
</WebappAuthenticatorConfig>

@ -0,0 +1,41 @@
<!--
~ Copyright (c) 2014, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
~
~ WSO2 Inc. licenses this file to you under the Apache License,
~ Version 2.0 (the "License"); you may not use this file except
~ in compliance with the License.
~ you may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing,
~ software distributed under the License is distributed on an
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
~ KIND, either express or implied. See the License for the
~ specific language governing permissions and limitations
~ under the License.
-->
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
<suite name="WebappAuthenticatorFramework">
<parameter name="useDefaultListeners" value="false"/>
<test name="WebappAuthenticatorTests" parallel="false">
<classes>
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.BaseWebAppAuthenticatorFrameworkTest"/>
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.WebappAuthenticatorConfigTest"/>
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.WebappAuthenticatorFrameworkUtilTest"/>
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.WebappAuthenticatorRepositoryTest"/>
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.BasicAuthAuthenticatorTest" />
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.BSTAuthenticatorTest" />
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.OauthAuthenticatorTest" />
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.JWTAuthenticatorTest" />
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.CertificateAuthenticatorTest" />
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.internal.WebappAuthenticatorFrameworkServiceComponentTest"/>
<class name="io.entgra.device.mgt.core.webapp.authenticator.framework.WebappAuthenticationValveTest"/>
</classes>
</test>
</suite>

@ -1,41 +0,0 @@
<!--
~ Copyright (c) 2014, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
~
~ WSO2 Inc. licenses this file to you under the Apache License,
~ Version 2.0 (the "License"); you may not use this file except
~ in compliance with the License.
~ you may obtain a copy of the License at
~
~ http://www.apache.org/licenses/LICENSE-2.0
~
~ Unless required by applicable law or agreed to in writing,
~ software distributed under the License is distributed on an
~ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
~ KIND, either express or implied. See the License for the
~ specific language governing permissions and limitations
~ under the License.
-->
<!DOCTYPE suite SYSTEM "http://testng.org/testng-1.0.dtd" >
<suite name="WebappAuthenticatorFramework">
<parameter name="useDefaultListeners" value="false"/>
<test name="WebappAuthenticatorTests" parallel="false">
<classes>
<class name="org.wso2.carbon.webapp.authenticator.framework.BaseWebAppAuthenticatorFrameworkTest"/>
<class name="org.wso2.carbon.webapp.authenticator.framework.WebappAuthenticatorConfigTest"/>
<class name="org.wso2.carbon.webapp.authenticator.framework.WebappAuthenticatorFrameworkUtilTest"/>
<class name="org.wso2.carbon.webapp.authenticator.framework.WebappAuthenticatorRepositoryTest"/>
<class name="org.wso2.carbon.webapp.authenticator.framework.authenticator.BasicAuthAuthenticatorTest" />
<class name="org.wso2.carbon.webapp.authenticator.framework.authenticator.BSTAuthenticatorTest" />
<class name="org.wso2.carbon.webapp.authenticator.framework.authenticator.OauthAuthenticatorTest" />
<class name="org.wso2.carbon.webapp.authenticator.framework.authenticator.JWTAuthenticatorTest" />
<class name="org.wso2.carbon.webapp.authenticator.framework.authenticator.CertificateAuthenticatorTest" />
<class name="org.wso2.carbon.webapp.authenticator.framework.internal.WebappAuthenticatorFrameworkServiceComponentTest"/>
<class name="org.wso2.carbon.webapp.authenticator.framework.WebappAuthenticationValveTest"/>
</classes>
</test>
</suite>

@ -34,7 +34,7 @@
<url>http://wso2.org</url>
<modules>
<module>org.wso2.carbon.webapp.authenticator.framework</module>
<module>io.entgra.device.mgt.core.webapp.authenticator.framework</module>
</modules>
<build>

@ -89,7 +89,7 @@
</properties>
</adviceFile>
<bundles>
<bundleDef>io.entgra.device.mgt.core:org.wso2.carbon.webapp.authenticator.framework:${carbon.device.mgt.version}
<bundleDef>io.entgra.device.mgt.core:io.entgra.device.mgt.core.webapp.authenticator.framework:${carbon.device.mgt.version}
</bundleDef>
</bundles>
</configuration>

@ -2,7 +2,7 @@
<Authenticators>
<Authenticator>
<Name>OAuth</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.OAuthAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.OAuthAuthenticator</ClassName>
<Parameters>
<Parameter Name="IsRemote">false</Parameter>
<Parameter Name="TokenValidationEndpointUrl">https://${iot.keymanager.host}:${iot.keymanager.https.port}</Parameter>
@ -14,11 +14,11 @@
</Authenticator>
<Authenticator>
<Name>BasicAuth</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.BasicAuthAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.BasicAuthAuthenticator</ClassName>
</Authenticator>
<Authenticator>
<Name>JWT</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.JWTAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.JWTAuthenticator</ClassName>
<Parameters>
<!--Issuers list and corresponding cert alias-->
<Parameter Name="default">wso2carbon</Parameter>
@ -29,15 +29,15 @@
</Authenticator>
<Authenticator>
<Name>CertificateAuth</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.CertificateAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.CertificateAuthenticator</ClassName>
</Authenticator>
<Authenticator>
<Name>OTPAuth</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.OneTimeTokenAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.OneTimeTokenAuthenticator</ClassName>
</Authenticator>
<Authenticator>
<Name>BST</Name>
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.BSTAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.BSTAuthenticator</ClassName>
<Parameters>
<Parameter Name="IsRemote">false</Parameter>
<Parameter Name="TokenValidationEndpointUrl">https://${iot.keymanager.host}:${iot.keymanager.https.port}</Parameter>

@ -10,7 +10,7 @@
{% endfor %}
</Parameters>
{% else %}
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.OAuthAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.OAuthAuthenticator</ClassName>
<Parameters>
<Parameter Name="IsRemote">false</Parameter>
<Parameter Name="TokenValidationEndpointUrl">https://${iot.keymanager.host}:${iot.keymanager.https.port}</Parameter>
@ -31,7 +31,7 @@
{% endfor %}
</Parameters>
{% else %}
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.BasicAuthAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.BasicAuthAuthenticator</ClassName>
{% endif %}
</Authenticator>
<Authenticator>
@ -44,7 +44,7 @@
{% endfor %}
</Parameters>
{% else %}
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.JWTAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.JWTAuthenticator</ClassName>
<Parameters>
<!--Issuers list and corresponding cert alias-->
<Parameter Name="default">wso2carbon</Parameter>
@ -64,7 +64,7 @@
{% endfor %}
</Parameters>
{% else %}
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.CertificateAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.CertificateAuthenticator</ClassName>
{% endif %}
</Authenticator>
<Authenticator>
@ -77,7 +77,7 @@
{% endfor %}
</Parameters>
{% else %}
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.OneTimeTokenAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.OneTimeTokenAuthenticator</ClassName>
{% endif %}
</Authenticator>
<Authenticator>
@ -90,7 +90,7 @@
{% endfor %}
</Parameters>
{% else %}
<ClassName>org.wso2.carbon.webapp.authenticator.framework.authenticator.BSTAuthenticator</ClassName>
<ClassName>io.entgra.device.mgt.core.webapp.authenticator.framework.authenticator.BSTAuthenticator</ClassName>
<Parameters>
<Parameter Name="IsRemote">false</Parameter>
<Parameter Name="TokenValidationEndpointUrl">https://${iot.keymanager.host}:${iot.keymanager.https.port}</Parameter>

@ -45,7 +45,7 @@
<!-- <module>components/ui-request-interceptor</module>-->
<!-- <module>components/transport-mgt</module>-->
<!-- <module>components/analytics-mgt</module>-->
<!-- <module>components/webapp-authenticator-framework</module>-->
<module>components/webapp-authenticator-framework</module>
<!-- <module>components/logger</module>-->
<module>components/task-mgt</module>
<module>components/subtype-mgt</module>
@ -62,7 +62,7 @@
<!-- <module>features/device-mgt-extensions</module>-->
<!-- <module>features/transport-mgt</module>-->
<!-- <module>features/analytics-mgt</module>-->
<!-- <module>features/webapp-authenticator-framework</module>-->
<module>features/webapp-authenticator-framework</module>
<!-- <module>features/logger</module>-->
<module>features/task-mgt</module>
<module>features/subtype-mgt</module>

Loading…
Cancel
Save