Latest PHP recipes tagged "security" Code RecipesGenerate a salt (PHP) 2012-07-10T19:52:17-07:00Xavier L. <p style="color: grey"> PHP recipe 576894 by <a href="/recipes/users/4171602/">Xavier L.</a> (<a href="/recipes/tags/crypt/">crypt</a>, <a href="/recipes/tags/generation/">generation</a>, <a href="/recipes/tags/generator/">generator</a>, <a href="/recipes/tags/hash/">hash</a>, <a href="/recipes/tags/pass/">pass</a>, <a href="/recipes/tags/password/">password</a>, <a href="/recipes/tags/salt/">salt</a>, <a href="/recipes/tags/secure/">secure</a>, <a href="/recipes/tags/security/">security</a>, <a href="/recipes/tags/string/">string</a>). Revision 6. </p> <p>This function will generate a salt for use with passwords ranging using characters in range a to z, A to Z, 0 to 9 and !@#$%&amp;<em>?. The characters are sorted in a random value and can appear more than one time in the string. This way, this function is more powerful than the *shuffle()</em> function. This means that the salt could also be longer than the character list.</p> Hash text simply (PHP) 2012-04-30T21:43:00-07:00Xavier L. <p style="color: grey"> PHP recipe 576893 by <a href="/recipes/users/4171602/">Xavier L.</a> (<a href="/recipes/tags/crypt/">crypt</a>, <a href="/recipes/tags/extensible/">extensible</a>, <a href="/recipes/tags/generator/">generator</a>, <a href="/recipes/tags/hash/">hash</a>, <a href="/recipes/tags/php/">php</a>, <a href="/recipes/tags/secure/">secure</a>, <a href="/recipes/tags/security/">security</a>, <a href="/recipes/tags/simple/">simple</a>). Revision 5. </p> <p>This is a simply and extensible script that can be used to rapidly has any amount of text using PHP's hash() built-in function.</p> <p>It recognizes when the page is loaded for the first time and displays a form with options. Afterward, it display the selected hash(es), with a link at the bottom to start again.</p> SPICE for PHP (PHP) 2008-04-30T17:30:49-07:00Stephen Chappell <p style="color: grey"> PHP recipe 572178 by <a href="/recipes/users/2608421/">Stephen Chappell</a> (<a href="/recipes/tags/security/">security</a>). </p> <p>SPICE has been in development since 2002. The first version was implemented on a graphing calculator, designed to work with base 27 numbers, and used hard coded keys. The program was ported to Java and later redesigned in Python. This implementation was ported directly from the standard code base.</p> Protect PHP File that must be include (PHP) 2003-06-24T17:41:18-07:00imam ferianto <p style="color: grey"> PHP recipe 207176 by <a href="/recipes/users/633541/">imam ferianto</a> (<a href="/recipes/tags/security/">security</a>). </p> <p>This Section is describe how we can protect php module that can calling in with include function, but is not secure and its have big risk. For the solution is we can make this module file cannot execute or calling when it's not include, the code simple with test file name. Some study case: we hosting in sites that we cannot protection in dir, regulary we add .htacces in folder /inc/ I was putin .htacces so if we calling <a href="http://localhost/inc/" rel="nofollow">http://localhost/inc/</a> is displayed forbidden but if I try if we calling <a href="http://localhost/inc/connect-module.php" rel="nofollow">http://localhost/inc/connect-module.php</a> it will be succesfull and maybe some accident will happen here</p> Password generation (PHP) 2002-11-29T04:55:53-08:00Alan Prescott <p style="color: grey"> PHP recipe 164739 by <a href="/recipes/users/843068/">Alan Prescott</a> (<a href="/recipes/tags/security/">security</a>). </p> <p>Improved version of make_password submitted by Shane Caraveo. This one adds options to use upper case characters, numerics and special characters.</p> php htaccess (PHP) 2002-04-25T13:33:27-07:00Sven Wagener <p style="color: grey"> PHP recipe 108479 by <a href="/recipes/users/182412/">Sven Wagener</a> (<a href="/recipes/tags/security/">security</a>). Revision 2. </p> <p>The htaccess class manages the htaccess functions of Apache Webservers. Without knowing much knowledge of Apache, users can be added or deleted, groups can be created anddeleted, .htaccess files can be created with this class etc.</p> Password Generation (PHP) 2001-12-07T11:02:07-08:00Shane Caraveo <p style="color: grey"> PHP recipe 101526 by <a href="/recipes/users/98233/">Shane Caraveo</a> (<a href="/recipes/tags/security/">security</a>). </p> <p>Quite often you need to generate passwords for user authentication systems.</p> LDAP Authentication (PHP) 2001-12-07T11:00:34-08:00Shane Caraveo <p style="color: grey"> PHP recipe 101525 by <a href="/recipes/users/98233/">Shane Caraveo</a> (<a href="/recipes/tags/security/">security</a>). </p> <p>A simple LDAP Authentication script.</p>