如何设置simplesamlphp以将ADFS 2用作idp

时间:2011-10-14 13:24:50

标签: php saml adfs2.0 federated-identity saml-2.0

我正在尝试使用Simplesamlphp 1.8将ADFS 2用作IdP。

现在我在获取浏览器NTLM身份验证对话框时非常困难,该对话框不接受任何登录(在选择“测试身份验证源” - >“default-sp”之后)。

在config / config.php

'default-sp' => array(
        'saml:SP',
        'privatekey' => 'saml.pem',
        'certificate' => 'saml.crt',
        'idp' => 'http://fs.example.org/adfs/services/trust',
    ),

在metadata / saml20-idp-remote.php中(使用/admin/metadata-converter.php从https://fs.example.com/FederationMetadata/2007-06/FederationMetadata.xml转换)

    $metadata['http://fs.example.com/adfs/services/trust'] = array (
  'entityid' => 'http://fs.example.com/adfs/services/trust',
  'contacts' => 
  array (
  ),
  'metadata-set' => 'saml20-idp-remote',
  'SingleSignOnService' => 
  array (
    0 => 
    array (
      'Binding' => 'urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect',
      'Location' => 'https://fs.example.com/adfs/ls/',
    ),
    1 => 
    array (
      'Binding' => 'urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST',
      'Location' => 'https://fs.example.com/adfs/ls/',
    ),
  ),
  'SingleLogoutService' => 
  array (
    0 => 
    array (
      'Binding' => 'urn:oasis:names:tc:SAML:2.0:bindings:HTTP-Redirect',
      'Location' => 'https://fs.example.com/adfs/ls/',
    ),
    1 => 
    array (
      'Binding' => 'urn:oasis:names:tc:SAML:2.0:bindings:HTTP-POST',
      'Location' => 'https://fs.example.com/adfs/ls/',
    ),
  ),
  'ArtifactResolutionService' => 
  array (
  ),
  'keys' => 
  array (
    0 => 
    array (
      'encryption' => true,
      'signing' => false,
      'type' => 'X509Certificate',
      'X509Certificate' => 'MIIC3DCCA....',
    ),
    1 => 
    array (
      'encryption' => false,
      'signing' => true,
      'type' => 'X509Certificate',
      'X509Certificate' => 'MIIC1j....',
    ),
  ),
);

在ADFS声明规则中,我有“允许所有用户访问”和转换规则“电子邮件地址 - >名称ID”

任何想法如何进行?

1 个答案:

答案 0 :(得分:2)

实际问题在于,在设置DNS记录时,我创建了一个CNAME fs.example.com到dc.exampledomain.com。将CNAME记录替换为A记录后,身份验证就完成了。

这并没有解决整个问题,但回答了被卡住的部分:)

我还需要在依赖方属性而不是SHA-256中将SHA-1设置为安全哈希算法。