Jump to content

encrypt and decrypt the content of file


flix_is_here22
 Share

Recommended Posts

hi,i want to encrypt and decrypt the content of file. Now just i found the encrypt from http://www.w3schools.com/php/func_string_crypt.asp and that code work for mebut i didn't found the decrypt from w3schools....i found the decrypt tutor from http://www.php.net/manual/en/function.mcrypt-decrypt.phpbut i really don't understand.... :wacko: anyone can you explain to me....???? :facepalm:

  • Like 1
Link to comment
Share on other sites

The crypt() function is one-way encryption which is not meant to be decrypted. The mcrypt's decrypt() function is meant for a completely different thing. Encryption always involves an algorithm and a key, if not several keys. The mcrypt_decrypt() method is for decryptying data that was encrypted with this tunction: http://www.php.net/manual/en/function.mcrypt-encrypt.php

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...