c - Decryption of a file on php server using openssl commands -


i encrypting file on client side , trying decrypt on linux server using openssl command, creating output file 0 bytes size.

the code using in php decrypting file is:

system("openssl enc -d -aes-192-ecb -in secure.cxf -out plain.xml -k 11223344556677889900aabbccddeeff0011223344556677");

here using aes in ecb mode 192 bit (24 byte) key,

where

secure.cxf input file in same folder php file

plain.xml output file comes 0 bytes

11223344556677889900aabbccddeeff0011223344556677 private key of decryption

i have tried same openssl command on different linux operationg systems, command works fine on server makes empty output file. idea how resolve empty file problem? there alternative way same decryption (aes, ecb mode, 192 bit key) files on php server?

thanks in advance.

try 1 of this:

a) create empty file plain.xml , permission 0666 chmod 0666 plain.xml

or

b) set permission on parent directory php file. chmod 0777 directorywithmyfile

you can in ftp client or ssh.

another way - phpinfo() find tmp dir , use dir.


Comments

Popular posts from this blog

image - ClassNotFoundException when add a prebuilt apk into system.img in android -

I need to import mysql 5.1 to 5.5? -

Java, Hibernate, MySQL - store UTC date-time -