All Products
Search
Document Center

Security Center:GetFileProtectClientRule

Last Updated:Jun 12, 2026

Retrieves the details of a file protection rule.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

Id

integer

No

The policy ID.

123

Response elements

Element

Type

Description

Example

object

Schema of Response

RequestId

string

Id of the request

79CFF74D-E967-5407-8A78-EE03B925****

Data

object

The returned data.

RuleAction

string

The action that the rule takes on the client. Valid values:

  • monitor: alert

  • block: block

  • pass: allow.

pass

RuleName

string

The rule name.

test

SwitchId

string

The switch ID that corresponds to the rule.

USER-CONTAINER-RULE-SWITCH-TYPE_***

Id

integer

The rule ID.

3119

AlertLevel

integer

The alert notification level. Valid values:

  • 0: no alert

  • 1: reminder

  • 2: suspicious

  • 3: high-risk.

1

FileOps

array

The operations performed on files.

string

The operations performed on files. Valid values:

  1. WRITE: write

  2. READ: read

  3. DELETE: delete

  4. RENAME: rename

  5. CHMOD: modify permissions.

WRITE

FileTypes

array

The protected file types.

string

The protected file types.

txt

FilePaths

array

The monitored file paths. Wildcards are supported.

string

The monitored file paths. Wildcards are supported.

/usr/*

ProcPaths

array

The process paths. Wildcards are supported.

string

The process paths. Wildcards are supported.

/usr/local/*

ExcludeUsers

array

The list of excluded users.

string

The list of excluded users.

root

Status

integer

The rule status. Valid values:

  • 0: disabled.

  • 1: enabled.

0

Platform

string

The operating system type. Valid values:

  • windows: Windows

  • linux: Linux.

linux

Examples

Success response

JSON format

{
  "RequestId": "79CFF74D-E967-5407-8A78-EE03B925****",
  "Data": {
    "RuleAction": "pass",
    "RuleName": "test",
    "SwitchId": "USER-CONTAINER-RULE-SWITCH-TYPE_***",
    "Id": 3119,
    "AlertLevel": 1,
    "FileOps": [
      "WRITE"
    ],
    "FileTypes": [
      "txt"
    ],
    "FilePaths": [
      "/usr/*"
    ],
    "ProcPaths": [
      "/usr/local/*"
    ],
    "ExcludeUsers": [
      "root"
    ],
    "Status": 0,
    "Platform": "linux"
  }
}

Error codes

HTTP status code

Error code

Error message

Description

400 IllegalParameter Illegal parameter, please check the param. Parameter error, please check the input parameters.
500 ServerError ServerError
403 NoPermission caller has no permission You are not authorized to do this operation.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.