LWN.net Logo

Remote root hole in Samba

Remote root hole in Samba

Posted Apr 11, 2012 23:59 UTC (Wed) by Cyberax (✭ supporter ✭, #52523)
In reply to: Remote root hole in Samba by khim
Parent article: Remote root hole in Samba

Sure. You need mandatory GC and range checks. If your language has them then it can be made safe.


(Log in to post comments)

Remote root hole in Samba

Posted Apr 12, 2012 13:57 UTC (Thu) by cesarb (subscriber, #6266) [Link]

> Sure. You need mandatory GC and range checks. If your language has them then it can be made safe.

Why do you need GC to make a safe language?

Remote root hole in Samba

Posted Apr 12, 2012 14:41 UTC (Thu) by khim (subscriber, #9252) [Link]

You don't need GC. The things which you can not include are free(3) and realloc(3): without tracing pointers you can not say if it's safe to decallocate memory or not if you trace pointers anyway then why will you need free(3) or realloc(3)?

Usually the safe alternative is some kind of GC (refcounting GC works fine and often presents the best practical compromise), but other schemes are possible (for example you can allocate memory statically or use arenas which can be freed in safe way).

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds