The SAML module in Mendix enables Single Sign-On (SSO) by integrating your application with external identity providers like Azure Active Directory (Azure AD). It facilitates encrypted communication, streamlines user access management, and strengthens application security.
Regularly upgrading your Mendix app and the SAML module is essential to ensure optimal security, performance, and compatibility. This guide walks you through the secure upgrade process and outlines common issues and their solutions.
What is SAML?
SAML (Security Assertion Markup Language) is an open standard that enables secure authentication and authorization between identity providers and service providers. It is commonly used for SSO to offer users seamless access across systems without needing to log in repeatedly.
Steps to Upgrade
Ensure that any deprecated features are addressed and check the Mendix release notes for any breaking changes.
These versions include critical fixes for Azure AD integration.
Once the application runs error-free:
Troubleshooting Common Issues
Issue 1: SAML v2.15.3 Error
Error Message:
org.opensaml.xml.signature.impl.CryptoBinaryBuilder cannot be cast to org.opensaml.core.xml.XMLObjectBuilder
Cause: Conflicting version of opensaml JAR in the userlib.
Fix:
Delete org.apache.servicemix.bundles.opensaml-2.6.0_3 from the userlib folder.
Clean the deployment directory.
Rebuild and retest the application.
Solution:
Issue 2: Java Code Compilation Errors
Problem:
Compilation errors, like “cannot find symbol”, may appear when running the project locally. These errors are typically caused by conflicting JAR files in the userlib folder.
Solution:
Issue 3: APPLICATION_SOAP_XML Compilation Error
Error Message:
cannot find symbol: variable APPLICATION_SOAP_XML
Cause: Missing or incompatible libraries.
Fix:
Example:
error: cannot find symbol
httpPost.setEntity(new ByteArrayEntity(authnState.getModifiedSOAPRequest().getBytes(), ContentType.APPLICATION_SOAP_XML));
Resolution:
Upgrading your Mendix app and the SAML module ensures security, reliability, and compatibility with modern identity systems like Azure AD. By following the steps in this guide, you can:
Note: Schedule regular reviews of your app dependencies to avoid unexpected issues in production
Quick Links
Locations