OSDev.org

The Place to Start for Operating System Developers
It is currently Thu Apr 25, 2024 6:10 am

All times are UTC - 6 hours




Post new topic Reply to topic  [ 3 posts ] 
Author Message
 Post subject: "unreal" mode - possible protection
PostPosted: Sat Jul 07, 2001 11:00 pm 
I'm currently writing a pmode OS, but I've read
a lot about unreal mode recently and it's peaked
my interest.

I'm guessing that once unreal mode has been
initialized, loading another segment register will
cause it to fail... therefore making it rather
unsecure for a real operating system, but
interesting to play around with. Correct?

This would mean using the BIOS is out, correct?

Would it be possible, however, to define a
segment from 0 - 0xfffffff and one from, say,
0x0001000 - 0xffffffff and switch between them?
Or will _any_ changing of the current segment
cause unreal mode to fault?

Thanks,
j.weeks


Top
  
 
 Post subject: RE:"unreal" mode - possible protection
PostPosted: Mon Jul 09, 2001 11:00 pm 
>On 2001-07-08 22:35:30, J. Weeks wrote:

>Would it be possible, however, to define a
>segment from 0 - 0xfffffff and one from, say,
>0x0001000 - 0xffffffff and switch between them?
>Or will _any_ changing of the current segment
>cause unreal mode to fault?

From what I've read, any change to the segment
regs during real mode causes things like length to
be reloaded with correct values for real mode.

You could have two regs pointing to different areas and just
switch between them but I not really sure about copying from one
to another. My guees would be no though...

-Chase


Top
  
 
 Post subject: RE:"unreal" mode - possible protection
PostPosted: Mon Jul 09, 2001 11:00 pm 
>I'm guessing that once unreal mode has been
>initialized, loading another segment register will
>cause it to fail...

Reloading a segment register after returning
to real mode changes the segment base address
only (0 - FFFF0h). It doesn't change the segment limit.

>This would mean using the BIOS is out, correct?

You can still use the BIOS after enabling unreal mode.

>Would it be possible, however, to define a
>segment from 0 - 0xfffffff and one from, say,
>0x0001000 - 0xffffffff and switch between them?

Sure.

I've read that you should not enable unreal mode for the CS and SS registers, though.


Top
  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 3 posts ] 

All times are UTC - 6 hours


Who is online

Users browsing this forum: Google [Bot], Majestic-12 [Bot] and 243 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group