[Issue 11171] Text relocations in Phobos shared library

2019-12-11 Thread d-bugmail--- via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=11171

berni44  changed:

   What|Removed |Added

 CC||bugzi...@d-ecke.de
  Component|phobos  |dmd

--


[Issue 11171] Text relocations in Phobos shared library

2016-02-19 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=11171

--- Comment #11 from Martin Krejcirik  ---
Can this be closed ? I think it't fixed since 2.067.

--


[Issue 11171] Text relocations in Phobos shared library

2014-04-22 Thread via Digitalmars-d-bugs
https://issues.dlang.org/show_bug.cgi?id=11171

--- Comment #10 from Martin Nowak c...@dawg.eu ---
This is fixed for x86_64, but there are still text relocations on x86_32.
The bug is also related to making ModuleInfo const, see bug 11543.

--


[Issue 11171] Text relocations in Phobos shared library

2014-02-09 Thread d-bugmail
https://d.puremagic.com/issues/show_bug.cgi?id=11171



--- Comment #9 from github-bugzi...@puremagic.com 2014-02-09 17:51:47 PST ---
Commits pushed to master at https://github.com/D-Programming-Language/dmd

https://github.com/D-Programming-Language/dmd/commit/1a99b8b6fea24094d483251cf7c8f2d4206813aa
fix Issue 11171 - text relocations in shared phobos library

- Read-only data with relocations cannot be added to CDATA,
  because text relocations are prohibited by many security
  checks (SELinux).
  Also text relocations effectively break sharing of
  read-only segments across multiple processes.

https://github.com/D-Programming-Language/dmd/commit/70653611a580867c232eb451b17a0f73d72e0b62
Merge pull request #3187 from MartinNowak/fix11171

[dll] fix Issue 11171 – Text relocations in Phobos shared library

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 11171] Text relocations in Phobos shared library

2014-02-01 Thread d-bugmail
https://d.puremagic.com/issues/show_bug.cgi?id=11171


Martin Nowak c...@dawg.eu changed:

   What|Removed |Added

   Keywords||dll
   Priority|P2  |P3
 CC||c...@dawg.eu
 AssignedTo|nob...@puremagic.com|c...@dawg.eu


--- Comment #6 from Martin Nowak c...@dawg.eu 2014-02-01 11:03:45 PST ---
Indeed it's a problem that block SELinux out of the box.
I stumbled over this today trying to run a binary with sandbox.
In elfutils there is a small tool to find those relocations
eu-findtextrel
https://fedoraproject.org/wiki/User:Tibbs/Text_Relocation_Guidelines

Seems like it mostly barks about vtblZ and initZ symbols in libphobos2.so.
Those indeed need to contain absolute relocations but they should be data
symbols, so I don't yet know what the problem is.

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 11171] Text relocations in Phobos shared library

2014-02-01 Thread d-bugmail
https://d.puremagic.com/issues/show_bug.cgi?id=11171



--- Comment #7 from Martin Nowak c...@dawg.eu 2014-02-01 16:09:08 PST ---
One cause of this bug is that the .minfo* sections are marked as read-only but
require dynamic relocations.
I think we should avoid the relocation and write the complete ModuleInfo into
the .minfo sections, currently .minfo holds pointers to ModuleInfos.

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 11171] Text relocations in Phobos shared library

2014-02-01 Thread d-bugmail
https://d.puremagic.com/issues/show_bug.cgi?id=11171



--- Comment #8 from Martin Nowak c...@dawg.eu 2014-02-01 23:28:41 PST ---
There are more false read-only symbols, most notably initZ, vtblZ and deh_eh.
We're supposed to put those into data.rel.ro sections when compiling -fPIC
code.
http://www.airs.com/blog/archives/189
http://stackoverflow.com/questions/7029734/what-is-the-data-rel-ro-used-for
http://refspecs.linux-foundation.org/LSB_4.0.0/LSB-Core-generic/LSB-Core-generic/specialsections.html

-- 
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 11171] Text relocations in Phobos shared library

2013-10-31 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=11171


Martin Krejcirik m...@krej.cz changed:

   What|Removed |Added

 CC||m...@krej.cz


--- Comment #2 from Martin Krejcirik m...@krej.cz 2013-10-31 22:43:50 CET ---
Just noticed this too. It makes shared libraries unusable on hardened system
(like grsecurity).

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 11171] Text relocations in Phobos shared library

2013-10-31 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=11171



--- Comment #4 from Martin Krejcirik m...@krej.cz 2013-10-31 23:07:52 CET ---
(In reply to comment #3)
 Duplicate of #5278?

Likely, but it's not just Gentoo. I use Grsecurity kernel on Debian and get
this error:

./prog: error while loading shared libraries:
/usr/local/lib/libphobos2.so.0.64: cannot make segment writable for relocation:
Permission denied

The only solution is to disable MPROTECT for given exacutable.
http://pax.grsecurity.net/docs/mprotect.txt

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 11171] Text relocations in Phobos shared library

2013-10-31 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=11171


safety0ff.bugz safety0ff.b...@gmail.com changed:

   What|Removed |Added

 CC||safety0ff.b...@gmail.com


--- Comment #3 from safety0ff.bugz safety0ff.b...@gmail.com 2013-10-31 
14:55:11 PDT ---
Duplicate of #5278?

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 11171] Text relocations in Phobos shared library

2013-10-31 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=11171



--- Comment #5 from safety0ff.bugz safety0ff.b...@gmail.com 2013-10-31 
15:10:09 PDT ---
(In reply to comment #4)
 (In reply to comment #3)
  Duplicate of #5278?
 
 Likely, but it's not just Gentoo.
I'm aware, it should probably be renamed.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---


[Issue 11171] Text relocations in Phobos shared library

2013-10-04 Thread d-bugmail
http://d.puremagic.com/issues/show_bug.cgi?id=11171



--- Comment #1 from Dicebot pub...@dicebot.lv 2013-10-04 04:14:41 PDT ---
P.S. version of shared library in question is
https://www.archlinux.org/packages/community/x86_64/libphobos/ , it can be
installed at any point by standard package manager (pacman)

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
--- You are receiving this mail because: ---