cbSecurity
CommunitySlackSupport
v1.x
v1.x
  • Introduction
  • Overview
  • How It Works
  • Declaring the Interceptor
    • XML Properties
    • JSON Properties
    • DB Properties
    • IOC Properties
    • OCM Properties
  • Security Rules
    • Sample JSON Rules
    • Sample XML Rules
  • _securedURL key
  • Default Security
  • Custom Security Validator Object
Powered by GitBook
On this page

Was this helpful?

Edit on Git
Export as PDF
  1. Declaring the Interceptor

DB Properties

The following are properties used when the source of the rules is db or coming from the database.

Property

Type

Required

Default

Description

rulesDSN

string

true if rulesSource = db

---

The dsn to use if the rules are coming from a database

rulesTable

string

true if rulesSource = db

---

The table where the rules are

rulesSQL

string

false

select* from rulesTable

The custom SQL statement to use to retrieve the rules according to the rulesTable property. If not set, the default of select* from rulesTable will be used.

rulesOrderBy

string

false

---

The column to order the rules by. If not chosen, the interceptor will not order the query, just select it.

interceptors = [
    {class="cbsecurity.interceptors.Security", name="ApplicationSecurity", properties={
        useRegex = true, rulesSource = "db", validatorModel = "SecurityService",
        rulesDSN = "myApp", rulesTable = "securityRules", rulesOrderBy = "order asc"
    }}
];
PreviousJSON PropertiesNextIOC Properties

Last updated 6 years ago

Was this helpful?