Dmytro Rudiy
Dmytro Rudiy

Reputation: 1

Laravel controller encoded with ioncube trigger segfault error

I have laravel application with code encoded by ioncube 13 php 8.1 :

namespace App\Http\Controllers;

use Illuminate\Http\Request;

class TestController extends Controller
{
     public function index(Request $request) {
        return view('welcome');
    }
}

In syslog I see segfault error:

localhost kernel: [167784.697796] php-fpm8.1[47572]: segfault at b343 ip 000055c3e7daa67c sp 00007ffe99912178 error 4 in php-fpm8.1[55c3e7cc8000+310000] likely on CPU 1 (core 0, socket 0)

with php 8.2 the same result

If I change code to:

namespace App\Http\Controllers;

use Illuminate\Http\Request;

class TestController extends Controller
{
     public function index() {
        return view('welcome');
    }
}

it works

Why param Request $request trigger error ? Do somebody faced this problem with ioncube and how sole it?

With php 7.4 I did not see this problem, only with ioncube with php8+

Upvotes: 0

Views: 382

Answers (1)

Saeed Azimi
Saeed Azimi

Reputation: 1

I had the exact same problem and the problem was solved with this solution.

You can do this to solve this problem in laravel 9, php 8.1 and ioncube 13

Encrypt these folders togeter: app config route vendor

Put all of them in one folder and encrypt it at once.

Because there are many vendor files, it slows down the speed when everything is encrypted, you can encrypt only the Laravel folder from within the vendor.

or just encrypt only the laravel folder from vendor folder

app, config, route, laravel

Upvotes: 0

Related Questions