maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   SailfishOS (https://talk.maemo.org/forumdisplay.php?f=52)
-   -   [BETA] prepatch a system-wide patching system (alternative to patchmanager) (https://talk.maemo.org/showthread.php?t=100243)

jakibaki 2018-03-12 20:14

Re: [WIP] prepatch a system-wide patching system (alternative to patchmanager)
 
Quote:

Originally Posted by cy8aer (Post 1542294)
I tried the packaged version and rebooted. But I had some difficulties:

1st try: Unlocking froze the device
2nd try: After shutdown and start I was able to unlock but then lipstick was veeery slow (waiting circle on startup). I had a frozen screen when swiping but it came back.

Then I uninstalled both packages (prepatcher and the keyboard patch) and rebooted and every went smooth again.

JollaC 2.1.4.14

Hmm :( I only tried it on my xperia x which is a good deal more powerful then your device.

Could you please try again and this time just let the phone sit for a few minutes after rebooting? I also have the circle-issue but after it goes away (20 seconds for me) everything goes smoothly.

I know this is not a permanent solution but I want to narrow down the issue.

I also released a new version which should fix a few memory-leaks but unfortunately doesn't completely fix the loading-bug so that may help.

Amboss 2018-03-12 21:11

Re: [WIP] prepatch a system-wide patching system (alternative to patchmanager)
 
Quote:

Originally Posted by tortoisedoc (Post 1542273)
Hello? Security? Am I the only one worried here? :(

I think I know where you're heading.

Patchmanager modifies files which I can check afterwards to be in place and doing what its was meant for. Checking can happen even in an environment like recovery shell.

Prepatch is injected in file system calls. You say yourself "be sure turn of this patch or that" to actually copy the correct file. So if you want to be sure, a patch does not contain malicious parts, you have to check that either before installing or has to happen in recovery shell were the prepatch is not loaded. Otherwise you can't be sure while prepatch is active. Because if someone wants to add malicious code, he just needs to also cover any file requests regarding his files with something innocent using the same architecture.

jakibaki 2018-03-12 21:52

Re: [WIP] prepatch a system-wide patching system (alternative to patchmanager)
 
Quote:

Originally Posted by Amboss (Post 1542304)
I think I know where you're heading.

Patchmanager modifies files which I can check afterwards to be in place and doing what its was meant for. Checking can happen even in an environment like recovery shell.

Prepatch is injected in file system calls. You say yourself "be sure turn of this patch or that" to actually copy the correct file. So if you want to be sure, a patch does not contain malicious parts, you have to check that either before installing or has to happen in recovery shell were the prepatch is not loaded. Otherwise you can't be sure while prepatch is active. Because if someone wants to add malicious code, he just needs to also cover any file requests regarding his files with something innocent using the same architecture.

I see your point and it's a very valid concern but isn't that the case with essentially everything you install from an untrused source?

Any rpm you install could also setup a rootkit on your device while it's installing which makes sure that you can't notice it unless you're in recovery even without prepatch.

I don't see any way to prevent rpms from doing evil things (as they're being installed with a tool that I don't have any control over) but that's the same way with the original patchmanager.

If I ever add something like the pm2-webstore I'll make sure that users have to explicitly enable the patches after installing them so that they can check out the content but for now I don't see the point in creating something that would be trivial to bypass in the rpm postininstall script.

Ancelad 2018-03-13 09:08

Re: [EARLY BETA] prepatch a system-wide patching system (alternative to patchmanager)
 
Well, it works on my Inoi R7, the first lipstick start after installation was about 30-35 seconds, but it works as fast as usual.

jakibaki 2018-03-13 10:18

Re: [EARLY BETA] prepatch a system-wide patching system (alternative to patchmanager)
 
I fixed the loading-screen-bug! Prepatch should now be usable on older devices too!

clovis86 2018-03-13 10:42

Re: [EARLY BETA] prepatch a system-wide patching system (alternative to patchmanager)
 
I'm facin issue after installing prepatch, can't launch anymore the dialer.
App is loading and then is closing itself.
Tryed restarting lipstick and rebooting Xperia without any impact.
Removing prepatch and restarting give me the dialer back.

Maybe some parts from "old" patchmanager are still there and causing this issue ?
Do you want me to fill a bug on github ?

jakibaki 2018-03-13 11:08

Re: [EARLY BETA] prepatch a system-wide patching system (alternative to patchmanager)
 
Quote:

Originally Posted by clovis86 (Post 1542323)
I'm facin issue after installing prepatch, can't launch anymore the dialer.
App is loading and then is closing itself.
Tryed restarting lipstick and rebooting Xperia without any impact.
Removing prepatch and restarting give me the dialer back.

Maybe some parts from "old" patchmanager are still there and causing this issue ?
Do you want me to fill a bug on github ?

That's very weird. The dialer works perfectly for me.

Please make sure that you're running the newest version (I released an update a few minutes ago).

If the issue persists could you please open an issue on github with the output of running
Code:

voicecall-ui
from ssh. (I don't want to clutter this thread with the back and forth of trying to debug this)

clovis86 2018-03-13 11:21

Re: [EARLY BETA] prepatch a system-wide patching system (alternative to patchmanager)
 
Just reinstalled your new 0.2 version and issue is fixed, yay ! :D

cy8aer 2018-03-13 14:10

Re: [WIP] prepatch a system-wide patching system (alternative to patchmanager)
 
Quote:

Originally Posted by jakibaki (Post 1542295)
Hmm :( I only tried it on my xperia x which is a good deal more powerful then your device.

So what? I do not buy any electronic crap every year. And it does not matter how fast it is...

cy8aer 2018-03-13 14:15

Re: [BETA] prepatch a system-wide patching system (alternative to patchmanager)
 
Ok, the new version of prepatcher seems to work. Thank you.

Just a lesson: Never test on the fastest machine you can buy. Test it on the slowest oldest. If there will be some hardware bug some time and your processors get 30% slower all of your hardware - old and new - will still perform.


All times are GMT. The time now is 07:51.

vBulletin® Version 3.8.8