1
我的Symfony2应用程序存在一个大问题。 我用FosRestBundle,FosUserBundle和LexikJWTAuthenticationBundle创建了RestFul Api。 在我的电脑上,没问题,验证效果很好。 但是,当我在OVH共享服务器上(perf1)上传整个应用程序时,开发环境仍然可用,但不是产品。它说不好的凭据... 我使用邮递员尝试。Symfony2 - 在产品模式下验证失败
我security.yml如下:
security:
encoders:
FOS\UserBundle\Model\UserInterface:
algorithm: pbkdf2
hash_algorithm: sha512
encode_as_base64: true
iterations: 1000
role_hierarchy:
ROLE_ADMIN: ROLE_USER
ROLE_SUPER_ADMIN: ROLE_ADMIN
providers:
fos_userbundle:
id: fos_user.user_provider.username_email
firewalls:
login:
pattern: ^/auth/login
stateless: true
anonymous: true
form_login:
provider: fos_userbundle
check_path: /auth/login
success_handler: lexik_jwt_authentication.handler.authentication_success
failure_handler: lexik_jwt_authentication.handler.authentication_failure
require_previous_session: false
username_parameter: username
password_parameter: password
post_only: true
api_open:
pattern: ^/api/open
anonymous: true
stateless: true
lexik_jwt: ~
api_secured:
pattern: ^/api
anonymous: false
stateless: true
lexik_jwt: ~
access_control:
我已经清除和热身督促缓存。
你知道它从哪里来的吗?
谢谢。
在你的web/app.php文件中,尝试$ kernel = new AppKernel('prod',true);调试设置可能会给你一个线索。 – Cerad
它不显示错误... – user3100287
但它在共享服务器上的开发工作?一个神秘的位。 – Cerad