Crypt::decrypt

public decrypt (mixed $text, [mixed $key]) Decrypts an encrypted text echo $crypt->decrypt($encrypted, "decrypt password");

Crypt::getAvailableCiphers

public getAvailableCiphers () Returns a list of available ciphers

Cookies Management

Cookies are a very useful way to store small pieces of data on the client’s machine that can be retrieved even if the user closes his/her browser. Phalcon\Http\Response\Cookies acts as a global bag for cookies. Cookies are stored in this bag during the request execution and are sent automatically at the end of the request. Basic Usage You can set/get cookies by just accessing the ‘cookies’ service in any part of the application where services can be accessed: use Phalcon\Mvc\Controller; class

Crypt::encryptBase64

public encryptBase64 (mixed $text, [mixed $key], [mixed $safe]) Encrypts a text returning the result as a base64 string

Crypt::getKey

public getKey () Returns the encryption key

Crypt::getCipher

public getCipher () Returns the current cipher

Crypt::decryptBase64

public decryptBase64 (mixed $text, [mixed $key], [mixed $safe]) Decrypt a text that is coded as a base64 string

Crypt

implements Phalcon\CryptInterface Source on GitHub Provides encryption facilities to phalcon applications $crypt = new \Phalcon\Crypt(); $key = 'le password'; $text = 'This is a secret text'; $encrypted = $crypt->encrypt($text, $key); echo $crypt->decrypt($encrypted, $key); Constants integer PADDING_DEFAULT integer PADDING_ANSI_X_923 integer PADDING_PKCS7 integer PADDING_ISO_10126 integer PADDING_ISO_IEC_7816_4 integer PADDING_ZERO integer PADDING_SPACE Methods public se

Crypt::encrypt

public encrypt (mixed $text, [mixed $key]) Encrypts a text $encrypted = $crypt->encrypt("Ultra-secret text", "encrypt password");

Config\Adapter\Yaml

extends class Phalcon\Config implements Countable, ArrayAccess Source on GitHub Reads YAML files and converts them to Phalcon\Config objects. Given the following configuration file: phalcon: baseuri: /phalcon/ controllersDir: !approot /app/controllers/ models: metadata: memory You can read it as follows: define('APPROOT', dirname(__DIR__)); $config = new Phalcon\Config\Adapter\Yaml("path/config.yaml", [ '!approot' => function($value) { return APPRO