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

后端 未结 14 1524
一个人的身影
一个人的身影 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.

    0 讨论(0)
  • 2020-12-01 01:58

    If the artisan command doesn't work and you get the same error in the command line, that means composer didn't do a good job at getting all the files, you should delete the vendor folder and run composer update again.

    0 讨论(0)
提交回复
热议问题