Link | ldap_validuser |
Author | Jason Huck |
Category | LDAP |
Version | 8.5.x |
License | http://opensource.org/licenses/artistic-license.php |
Posted | 05 Oct 2006 |
Updated | 05 Oct 2006 |
More by this author... |
A shortcut for basic validation via LDAP.
var('isValid') = ldap_validuser( -host='0.0.0.0', -username='foo', -password='bar' ); if($isValid); // do something else; // do something else /if;
Click the "Download" button below to retrieve a copy of this tag, including the complete documentation and sample usage shown on this page. Place the downloaded ".inc" file in your LassoStartup folder, restart Lasso, and you can begin using this tag immediately.
define_tag( 'validuser', -namespace='ldap_', -req='host', -req='username', -req='password', -priority='replace', -description='Returns true if the given account authenticates against the given host.' ); local('ldap') = ldap; #ldap->open(#host); protect; #ldap->authenticate(#username,#password); local('valid' = true); handle_error; local('valid' = false); /handle_error; /protect; #ldap->close; return(#valid); /define_tag;
No comments
©LassoSoft Inc 2015 | Web Development by Treefrog Inc | Privacy | Legal terms and Shipping | Contact LassoSoft