Jump to content
Welcome to our new Citrix community!
  • NetScaler Gateway and Microsoft Azure Multi-Factor Authentication Part 2


    Richard Faulkner
    • Validation Status: Validated
      Summary: NetScaler Gateway presents all hosted, SaaS, web, enterprise, and mobile applications to users on any device and any browser. It uses nFactor Authentication to authenticate users against on-premises Microsoft AD and leverages Microsoft AD FS for Azure Multi-Factor Authentication (MFA).
      Has Video?: No

    Continued from Part 1

    Configure the AD FS farm

    Now you can begin your AD FS post-deployment configuration from Server Manager. Click Configure the federation service on this server.

    add-adfs-role-to-windows-server-2016-post-deployment-configuration-alert.png.a5c7b16fe9bb46ee9a1a0b4fd4faa4ea.png

    On the Welcome page, select Create the first federation server in a federation server farm, and then click Next.

    adfs-post-deployment-configuration-create-the-first-federation-server-in-a-federation-server-farm.png.30e80271f605f31ef8757f835510c453.png

    On the Connect to Active Directory Domain Services page, ensure the Domain Administrator account is specified, and then click Next.

    adfs-post-deployment-configuration-connect-to-active-directory-domain-services.png.26bbbffdc44a9f7d9ea14867965a223a.png

    On the Specify Service Properties page, complete the following steps, and then click Next:

    • Choose the certificate which was installed on the server in the previous steps.
    • The federation service name will automatically be populated based on the subject name of the certificate.
    • Put the display name for the federation service. For example, CTXDEMOS STS.

    adfs-post-deployment-configuration-specify-service-properties.png.83090d2d6f7cbcccccb4b88635ad0e76.png

    On the Specify Service Account page, select Create a Group Managed Service Account, and enter a unique name for this account. Group Managed Service Accounts are supported in Windows Server 2012 onwards and come with strict, complex passwords which are changed automatically every 30 days. Click Next.

    adfs-post-deployment-configuration-create-a-group-managed-service-account.png.f73c8b97d524be372236ff94b74478e4.png

    On the Specify Configuration Database page, select specify the location of a SQL Server database. Click Next.

    adfs-post-deployment-configuration-specify-configuration-database.png.4263277f738a373985dbc7dbc12b8183.png

    On the Review Options page, verify your configuration selections, and then click Next.

    adfs-post-deployment-configuration-review-options.png.0a4a52b13a027dede0a6cc21d2427aa0.png

    On the Pre-requisite Checks page, verify that all prerequisite checks are successfully completed, and then click Configure.

    adfs-post-deployment-configuration-pre-requisite-checks.png.ee3fcd7c801ecb37dc0691de3be695d9.png

    On the Results page, ensure that the installation is successful. Click Close to exit the wizard.

    adfs-post-deployment-configuration-results.png.13b302b4b606da313ad8b6e0699d6aad.pngOTE:

    To complete the following steps, you will need your Azure Tenant ID.

    You can get the Azure Tenant ID by following the steps in the Microsoft documentation article, Get AzureID Tenant Detail.

    Microsoft documentation also provides information about the Azure MFA Client GUID in Configure AD FS 2016 and Azure MFA.

    Configure AD FS farm - automated

    You can run the following PowerShell script:

    ## Windows PowerShell script for AD FS Deployment#Import-Module ADFSInstall-AdfsFarm `-CertificateThumbprint:"BD02F30D90A96EEE4A5934F2EA979E7A052584AE" `-FederationServiceDisplayName:"CTXDEMOS STS" `-FederationServiceName:"adfs.ctxdemos.com" `-GroupServiceAccountIdentifier:"C

    Configure AD FS with Azure MFA

    Configure AD FS servers

    On each of your AD FS servers, launch PowerShell and run the following commands:

     

    # Install Windows PowerShell MSOnline ModuleInstall-Module MSOnline# Import Windows PowerShell MSOnline ModuleImport-Module MSOnline# Get the Azure Global Administrator credential$credential = Get-Credential# Sign in to your Azure Active Directory environmentConnect-MsolService -Credential $credential# Set a variable for the Azure Tenant name$azureTenantID = "ctxdemos.onmicrosoft.com"# Set a variable for the Azure MFA Client GUID$azureMFAClientGUID = "981f26a1-7f43-403b-a875-f8b09b8cd720"# Generate a certificate for the Azure MFA on AD FS server$azureMFACertificate = New-AdfsAzureMfaTenantCertificate -TenantId $azureTenantID# Add the new credentials to the Azure MFA Client Service PrincipalNew-MsolServicePrincipalCredential -AppPrincipalId $azureMFAClientGUID -Type asymmetric -Usage verify -Value $azureMFACertificate

    Configure AD FS farm

    Only on one of the AD FS servers, run the following command:

    Set-AdfsAzureMfaTenant -TenantId $azureTenantID -ClientId $azureMFAClientGUID

    Restart the AD FS service on each of your servers. Then you will see that Azure MFA is available as the primary and multifactor authentication method for the intranet and extranet use.

    adfs-configuration-with-azuremfa-primary-authentication-method.png.4d7848f96fef18d5fb917f837e992654.png

    adfs-configuration-with-azuremfa-multi-factor-authentication-method.png.35097a1d4b239425cad0f2d5f3276190.png

    Configure AD FS with NetScaler ADC

    You need to create a federation trust between AD FS and NetScaler ADC. In the AD FS Management Console, navigate to Relying Party Trust and select Add Relying Party Trust.

    adfs-add-relying-party-trust-start.png.d395240d0a4d1611b48e0a9cf3a4262e.png

    Select Enter data about the relying party manually and click Next.

    adfs-add-relying-party-trust-enter-data-about-the-relying-party-manually.png.4f591e003c978922934444c1640e115f.png

    Enter a descriptive display name and optional notes. Click Next.

    adfs-add-relying-party-trust-display-name-and-optional-notes.png.98c82f97ece5bf6c048adb0da8095465.png

    Click Next.

    adfs-add-relying-party-trust-configure-certificate.png.281fcbc291d0c7e4fe769ef062e3e7c5.png

    Select Enable support for the SAML 2.0 WebSSO protocol and enter https://NetScalerGatewayFQDN/cgi/samlauth. In the demo environment, it is https://access.ctxdemos.com/cgi/samlauth. Click Next.

     

     

    adfs-add-relying-party-trust-configure-url.png.6cc9529bec55a3a4a5bcc070a421ba50.png

    Enter a unique identifier string for the Relying Party Trust. In the demo environment, it is https://access.ctxdemos.com. This identifier will be used as an Issuer URL in the NetScaler ADC SAML profile. Click Next.

    adfs-add-relying-party-trust-configure-identifiers.png.424612419165dd7c1f4f779e2fe35088.png

    On the Choose Access Control Policy page, select Permit everyone and require MFA. Click Next.

    adfs-add-relying-party-trust-choose-access-control-policy.png.53afef9546bdc957372c5aa7a5fb3598.png

    Click Next.

    adfs-add-relying-party-trust-ready-to-add-trust.png.a51d4a9c41af5b8a876e75017501fd16.png

    On the Finish page, select Configure claims issuance policy for this application. Click Close.

    adfs-add-relying-party-trust-finish.png.22ebf9881b25bc34af55d684077a2368.png

    On the Issuance Transform Rules page, click Add Rule.

    adfs-issuance-transform-rules-start.png.1d42f29be3f4bb39d05394d396787bd2.png

    Click Next.

    adfs-issuance-transform-rules-select-rule-template.png.fa9575e79746f43896017f185db15e20.png

    Enter a descriptive name in the Claim rule name field. Under Attribute store, select Active Directory. Then select the following: LDAP Attributes and Outgoing Claim Types.

    adfs-issuance-transform-rules-configure-rule.png.36bfc2d3057dfcc0da2e47f4e41ba232.png

    Create a new rule and use Send Claims Using a Custom Rule as a Claim rule template. Enter a descriptive name for the Claim rule name and enter the following string for Custom rule:

     

     

    => issue(Type = "logoutURL", Value = "https://access.ctxdemos.com/cgi/tmlogout", Properties["http://schemas.xmlsoap.org/ws/2005/05/identity/claimproperties/attributename"] = "urn:oasis:names:tc:SAML:2.0:attrname-format:unspecified");

    adfs-issuance-transform-rules-logoff-configure-rule.png.73df769ef6a5e7f8fd3cd7906cec21c4.png

    When the Claim Issuance Policies are created, click Ok.

    Right-click Relying Party Trust > NetScaler ADC, and select Properties. Select Endpoints and add an endpoint by clicking Add SAML for Logout. From the Endpoint type list, select SAML Logout. For Binding, select POST, and for Trusted URL, enter https://sts.ctxdemos.com/adfs/ls/?wa=wsignout1.0. This will act as a logout URL when logging out of NetScaler ADC. Click OK.

    adfs-add-relying-party-trust-endpoint-saml-logout.png.9f71f180d8b57c335cdab53b519ec582.png

    Right-click Relying Party Trust > NetScaler ADC, and select Properties. Select Encryption and add a public SSL certificate that is installed on NetScaler Gateway. This certificate will be used to decrypt an incoming SML Request from NetScaler ADC. Repeat the same on the Signature tab. This certificate will be used to check the signature of an incoming SAML Request. Click OK.

    Enable IdP initiated sign-on page

    You can enable the AD FS IdP-initiated sign-on page. You will be using the IdP-initiated sign-on to present a custom error page to unregistered MFA users. To enable, run the following command:

    Set-AdfsProperties -EnableIdPInitiatedSignonPage $true

    Test AD FS farm

    Open a web browser and navigate to:

    NetScaler ADC and NetScaler Gateway

    Configure NetScaler Gateway

    You can configure NetScaler Gateway through the wizard. Log on to NetScaler ADC Management GUI, navigate to Unified Gateway, and click Create New Gateway. Then click Continue.

    adfs-single-public-access.thumb.png.76d6447ed2af4b1f8b449a9a2b88c4d0.png

    Enter the name, IP, and FQDN for Unified Gateway and click Continue.

    adfs-gateway-configuration.thumb.png.8c7323c3cb81945fd39bb50053041adb.png

    Select the public SSL certificate and click Continue.

    adfs-server-certificate.thumb.png.15c5760febe0cfe7088f68f193bb9743.png

    Create a basic LDAP policy and bind it to Unified Gateway. Click Continue.

    adfs-authentication.thumb.png.5c8329a3b2b82de45db309d146e8c8cf.png

    Create a portal theme based on RfWebUI and bind it to Unified Gateway. Click Continue.

    adfs-portal-theme.thumb.png.f7678c0bb3608158664acc164fe1dade.png

    Select the plus sign (+) in front of the applications to integrate NetScaler Gateway with StoreFront.

    adfs-applications.thumb.png.438000ad3d34700075a10ab640077905.png

    Integrate Citrix StoreFront into NetScaler Gateway

    On the Application page, select XenApp & XenDesktop, and from the Choose Integration Point list, select StoreFront. Click Continue.

    adfs-storefront.png.eaffa89ec2d997eb536be4fa92fee788.png

    Enter a StoreFront URL and click Retrieve Stores. Then enter the Default Active Directory Domain and Secure Ticket Authority URL settings. Click Test STA Connectivity and then click Continue.

    adfs-test-connectivity.png.9695db5b5d757e88e11deaee008acdca.png

    Click Done and then click Continue.

    adfs-continue.thumb.png.6feaf32b9de7c5f815b6c42183e79704.png

    Continued in Part 3

    User Feedback

    Recommended Comments

    There are no comments to display.



    Create an account or sign in to comment

    You need to be a member in order to leave a comment

    Create an account

    Sign up for a new account in our community. It's easy!

    Register a new account

    Sign in

    Already have an account? Sign in here.

    Sign In Now

×
×
  • Create New...