[GHC] #12657: GHC and GHCi: RWX mmap denied by GrSec, results in a segfault

GHC ghc-devs at haskell.org
Wed Oct 5 12:49:06 UTC 2016


#12657: GHC and GHCi: RWX mmap denied by GrSec, results in a segfault
-------------------------------------+-------------------------------------
        Reporter:  PoroCYon          |                Owner:
            Type:  bug               |               Status:  new
        Priority:  normal            |            Milestone:
       Component:  Runtime System    |              Version:  8.0.1
      Resolution:                    |             Keywords:  grsec, pax,
                                     |  mmap, rts
Operating System:  Linux             |         Architecture:  x86_64
                                     |  (amd64)
 Type of failure:  Runtime crash     |            Test Case:
      Blocked By:                    |             Blocking:
 Related Tickets:                    |  Differential Rev(s):
       Wiki Page:                    |
-------------------------------------+-------------------------------------

Comment (by simonmar):

 The linker should mmap RW during linking and them remap RX when linking is
 complete.  I think the new m32 allocator will make things a more difficult
 though, because it maintains partial pages of linked code, and we can't
 remap one of those pages from RX to RW since it might already be in use.

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/12657#comment:6>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list