Not logged in
Log in now
Create an account
Subscribe to LWN
LWN.net Weekly Edition for December 5, 2013
Deadline scheduling: coming soon?
LWN.net Weekly Edition for November 27, 2013
ACPI for ARM?
LWN.net Weekly Edition for November 21, 2013
An unexpected perf feature
Posted May 23, 2013 12:32 UTC (Thu) by renox (subscriber, #23785)
Posted May 23, 2013 12:46 UTC (Thu) by Cyberax (✭ supporter ✭, #52523)
And yes, it's totally possible to create a language (hint: Java, C#) that do NOT require hardware memory protection at all to isolate misbehaving applications.
Posted May 27, 2013 17:13 UTC (Mon) by dgm (subscriber, #49227)
Anywhere it was not intended to be, but mostly strings, specially strings that are interpreted by the program.
> And yes, it's totally possible to create a language (hint: Java, C#) that do NOT require hardware memory protection at all to isolate misbehaving applications.
It's not the language but the virtual _machine_ they run on what isolates misbehaving applications.
Posted May 27, 2013 23:51 UTC (Mon) by Cyberax (✭ supporter ✭, #52523)
> It's not the language but the virtual _machine_ they run on what isolates misbehaving applications.
Nope. If your language allows unrestricted pointer arithmetic then it doesn't matter at all if you are running it inside the most secure VM.
And if your language simply doesn't have a way to express pointer arithmetic then you can't use it to do memory damage.
Posted May 28, 2013 8:59 UTC (Tue) by etienne (subscriber, #25256)
IHMO you can't use that language to manage the memory neither, i.e. you can't write malloc()/free() nor what the kernel needs, for instance "allocate a contiguous DMA able buffer accessible with DMA32 PCI card and fail if a wait is needed and give back it's physical address" or "free memory blocks after DMA hardware has finished sending them", or any variation of it.
Obviously if you had perfect hardware and a processor with an "allocate_memory" and a "free_memory_after_both_software_and_DMA_have_finished_with_it" assembly instruction, then maybe...
Posted May 28, 2013 9:06 UTC (Tue) by Cyberax (✭ supporter ✭, #52523)
You also certainly can allocate buffers with special properties, and you can even do stuff like reading from within buffers by using fat pointers (i.e. a pointer with a length).
In fact, it's all been done in the past even for OS kernels. It's the question of practicality, not possibility.
Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds