I am reading materials of intel's IA-32 Intel Architecture Software Developers Manual
In Volume 1:Basic Architecture->18.104.22.168. RETURN INSTRUCTION POINTER ,it is described:
"The processor does not require that the return instruction pointer point back to the calling procedure.Prior to executing the RET instruction, the return instruction pointer can be manipulated in software to point to any address in the current code segment (near return) or another code segment (far return). Performing such an operation, however, should be undertaken very cautiously, using only well defined code entry points."
Is there any circumstance that any software manipulate the return instruction pointer?At least I have never met such case except overflow which is used by hacker.
So,since there are mechanism of page protect,segment protect,Why stack protect mechanism dosen't exist?
And without this machanism,the overflow will happen and will result in great damage as RPC worm did.To prevent this case,the programmer need to do lot of work to check the argument,or the new compiler insert lot of rubbish code to the executable files.
We all knowoverflow happend just becausethat thebasic architecture of the chips are designedonNeumann's theroy.I do not investigate in the theroy.Is it unchangeble?
I am a programmer,and I do not familiar with hardware design.So it is just a free talk.
Message Edited by pll on 04-29-2004 11:31 PM