Security impact of access modifiers (public, private, internal, protected)
问题 Do the access modifiers of classes , properties or methods in C#, Java and other programming languages actually have an impact on the security of an application? Do they also protect against unauthorized access in some way? Or are they just a tool for clear and propper programming? 回答1: No, access modifiers don't offer security protection. They are merely there for developer convenience, e.g. they help to enforce good coding practices and help with programming patterns. It's easy to access