[prev in list] [next in list] [prev in thread] [next in thread]
List: klik-devel
Subject: [klik-devel] glibc hack to support FAKECHROOT_BASE
From: Lionel Tricon <lionel.tricon () free ! fr>
Date: 2008-03-21 22:07:20
Message-ID: 200803212307.21123.lionel.tricon () free ! fr
[Download RAW message or body]
Ok list,
Here we are. As described previously, i am trying a new approach to improve
the klik2 model. Since one of the most annoying problem is the
LD_LIBRARY_PATH restriction, i got the idea to change dynamically the loader
to point a modified one which is aware of our jail approach.
The current situation is that i was able to modify ld.so to support the
FAKECHROOT_BASE variable. All seems working great even if i suspect that all
is not perfect (i'm not a glibc hacker indeed). But, well, it seems working
enough to allow me to to run acroread without any modifications and even with
the original script.
To reach that, i have added an option to fusioniso to change on the fly the
loader into each elf binaries (just by rewriting path into the binary, simple
but efficient) through the -g option.
All you have to do to test that is to connect /lib/ld-klik2.so.2
to /opt/klik/lib/glibc/ld-2.5.so in case your distro embed glibc-2.5 (for
others, oi need to compile them).
Do the same with /lib/ld-lsk.so.1 to /opt/klik/lib/glibc/ld-2.5.so (and the
same for .2 and for .3) : acroread is an lsb 3 binary.
And obviously to patch fuse.py and execute.py as below :
fuse.py
command = [fusioniso, "-n", "-g"]
execute.py
os.environ["LD_LIBRARY_PATH"] = "/usr/lib:/lib:/opt/kde3/lib:/usr/X11R6/lib/"
and
os.environ["LD_LIBRARY_PATH"] = os.environ["LD_LIBRARY_PATH"] + ":" + dir[1:]
For those who have OpenSuse10.2, RHEL5 or kubuntu 7.04, you can test it now.
For others, works is in progress (hopefuly, the loader is a part of glibc
which is quite unmodified, i just have to patch and recompile).
Hope this approach is the good one.
Don't hesitate to tell me if something behave worse is this version.
Lionel
_______________________________________________
klik-devel mailing list
klik-devel@kde.org
https://mail.kde.org/mailman/listinfo/klik-devel
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic