【问题标题】:Symfony2 Unrecognized options simple_preauthSymfony2 无法识别的选项 simple_preauth
【发布时间】:2014-01-09 12:14:02
【问题描述】:

我按照文档编写了自定义用户身份验证器:http://symfony.com/doc/current/cookbook/security/api_key_authentication.html 当我添加 app/security.yml

    pattern: ^/
    stateless: true
    simple_preauth:
        authenticator: sso_authenticator

它说: InvalidConfigurationException: Unrecognized options "simple_preauth" under "security.firewalls.secured_area" 什么可以导致这个问题如何解决?

【问题讨论】:

  • 你使用哪个版本的 Symfony2?它仅在 2.4 中可用
  • 是的,这是一个原因,我将版本从 2.3 更新到 2.4 现在没问题!谢谢

标签: php security symfony authentication service


【解决方案1】:

这个问题是由于版本引起的。 simple_preauth 选项是在 symfony 2.4 中创建的。更多参考SimplePreAuthenticationFactory.php

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2014-08-21
    • 2020-07-02
    • 2018-02-06
    • 2021-11-08
    • 2017-02-14
    • 2022-06-17
    • 2022-10-12
    相关资源
    最近更新 更多