Date: Mon, 17 Feb 2025 11:02:26 +0100
Amit, this has nothing to do with security. C doesn't have
private/public either and it's not less secure because of that.
Any bit of code that runs in the address space of your process is able
to overwrite any memory that's not write-protected. At an assembly
level, private doesn't offer any protection whatsoever; it's just a
"no touchy" high-level way to prevent developers from accessing things
they shouldn't, mainly to avoid bugs.
private/public either and it's not less secure because of that.
Any bit of code that runs in the address space of your process is able
to overwrite any memory that's not write-protected. At an assembly
level, private doesn't offer any protection whatsoever; it's just a
"no touchy" high-level way to prevent developers from accessing things
they shouldn't, mainly to avoid bugs.
Received on 2025-02-17 10:02:39