KNOWLEDGE BASE

SAML Metadata XML File Exported From Tableau Server Contains Code Block


Published: 16 Sep 2016
Last Modified Date: 21 Nov 2016

Issue

When you click "Export Metadata File" in the SAML tab of the Tableau Server Configuration dialog, the file that results has a code block in it and is treated as invalid by your idP.

For example
 
<?xml version="1.0" encoding="UTF-8"?>
<%
def get_cert_content
    return '' if wgserver.saml.cert.file.nil? || wgserver.saml.cert.file.empty?
    certFile = Cfg.win32 ? wgserver.saml.cert.file : wgserver.saml.cert.file.to_s.gsub('\\', '/')
    return (IO.read(certFile).gsub(/-----BEGIN CERTIFICATE-----\n/, '').gsub(/-----END CERTIFICATE-----\n/, ''))
end
%>
<md:EntityDescriptor xmlns:md="urn:oasis:names:tc:SAML:2.0:metadata" ID="http://blah" entityID="http://blah">
    <md:SPSSODescriptor AuthnRequestsSigned="true" WantAssertionsSigned="true" protocolSupportEnumeration="urn:oasis:names:tc:SAML:2.0:protocol">
        <md:KeyDescriptor use="signing">

Environment

Tableau Server 10.0

Resolution

Option 1

Upgrade to Tableau Server 10.0.2. For more information, see Upgrading Tableau Server.

Option 2

Manually remove the code block from the XML file after exporting it.

Cause

This behavior is related to a known defect (ID: 563630) that has been fixed in the release 10.1 of Tableau Server.

Additional Information

This behavior only occurs when generating a new Metadata XML file. If you are using an existing Metadata XML file generated in a previous version, configuration will proceed normally. 

 
Did this article resolve the issue?