diff --git a/etc/sample-post-authentication-handler/pom.xml b/etc/sample-post-authentication-handler/pom.xml
index fea479583..1cf4eb3e8 100644
--- a/etc/sample-post-authentication-handler/pom.xml
+++ b/etc/sample-post-authentication-handler/pom.xml
@@ -78,7 +78,7 @@
javax.servlet.http,
org.apache.commons.logging,
org.osgi.framework,
- org.osgi.service.component,
+ org.osgi.service.component.*;version="${osgi.service.component.imp.pkg.version.range}",
org.wso2.carbon.identity.application.authentication.framework.config,
org.wso2.carbon.identity.application.authentication.framework.config.model,
org.wso2.carbon.identity.application.authentication.framework.context,
diff --git a/etc/sample-post-authentication-handler/src/main/java/org/wso2/carbon/identity/post/authn/handler/disclaimer/DisclaimerPostAuthenticationHandler.java b/etc/sample-post-authentication-handler/src/main/java/org/wso2/carbon/identity/post/authn/handler/disclaimer/DisclaimerPostAuthenticationHandler.java
index 849157ae4..5f664b47e 100644
--- a/etc/sample-post-authentication-handler/src/main/java/org/wso2/carbon/identity/post/authn/handler/disclaimer/DisclaimerPostAuthenticationHandler.java
+++ b/etc/sample-post-authentication-handler/src/main/java/org/wso2/carbon/identity/post/authn/handler/disclaimer/DisclaimerPostAuthenticationHandler.java
@@ -18,16 +18,17 @@
package org.wso2.carbon.identity.post.authn.handler.disclaimer;
-import org.apache.commons.codec.digest.DigestUtils;
import org.wso2.carbon.identity.application.authentication.framework.config.ConfigurationFacade;
import org.wso2.carbon.identity.application.authentication.framework.context.AuthenticationContext;
import org.wso2.carbon.identity.application.authentication.framework.exception.PostAuthenticationFailedException;
import org.wso2.carbon.identity.application.authentication.framework.handler.request.AbstractPostAuthnHandler;
import org.wso2.carbon.identity.application.authentication.framework.handler.request.PostAuthnHandlerFlowStatus;
import org.wso2.carbon.identity.application.authentication.framework.model.AuthenticatedUser;
-import org.wso2.carbon.identity.application.authentication.framework.util.FrameworkUtils;
import java.io.IOException;
+import java.net.URI;
+import java.net.URISyntaxException;
+
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
@@ -54,15 +55,20 @@ public PostAuthnHandlerFlowStatus handle(HttpServletRequest httpServletRequest,
}
} else {
try {
+ String urlEncodedApplicationName = new URI(null, null, authenticationContext
+ .getSequenceConfig().getApplicationConfig().getApplicationName(), null).toASCIIString();
+
httpServletResponse.sendRedirect
- (ConfigurationFacade.getInstance().getAuthenticationEndpointURL().replace("/login.do", ""
- ) + "/disclaimer" + ".jsp?sessionDataKey=" + authenticationContext.getContextIdentifier() +
- "&application=" + authenticationContext
- .getSequenceConfig().getApplicationConfig().getApplicationName());
+ (ConfigurationFacade.getInstance().getAuthenticationEndpointURL().replace("/login.do", "") +
+ "/disclaimer.jsp?sessionDataKey=" + authenticationContext.getContextIdentifier() +
+ "&application=" + urlEncodedApplicationName);
setConsentPoppedUpState(authenticationContext);
return PostAuthnHandlerFlowStatus.INCOMPLETE;
} catch (IOException e) {
throw new PostAuthenticationFailedException("Invalid Consent", "Error while redirecting", e);
+ } catch (URISyntaxException e) {
+ throw new PostAuthenticationFailedException("Invalid Application Name",
+ "Error encoding application name", e);
}
}
}
diff --git a/oauth2/custom-grant/src/main/java/org/wso2/sample/identity/oauth2/grant/mobile/MobileGrant.java b/oauth2/custom-grant/src/main/java/org/wso2/sample/identity/oauth2/grant/mobile/MobileGrant.java
index b4858da6a..4b9f75f2d 100644
--- a/oauth2/custom-grant/src/main/java/org/wso2/sample/identity/oauth2/grant/mobile/MobileGrant.java
+++ b/oauth2/custom-grant/src/main/java/org/wso2/sample/identity/oauth2/grant/mobile/MobileGrant.java
@@ -30,6 +30,8 @@
import org.wso2.carbon.utils.multitenancy.MultitenantUtils;
import java.util.UUID;
+import java.util.regex.Matcher;
+import java.util.regex.Pattern;
/**
* New grant type for Identity Server
@@ -158,22 +160,21 @@ public boolean validateScope(OAuthTokenReqMessageContext tokReqMsgCtx)
/**
- * TODO
- *
* You need to implement how to validate the mobile number
*
- * @param mobileNumber
- * @return
+ * @param mobileNumber Mobile number of the user.
+ * @return true if the mobile number is valid, otherwise false.
*/
private boolean isValidMobileNumber(String mobileNumber){
- // just demo validation
-
- if(mobileNumber.startsWith("033")){
- return true;
- }
-
- return false;
+ // Regular expression to match 10 digits, with optional country code
+ String pattern = "^(\\+\\d{1,3})?\\d{10}$";
+ // Create a Pattern object
+ Pattern r = Pattern.compile(pattern);
+ // Create Matcher object
+ Matcher m = r.matcher(mobileNumber);
+ // Check if the pattern matches
+ return m.matches();
}
@Override
diff --git a/pom.xml b/pom.xml
index 7f3272fd2..11fb1a977 100644
--- a/pom.xml
+++ b/pom.xml
@@ -489,11 +489,6 @@
commons-pool
${commons.pool.wso2.version}
-
- org.wso2.carbon.identity.framework
- org.wso2.carbon.identity.workflow.mgt.stub
- ${carbon.identity.framework.version}
-
org.wso2.carbon.identity.framework
org.wso2.carbon.identity.application.mgt.stub
@@ -501,26 +496,31 @@
compile
- org.wso2.carbon.identity.framework
+ org.wso2.carbon.identity.workflow.impl.bps
org.wso2.carbon.identity.workflow.mgt
- ${carbon.identity.framework.version}
+ ${identity.workflow.impl.bps.version}
- org.wso2.carbon.identity.framework
- org.wso2.carbon.identity.application.mgt
- ${carbon.identity.framework.version}
- compile
+ org.wso2.carbon.identity.workflow.impl.bps
+ org.wso2.carbon.identity.workflow.mgt.stub
+ ${identity.workflow.impl.bps.version}
org.wso2.carbon.identity.workflow.impl.bps
- org.wso2.carbon.identity.workflow.impl.stub
+ org.wso2.carbon.identity.workflow.impl
${identity.workflow.impl.bps.version}
org.wso2.carbon.identity.workflow.impl.bps
- org.wso2.carbon.identity.workflow.impl
+ org.wso2.carbon.identity.workflow.impl.stub
${identity.workflow.impl.bps.version}
+
+ org.wso2.carbon.identity.framework
+ org.wso2.carbon.identity.application.mgt
+ ${carbon.identity.framework.version}
+ compile
+
org.wso2.carbon.identity.user.ws
org.wso2.carbon.um.ws.api
@@ -857,7 +857,7 @@
7.0.110
3.6.1
1.22.0
- 3.2.0
+ 2.4.0
1.4
4.5.13
4.4.8
@@ -883,9 +883,9 @@
1.1.3
3.1
5.4.0
- 5.18.0
+ 7.0.110
1.5.6.wso2v1
- 5.4.1
+ 5.5.7
5.4.0
1.7.28
1.6.1-wso2v43
@@ -915,7 +915,7 @@
[1.2.0,2.0.0)
[5.18,6.0)
2.6.0.wso2v1
- [5.14.67, 6.0.0]
+ [5.14.67, 8.0.0]
[2.26.0,8.0.0)
[1.3.0,3.0.0)
[1.0.5, 2.0.0)
diff --git a/sample-outbound-connector/pom.xml b/sample-outbound-connector/pom.xml
index 46aed4265..d2dcde9b3 100644
--- a/sample-outbound-connector/pom.xml
+++ b/sample-outbound-connector/pom.xml
@@ -132,7 +132,7 @@
wso2-nexus
WSO2 internal Repository
- http://maven.wso2.org/nexus/content/groups/wso2-public/
+ https://maven.wso2.org/nexus/content/groups/wso2-public/
true
daily
@@ -142,13 +142,25 @@
wso2.releases
WSO2 internal Repository
- http://maven.wso2.org/nexus/content/repositories/releases/
+ https://maven.wso2.org/nexus/content/repositories/releases/
true
daily
ignore
+
+ wso2.snapshots
+ Apache Snapshot Repository
+ https://maven.wso2.org/nexus/content/repositories/snapshots/
+
+ true
+ daily
+
+
+ false
+
+
diff --git a/user-mgt/custom-jdbc-user-store-manager/pom.xml b/user-mgt/custom-jdbc-user-store-manager/pom.xml
index 51807fd5e..88fe75302 100644
--- a/user-mgt/custom-jdbc-user-store-manager/pom.xml
+++ b/user-mgt/custom-jdbc-user-store-manager/pom.xml
@@ -21,13 +21,13 @@
org.wso2.samples.is
- wso2is-identity-samples-usermgt
+ samples-is
4.6.3-SNAPSHOT
- ../pom.xml
+ ../../pom.xml
4.0.0
- org.wso2.custom.user.store
+ custom-jdbc-user-store-manager
bundle
Custom JDBC User-store Manager
Custom JDBC User-store Manager
@@ -120,7 +120,7 @@
${project.artifactId}
${project.artifactId}
- org.wso2.custom.user.store.internal.*,
+ org.wso2.custom.user.store.internal,
org.jasypt.*
@@ -149,10 +149,10 @@
${project.version}
- [1.0.0, 2.0.0)
+ [4.6.0, 5.0.0)
- 4.6.2
+ 4.10.13
[4.6.0, 5.0.0)
[1.0.1, 2.0.0)
diff --git a/workflow/handler/service-provider/pom.xml b/workflow/handler/service-provider/pom.xml
index 5d5cb8caa..62720cdd8 100644
--- a/workflow/handler/service-provider/pom.xml
+++ b/workflow/handler/service-provider/pom.xml
@@ -26,7 +26,7 @@
bundle
- org.wso2.carbon.identity.framework
+ org.wso2.carbon.identity.workflow.impl.bps
org.wso2.carbon.identity.workflow.mgt
diff --git a/workflow/template/sample-template/pom.xml b/workflow/template/sample-template/pom.xml
index 5ddc821a7..c38b1ddb4 100644
--- a/workflow/template/sample-template/pom.xml
+++ b/workflow/template/sample-template/pom.xml
@@ -26,7 +26,7 @@
bundle
- org.wso2.carbon.identity.framework
+ org.wso2.carbon.identity.workflow.impl.bps
org.wso2.carbon.identity.workflow.mgt