ionCube Logo
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


 
Post new topic   Reply to topic    ionCube Forum Index -> ionCube PHP Encoder

ioncube error

Author Message
saigopal



Joined: 26 Aug 2005
Posts: 6

PostPosted: Fri Aug 26, 2005 12:45 pm    Post subject: ioncube error Reply with quote

hi nick,
Thanks . Now the error is not comming but i didnt used old ioncube 3 loaders.
i dont know how it happened. But i was wondering without generatiing license file how the encoded files can run. It should display license not found error. becoz encoded files are generated using --with-license option.

We are already using ioncube 5 . Plz can u send me the proper steps to use ioncube 6 with command that i posted. Once its get successful we may buy ioncube 6

many thanks
saigopal
my email id. saigopal@comodo.com
Back to top
View user's profile Send private message MSN Messenger
liaison
ionCube Support


Joined: 16 Dec 2004
Posts: 2788

PostPosted: Fri Aug 26, 2005 2:03 pm    Post subject: About corrupt files Reply with quote

Hi

Thanks for the followup here, you highlighted a potential user error. I suspect that you had accidentally reencoded a file that was already encoded. If the Loader detects a corrupted file, the default message is that the file is "corrupt", not "corrupted" as you had. A message saying that a file is "corrupted" can be generated by the default PHP preamble that starts each file. Here's the explanation.

The preamble on encoded files first checks to see whether the Loader is installed, and if it is then a corrupted file message is generated. The logic here is that if the Loader is installed then it would have recognised a valid file as encoded and therefore processed it. The preamble isn't used in that case. If the Loader didn't recognise the file then it would have passed it onto PHP, and the preamble would have been executed. If the Loader is installed and a file wasn't picked up by the Loader, it must be corrupted. Generally the Loader will itself detect files that are corrupt, but this else clause to the Loader check in the preamble catches files that the Loader passed up. So that's the logic in the case where a file really is corrupted.

HOWEVER, if you encode a file that is already encoded, when executed the premable will be run as that's what the encoded file contains, some PHP code and the encoded data. Following the logic above, you can see why the corrupted file message is generated in this case as the Loader is installed.

We're going to add a feature to the Encoder that will give a warning, and not reencode files that it believes to be encoded already.

About your files running even though you had specified a license file, this is because the option

Code:
--license-check script


was used. This option specifies that you want to do license checking in your scripts as opposed to having the Loader do the checking. This gives great flexibility, but you must remember to actually implement the checking of course! The safest way would be to inline the checking into the top level scripts, but if you use an included file to do this, take sensible security precautions when designing your application. We'd caution against a filename such as check_license.php, and make full use of the properties and include protection features to prevent the license checking script being replaced by another one.
_________________
Community Admin
Back to top
View user's profile Send private message
saigopal



Joined: 26 Aug 2005
Posts: 6

PostPosted: Fri Aug 26, 2005 2:18 pm    Post subject: Reply with quote

thanks nick for giving detailed explanation about encoding.
i checked my encoding script again and i have to say here that the corrupted error comes only if i put --with-license option . If i remove it it works fine. But my requirement is --with-license encoding. As u said earlier we need ioncube_loader 3 for ioncube6 encoded files. Can u provide the links to download. I dont think its availabe at u r site.
Back to top
View user's profile Send private message MSN Messenger
saigopal



Joined: 26 Aug 2005
Posts: 6

PostPosted: Fri Aug 26, 2005 2:29 pm    Post subject: Reply with quote

here is u r documenation which says about loader-event

its says file is corrupted:
To customise an event message, use:
--loader-event “<event>=<message>”
<event> should be the event type to customise and <message> the text to associate with the
event.
Event types are:
Event Type Triggered When…
An encoded file has been corrupted
corrupt-file
An encoded file has reached its expiry time
expired-file
Back to top
View user's profile Send private message MSN Messenger
liaison
ionCube Support


Joined: 16 Dec 2004
Posts: 2788

PostPosted: Fri Aug 26, 2005 2:41 pm    Post subject: Reply with quote

Hi

In that case it will be because you have old Loaders. The latest ones are available on our site for the most common OS's and have been for a while. Check your setup to ensure that you get the latest Loaders. If you use Encoder 6 but only use features that were supported by earlier Loaders, the Encoder will generate files that can be processed by the older Loaders. In other words, the Encoder produces files to give the maximum back compatibility possible. If you're still having problems or are unsure on this issue, please followup in the helpdesk.

For the corrupt file Loader event, processing this is only possible in some cases. The new features of 6 require a new file format, and it's not possible to process the corrupt file event in that case because the file cannot be decoded in the first place to know that the corrupt file event was customised. Custom corrupt file events can be successfully triggered if the Loader has processed enough of the encoded file to know that the corrupt file event has been customised.
_________________
Community Admin
Back to top
View user's profile Send private message
saigopal



Joined: 26 Aug 2005
Posts: 6

PostPosted: Fri Aug 26, 2005 2:50 pm    Post subject: Reply with quote

ok if this is the case. the for u r information i have folder in my project directory called ioncube which contains all the loader for all platforms.
SO according to u it should not give problem because i have all kind loaders in my folder .
lets assume if my script uses ioncube_loader_lin_4.3 will it support ioncube_encoder6 --with -license option. or i have to go for ioncube_lin_loader_5 . this file is also in ioncube project folder
Back to top
View user's profile Send private message MSN Messenger
saigopal



Joined: 26 Aug 2005
Posts: 6

PostPosted: Fri Aug 26, 2005 3:08 pm    Post subject: Reply with quote

hey nick, thanks man....it work here now. I got error saying
The encoded file /var/www/html/crm/prepend.inc requires a license file crmkey.

i edited my php.ini file which was pointing to ioncube _loader_lin _4.3 file and i changed it
to ioncube_loader_lin_5 in turn it generated above error.

i generated a license file using make_license and a passphrase. and it worked.
I think its correct. plz comment here.

thanks for u r coordination. Let us design the staergy we will then upgrade our ioncube encoder.
its really a great tool.
Back to top
View user's profile Send private message MSN Messenger
Display posts from previous:   
Post new topic   Reply to topic    ionCube Forum Index -> ionCube PHP Encoder All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum