[BUGS] Looking for plugins (Linux)
Tim Rowledge
tim at sumeru.stanford.edu
Fri Dec 28 23:10:03 UTC 2001
Joshua 'Schwa' Gargus wrote:
>
> It seems to me that looking for a loadable module in the same
> directory that the VM exists in is a very sensible behavior. For some
> reason, the Linux VM does not do this.
According to the code in
platforms/unix/vm/sqUnixExternalPrims.c>ioLoadModule(), it looks in
current dir, /etc/ld.so.cache, /usr/lib, /lib, SQ_LIBDIR, so it really
should be working for you. I usually end up with the plugins in the same
directory as the cwd. Surely it also ought to look in the same directory
as the vm, and maybe in a suitable subdir of that.
> There seems to be no security
> reason for this; if a terrorist could put bad plugins in the VM
> directory, said terrorist could also replace the VM with their own.
Probably true :-) Note that it would be possible to override a vm with
all internal plugins and security turned on simply by putting
non-secured external plugins in any one of those directories.
>
> On a related note, "Smalltalk vmPath" incorrectly answers the
> directory that the image resides in.
So it does. And it does it with deliberate care - see
platforms/unix/vm/sqXWindow.c>RecordFullPathForImageName(). Looks like a
fix is needed from someone that understands how to get path info for the excutable.
tim
More information about the Squeak-dev
mailing list
|