"""Optimizer for Security"""

class OptimizerSecurity:
    def __init__(self, security_level=1):
        self.security_level = max(1, min(security_level, 3))
        self.enabled_features = {
            'data_encryption': True,
            'network_protection': True,
            'access_control': False,
            'audit_logs': False
        }
        self.set_security_policies()

    def set_security_policies(self):
        if self.security_level == 1:
            self.enabled_features['network_protection'] = False
            self.enabled_features['access_control'] = False
            self.enabled_features['audit_logs'] = True
        elif self.security_level == 2:
            self.enabled_features['data_encryption