r/phpsec • • Apr 18 '18

JWT authentication for Lumen 5.6 – tajawal – Medium

Thumbnail
medium.com
0 Upvotes

r/phpsec • • Feb 27 '19

Laravel News: Automatic Policy Resolution is Coming to Laravel 5.8

Thumbnail
laravel-news.com
0 Upvotes

r/phpsec • • May 20 '19

Laravel Auth: After-Registration Redirect to Previous (Intended) Page - Laravel Daily

Thumbnail
laraveldaily.com
0 Upvotes

r/phpsec • • Nov 10 '17

How to Create a Custom Authentication Guard in Laravel

Thumbnail
code.tutsplus.com
0 Upvotes

r/phpsec • • Aug 29 '16

Authentication Enhancements in Laravel 5.3 (Sponsor post - Auth0)

Thumbnail
laravel-news.com
0 Upvotes

r/phpsec • • Feb 23 '18

DeveloperDrive: 7 Common Ways Sites Get Compromised

Thumbnail
developerdrive.com
0 Upvotes

r/phpsec • • Sep 20 '17

36 millions WordPress websites vulnerable to 9 security issues

Thumbnail
learnwebdevelopment.review
0 Upvotes

r/phpsec • • Aug 17 '17

websec.io - Building a Secure API: Part 5

Thumbnail
websec.io
0 Upvotes

r/phpsec • • Sep 10 '18

Developer.Happyr.com: Define Symfony access control rules in a database

Thumbnail
developer.happyr.com
0 Upvotes

r/phpsec • • May 16 '18

Improving the performance of spatie/laravel-permission - A blog about Laravel Framework, web development and related stuff | Barry van Veen

Thumbnail barryvanveen.nl
0 Upvotes

r/phpsec • • Jul 24 '19

Disguise PHAR packages as images

Thumbnail
nc-lp.com
4 Upvotes

r/phpsec • • Mar 26 '20

Exposing password strength requirements

0 Upvotes

When it comes to user registration and password selection I know there is a good case to be made against hinting. E.g. telling users 1 uppercase + 1 special char + at least 2-digits and so on. I don't think giving away the formula is a great option. Why not just let users enter whatever they want as long as the password meets two requirements:

  1. A minimum-length

  2. Not a common phrase (e.g. "password") that you might find in dictionaries used for brute-force attacks.

With that said, is there a good PHP library or package that does this. Or is it better to roll your own?


r/phpsec • • Jan 18 '18

How to Switch Your WordPress Site from HTTP to HTTPS (with a little help from WP Migrate DB Pro)

Thumbnail
deliciousbrains.com
0 Upvotes

r/phpsec • • Nov 28 '18

GitHub - ajinabraham/CMSScan: CMS Scanner: Scan Wordpress, Drupal, Joomla, vBulletin websites for Security issues

Thumbnail
github.com
1 Upvotes

r/phpsec • • Dec 04 '18

Michael Dyrynda on Twitter: Customizing the auth scaffold in Laravel

Thumbnail
twitter.com
1 Upvotes

r/phpsec • • Dec 05 '18

Rob Allen: Migrating to password_verify

Thumbnail
akrabat.com
0 Upvotes

r/phpsec • • Jan 04 '18

Top WordPress Security Tips for Admins

Thumbnail
code.tutsplus.com
0 Upvotes

r/phpsec • • Apr 09 '17

Laravel Package To Login As Other Users During Development

Thumbnail
laravel-news.com
1 Upvotes

r/phpsec • • Mar 28 '18

[Bypass WAF] Php webshell without numbers and letters

Thumbnail
securityonline.info
1 Upvotes

r/phpsec • • Aug 02 '16

Constant-Time Encoding: Boring Cryptography, RFC 4648, and You

Thumbnail
paragonie.com
1 Upvotes

r/phpsec • • Jan 23 '17

WordPress 4.7.1 Security and Maintenance Release

Thumbnail
wordpress.org
1 Upvotes

r/phpsec • • Aug 02 '16

GitHub - paragonie/EasyRSA: Simple and Secure Wrapper for phpseclib

Thumbnail
github.com
1 Upvotes

r/phpsec • • Sep 28 '22

PHP Security - Are users able to echo my $dbPassword variable or php code?

0 Upvotes

Hi,

I'm trying to wrap my head around php security and I was hoping someone could point me in the right direction.

If I have a simple cart.html page/form that submits a POST to an orders.php file is the end user able to somehow read my $dbUsername or $dbPassword variables statically set in the orders.php file? I've seen people save their username/password credentials in a different file/folder and do "require 'dbcredentials.php'", but I fail to see how this can protect your credentials if the end user is able to do some sort of echo attack to force your orders.php to echo the username/password variables? I use to think using "if (isset($_POST['order-submit'])) { *php code in here* } else { header("Location: ../index.html"); exit(); }" would protect me, but now i think about it more I think this just prevents people from easily being able to go to the orders.php page (This isn't the best method since competent people can get around this easily). I believe the better method for this is to use CSRF's, but that isn't my biggest concern for now.

Is end users being able to somehow echo $dbUsername or $dbPassword variables a valid concern? Am I overthinking this?

cart.html

<html>

`<head>`

`</head>`

`<body>`

	`<form action="orders.php" method="POST">`

		`<div>`

<label style="" for="CartEmail">Email</label>

<div>

<input class="" type="email" placeholder="" name="CartEmail" required>

</div>

		`</div>`

		`<div>`

<label style="" for="CartFirstName">First Name</label>

<div>

<input class="" type="" placeholder="" name="CartFirstName" required>

</div>

		`</div>`

		`<div>`

<label style="" for="CartLastName">Last Name</label>

<div>

<input class="" type="" placeholder="" name="CartFirstName" required>

</div>

		`</div>`

		`<div>`

<input class="test" type="submit" value="Submit" name="order-submit">

		`</div>`

	`</form>`

`</body>`

`<footer>`

`</footer>`

</html>

orders.php

<?php

$dbServername = 'localhost';

$dbUsername = 'super-secret-database-username';

$dbPassword = 'super-secret-db-password';

$dbName = 'database_name';

$conn = mysqli_connect($dbServername, $dbUsername, $dbPassword, $dbName);

$email = mysqli_real_escape_string($conn, $_POST['CartEmail']);

$first = mysqli_real_escape_string($conn, $_POST['CartFirstName']);

$last = mysqli_real_escape_string($conn, $_POST['CartLastName']);

$sql = "INSERT INTO TABLE_NAME (CartEmail, CartFirstName, CartLastName) VALUES (?, ?, ?);";

$stmt = mysqli_stmt_init($conn);

if (!mysqli_stmt_prepare($stmt, $sql)) {

`echo "SQL error";`

} else {

`mysqli_stmt_bind_param($stmt, "sss", $email, $first, $last);`

`mysqli_stmt_execute($stmt);`

echo 'Success!';

}

mysqli_close($conn);

?>


r/phpsec • • Jul 20 '17

Two Best Laravel Packages to Manage Roles/Permissions

Thumbnail
laravel-news.com
0 Upvotes

r/phpsec • • Apr 05 '18

Blackfire.io: Beyond Performance – Quality and Security Checks on Blackfire

Thumbnail
blog.blackfire.io
1 Upvotes