The only supported ciphers are AES-128-CBC and AES-256-CBC with the correct key lengths. laravel 5.3

后端 未结 14 1734
一个人的身影
一个人的身影 2020-12-01 01:09

I installed a new fresh copy of Laravel 5.3 using composer but I\'m getting this error:

The only supported ciphers are AES-128-CBC and AES-256-CBC wit

14条回答
  •  余生分开走
    2020-12-01 01:53

    in .env file give this key and you are done

    APP_KEY=ABCDEF123ERD456EABCDEF123ERD456E
    

    Still not working?

    If you are working from cli, reboot the server and it will.

    Want explanation?

    ok, as the error message says:

    The only supported ciphers are AES-128-CBC and AES-256-CBC with the correct key lengths.

    Key length for AES-128-CBC is 16 characters e.g ABCDEF123ERD456E

    Key length for AES-256-CBC is 32 characters e.g ABCDEF123ERD456EABCDEF123ERD456E

    Make sure in config/app.php the cipher is set to the appropriate cipher like the two above and the key is pointing to the .env file APP_KEY variable. My app has the AES-256-CBC cipher set, so i gave it the 32 characters key like APP_KEY=ABCDEF123ERD456EABCDEF123ERD456E and everything worked just fine after that.

提交回复
热议问题