DEV Community

Discussion on: Laravel .env Files Exposed In Browsers

Collapse
 
_shahroznawaz profile image
Shahroz Nawaz

No, It's not Laravel's fault. They recommend to setup webroot properly to /public. even specifying some htaccess rules also but this happened at developers end :D They need to secure it properly.

Collapse
 
joppedc profile image
JoppeDC

Could be better. Symfony checks for the env file, and if its there, it won't even run on production mode, only dev mode

Thread Thread
 
philnash profile image
Phil Nash

That makes more sense.

Collapse
 
philnash profile image
Phil Nash

Thing is, if you make it possible to expose credentials, but document how to avoid it, someone (many people, according to that Google search) will expose them.

It's up to the framework to build this such that developers can't make this mistake.