Laragon is sending Access-Control-Allow-Origin * header


  • | 675 points

    I noticed that since I updated to 2.1.0 laragon is always sending a Access-Control-Allow-Origin *. This is really bad because chrome will throw the error that multiple headers can't be present.

    I'm using the Laravel Cors package. I also know that is Laragon because I put the header(;Access-Control-Allow-Origin 123'); up at the top of the public/index.php & the Access-Control-Allow-Origin 123 is on the bottom of Access-Control-Allow-Origin * so that means that there is a header being generated before laravel is even called.

    I tested by starting up a php server in laravel php artisan serve & it didn't have a Access-Control-Allow-Origin *

    ************ Fixed

    Go to your httpd.conf line 527 comment it out Header always set Access-Control-Allow-Origin "*"


  • administrators
    | 62136 points

    Thanks @dragonfire1119 , it is for CORS. I'll check and make a permanent fix if Chrome complains :)


Log in to reply
 

Looks like your connection to Laragon was lost, please wait while we try to reconnect.