Jump to content

ioncube encryption of tpl files


gr2

Recommended Posts

While I haven't tested the template encryption with WHMCS specifically...

 

Please note that the script calling ioncube_read_file(), e.g. the template engine, must be encoded.
That means that the file "includes/smarty/Smarty.class.php" needs to be encoded as well. I'm guessing that you replaced the _read_file function, but haven't encoded the .PHP though? Edited by GGWH-James
Link to comment
Share on other sites

Hello mylove4life, GGWH-James,

 

Thank you both for your replies.

 

why do you want to encrypt the ioncube files?

sorry if i was not clear on that mylove4life, when i write tpl file i am referring to the files located in the templates directory with the .tpl extension.

 

GGWH-James,

 

in smarty.class.php, i commented out line3429 to 3455 and added the patch code directly under that.

 

encoded the file and uploaded it to the smarty directory.

 

i get this error:

 

Fatal error:

The encoded file /home/mydir/public_html/includes/smarty/Smarty.class.php is corrupt. in Unknown on line 0

 

thanks in advance for your time.

 

best regards

Andreas

Link to comment
Share on other sites

in smarty.class.php, i commented out line3429 to 3455 and added the patch code directly under that.

 

encoded the file and uploaded it to the smarty directory.

 

i get this error:

 

Fatal error:

The encoded file /home/mydir/public_html/includes/smarty/Smarty.class.php is corrupt. in Unknown on line 0

Did you encode the file in BINARY, but upload it in ASCII or AUTO mode? If you did encode it in BINARY, force BINARY mode in your FTP program while uploading the file.

Link to comment
Share on other sites

issue resolved.

 

Thank you all for your feedback.

 

for some ridiculous reason i felt the need to put the contents of the tpl files inside {php}{/php} tags thinking it was needed and that was my mistake.

 

yes, i had uploaded the smarty.class file in auto mode and that is why the file broke.

 

so just to let you all know, .tpl WHMCS files can be encoded with ioncube.

Edited by gr2
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated