package com.erp.audit.service;

import com.erp.audit.entity.SensitiveOperationRule;
import java.util.List;

/**
 * 敏感操作服务接口
 */
public interface SensitiveOperationService {

    /**
     * 查询所有启用的规则
     */
    List<SensitiveOperationRule> getEnabledRules();

    /**
     * 创建/更新规则
     */
    SensitiveOperationRule saveRule(SensitiveOperationRule rule);

    /**
     * 删除规则
     */
    void deleteRule(Long id);

    /**
     * 检查是否匹配敏感操作规则
     */
    SensitiveOperationRule matchRule(String url, String operationType, String module);

    /**
     * 触发告警
     */
    void triggerAlert(Long auditLogId, SensitiveOperationRule rule);
}
