Access control lists (ACLs)

Một phần của tài liệu Đồ án tin học nghiên cứu về giao thức LDAP (Trang 25)

Directory ACLs cung cấp bởi OpenLDAP khá đơn giản trong cú pháp nhưng lại cực kỳ linh hoạt và mạnh mẽ trong thực thi. Ý tưởng cơ bản là xác định Who has Access to What ? “Who” bao gồm :

*

self Chỉ mình DN root anonymous Nonauthenticated user users Authenticated user Regular expression

Matches a DN or an SASL identity

Còn về việc Access được chia thành các cấp độ khác nhau như sau :

Table 3-7. Summary of access levels from most (top) to least (bottom)

Access

level Permission granted

write Access to update attribute values (e.g., Change this telephoneNumber to 555-2345).

read Access to read search results (e.g., Show me all the entries with a telephoneNumber of 555*). search Access to apply search filters (e.g., Are there any entries with a telephoneNumber of 555*). compare Access to compare attributes (e.g., Is your telephoneNumber 555-1234?).

auth Access to bind (authenticate). This requires that the client send a username in the form of a DN and some type of credentials to prove his or her identity.

none No access.

Cách đơn giản nhất để điều khiển access là tạo các cấp độ mặc định, chuyện này được điều khiển bởi tham số defaultaccess trong slapd.conf , ví dụ:

## Give users search access when no other ACL applies. defaultaccess search

Cuối cùng “What” xác định các entry và atributes để áp dụng ACL. Nó được chia làm 3 phần không bắt buộc :

• Phần được DN xác định cho ACL.

• Phần LDAP tìm kiếm và lọc

• Phần dành riêng cho các attributes

Nếu không có cả 3 phần, nó sẽ được thay thế bởi 1 dấu *, tức là bao gồm tất cả. Ví dụ :

# Set control on the userPassword attribute. access to dn=".*,ou=eng,dc=plainjoe,dc=org" attrs=userPassword by self write by * auth by dn=".*,ou=admins,ou=eng,dc=plainjoe,dc=org" write Hoặc :

# Set control on the userPassword attribute. access to dn.chilren="ou=eng,dc=plainjoe,dc=org" attrs=userPassword

by self write by * auth

Một phần của tài liệu Đồ án tin học nghiên cứu về giao thức LDAP (Trang 25)