[GHC] #11490: check architecture before attempting to load object files

#11490: check architecture before attempting to load object files -------------------------------------+------------------------------------- Reporter: rwbarton | Owner: Type: bug | Status: new Priority: low | Milestone: Component: Runtime | Version: 8.0.1-rc1 System (Linker) | Keywords: | Operating System: Unknown/Multiple Architecture: | Type of failure: Other Unknown/Multiple | Test Case: | Blocked By: Blocking: | Related Tickets: Differential Rev(s): | Wiki Page: -------------------------------------+------------------------------------- If a user somehow manages to trick ghci into loading a `.o` file for the wrong architecture (e.g. arm vs x86), the runtime linker doesn't notice and tries to load it anyway. That is likely to result in a confusing error or crash. `ocVerifyImage_ELF` does already check the "ELF class", which amounts to 32-bit vs 64-bit. It should also check the architecture and, I think, endianness to make sure they are compatible with the running process. -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11490 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler

#11490: check architecture before attempting to load object files -------------------------------------+------------------------------------- Reporter: rwbarton | Owner: Type: bug | Status: new Priority: low | Milestone: Component: Runtime System | Version: 8.0.1-rc1 (Linker) | Resolution: | Keywords: Operating System: Unknown/Multiple | Architecture: | Unknown/Multiple Type of failure: Other | Test Case: Blocked By: | Blocking: Related Tickets: | Differential Rev(s): Wiki Page: | -------------------------------------+------------------------------------- Comment (by ezyang): Related: #7790 -- Ticket URL: http://ghc.haskell.org/trac/ghc/ticket/11490#comment:1 GHC http://www.haskell.org/ghc/ The Glasgow Haskell Compiler
participants (1)
-
GHC