NX bit emulation

Discussions on more advanced topics such as monolithic vs micro-kernels, transactional memory models, and paging vs segmentation should go here. Use this forum to expand and improve the wiki!
Post Reply
mrn
Posts: 4
Joined: Sat Jan 15, 2011 11:56 am

NX bit emulation

Post by mrn »

Hi,
Could someone explain to me how the NX bit can be emulated on platforms such as 32-bit x86 where the hardware doesn't provide it? I would be greatful for an explanation of the basics of the way it is emulated since I simply can't imagine how it could be realized. Thanks in advance.
User avatar
Brynet-Inc
Member
Member
Posts: 2426
Joined: Tue Oct 17, 2006 9:29 pm
Libera.chat IRC: brynet
Location: Canada
Contact:

Re: NX bit emulation

Post by Brynet-Inc »

It's possible to use segmentation to achieve a similar effect, as a sort of line in the sand.. executable area up until some point and then non-executable data.

I believe that's how a lot of x86 OS's are implementing it these days, at least OpenBSD and Linux.
Image
Twitter: @canadianbryan. Award by smcerm, I stole it. Original was larger.
mrn
Posts: 4
Joined: Sat Jan 15, 2011 11:56 am

Re: NX bit emulation

Post by mrn »

Thanks for the reply. I guess you were right it can be done using segmentation. Following links on http://stackoverflow.com/questions/4703 ... -emulation I found out NX emulation can as well be done using TLB.
Post Reply