php - Usage of Blenc extension of Apache -
i'm bit confused while using blenc v1.1.4b in apache 2.2 on ubuntu 12.04 php 5.3.10. tutorial online, have encrypt php scripts using key file. use following commands encrypt php scripts:
export blencode='php -f /path/to/blenc-1.1.4b/tools/blencode.php' $blencode plain.php
the script will:
- create 32-character blowfish unencrypted key
- create 44-character redistributable key file in same directory, named
key_file.blenc
- create backup directory save original
plain.php
- convert
plain.php
encrypted versionplain.phpenc
- create symlink named
plain.php
, linkplain.phpenc
it returns:
fatal error: blenc_compile: validation of script '/path/to/plain.php' failed, cannot execute. in unknown on line 0
seems failed. copy contents of key_file.blenc
/usr/local/etc/blenckeys
(assume have rights write file):
cat key_file.blenc > /usr/local/etc/blenckeys
reload browser, still fails. create .htaccess
define key is:
php_value blenc.keyfile /usr/local/blenc/blenckeys
reload browser again. success! php page starts load. other pages, repeat command, such as:
$blencode second_page.php cat key_file.blenc > /usr/local/etc/blenckeys
last, remove or move backup
directory , key_file.blenc
.
my questions are:
- do have save blowfish unencrypted key?
- how can in batch , encrypt files once updated (i.e. how manage files while using blenc)?
- should in local computer or should run @ web server?
- since blenc not require
<?php
,?>
, removing tags quite troublesome, workarounds blenc can support php tags?
Comments
Post a Comment