PEAR Manual
Prev |  | Next

# File_Passwd_Cvs::generatePassword()

File_Passwd_Cvs::generatePassword() -- Generate password

## Synopsis

``string File_Passwd_Cvs::generatePassword` (string $pass [, string $salt = null])`

## Description

Generate a "CVS" pserver style password.

## Parameter

string `$pass`

  the plaintext password to encrypt

string `$salt`

  the salt to use for encryption (usually empty)

## Return value

Returns string encrypted password.

## Example

Example 37-1. File_Passwd_Cvs::generatePassword()
    require_once 'File/Passwd/Cvs.php';
    $pass = File_Passwd_Cvs::generatePassword('secret');

## Note

This function should be called statically.

Prev | Home | Next
File_Passwd_Cvs::verifyPasswd() | Up | MP3_Id