phpBolt icon indicating copy to clipboard operation
phpBolt copied to clipboard

Namespace declaration statement has to be the very first statement or after any declare call in the script

Open shukla-rohit opened this issue 6 years ago • 18 comments

Hello,

I am facing one issue, in my file I have namespace, and after encryption with bolt, having line on top. bolt_decrypt( FILE , PHP_BOLT_KEY); return 0;

and later have encrypted code.

so when I am running file, getting compile error.

Description:Namespace declaration statement has to be the very first statement or after any declare call in the script Backtrace-------------------

So problem is that after encryption we are adding bolt_decrypt, and that is creating problem, if having namespace in file. Can you please suggest anything or any solution for this.

Regards,

shukla-rohit avatar Oct 01 '19 14:10 shukla-rohit

I am looking any solution for it. Do you have any solution for it?

shukla-rohit avatar Oct 03 '19 08:10 shukla-rohit

I have the same issue. Any solution on that ?

allanvb avatar Oct 26 '19 13:10 allanvb

Please download new version. Or please feel free to contact me. Skype : arshidkv12

arshidkv12 avatar Oct 26 '19 23:10 arshidkv12

@arshidkv12 Can you add the link of the latest version?

abhayvishwakarma avatar Nov 07 '19 11:11 abhayvishwakarma

Feel free to PM Skype: arshidkv12

On Thu, Nov 7, 2019, 4:49 PM abhayvishwakarma [email protected] wrote:

@arshidkv12 https://github.com/arshidkv12 Can you add the link of the latest version?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/arshidkv12/phpBolt/issues/4?email_source=notifications&email_token=ABT5Y5PLD5XJR75RX3OJ44DQSP2URA5CNFSM4I4KCMB2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDMCUCQ#issuecomment-551037450, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABT5Y5JIBWQAI3ZZLOVYURDQSP2URANCNFSM4I4KCMBQ .

arshidkv12 avatar Nov 07 '19 11:11 arshidkv12

We have also same issue.Could anyone share latest version of bolt.so and encryptor php file

Edit:Author deleted our all comments related with not finding solution to this problem. @allanvb

burakvural93 avatar Jan 16 '20 13:01 burakvural93

Encrypt controller folder only.

arshidkv12 avatar Jan 17 '20 06:01 arshidkv12

I'm facing the same issue with Codeigniter. Encrypting any file with the namespace at the top seems to break the scripts. I already sent a message on the webpage but I did not have an answer there.

joseques avatar Jul 29 '20 12:07 joseques

@joseques the author don't care about this issue. I contacted him and he told me that he will help me only if I pay for that, so I decided to pay for ionCube despite it's more expensive, because If I pay, I want to get a finished and tested product.

allanvb avatar Jul 29 '20 13:07 allanvb

@joseques the author don't care about this issue. I contacted him and he told me that he will help me only if I pay for that, so I decided to pay for ionCube despite it's more expensive, because If I pay, I want to get a finished and tested product.

ioncube is a fool, because I suspect someone working on ioncube created a decode service https://easytoyou.eu/

This service is always up to date about 5-7 months after Ioncube releases the latest version, where all the code that we have encrypted will be able to decrypt using the service.

Then a few months after https://easytoyou.eu/ released the latest version, then 3-5 months later ioncube released the latest version again.

We have to pay again to get the latest version of ioncube so that the code that we encrypt cannot be decrypted.

However, as I mentioned, that after 5-7 months ioncube releases the latest version, then https://easytoyou.eu/ will follow it to release the latest version too.

Then again as I mentioned that after https://easytoyou.eu/ releases the latest version, ioncube will release the latest version after 3-5 months of decoded, and we have to pay again to get the latest version.

f * ck ioncube.

sir-reynolds avatar May 06 '21 18:05 sir-reynolds

Does anyone have the solution?

brunoromeo001 avatar Nov 23 '21 07:11 brunoromeo001

Dose anyone have the solution for this issue?

dipakkolhe avatar Jan 11 '22 09:01 dipakkolhe

does have solution?

mrmuminov avatar Jul 16 '22 17:07 mrmuminov

Hey guys, the solution for me was to download directly from this repository and not from the website. Hope this helps.

brunoromeo001 avatar Jul 16 '22 20:07 brunoromeo001

Downloaded the encryption script from this repo, now the problem is another: "Parse error: syntax error, unexpected ':', expecting end of file"

Downloading from the website, using php 7.4 TS dll, i got the same error (namespace declaration...)

andreescocard avatar Aug 18 '22 01:08 andreescocard

Hello,

I am facing one issue, in my file I have namespace, and after encryption with bolt, having line on top. bolt_decrypt( FILE , PHP_BOLT_KEY); return 0;

and later have encrypted code.

so when I am running file, getting compile error.

Description:Namespace declaration statement has to be the very first statement or after any declare call in the script Backtrace-------------------

So problem is that after encryption we are adding bolt_decrypt, and that is creating problem, if having namespace in file. Can you please suggest anything or any solution for this.

Regards,

hi have you found the solution for this?

leehong0115 avatar Apr 12 '23 04:04 leehong0115

delete string "<?php" ,the bolt_encrypt will add "<?php auto"

$fileContents = File::get(base_path($filePath)); $prepend = "<?php bolt_decrypt( FILE , '$key'); return 0; ##!!!##"; $pattern = '/<?php/m'; preg_match($pattern, $fileContents, $matches); if (!empty($matches[0])) { $fileContents = preg_replace($pattern, '', $fileContents); } $cipher = bolt_encrypt($fileContents, $key);

shjy avatar Dec 28 '23 09:12 shjy

The problem is actually this line:

$cipher = bolt_encrypt( "?> ".$contents, $php_blot_key );

The space after ?> is the culprit.

Change the line to:

$cipher = bolt_encrypt( "?>".$contents, $php_blot_key );

and everything should work.

alesf avatar Jan 25 '24 13:01 alesf