requiresRole on DataSource and operationBinding

SmartClient Version: v13.1p_2026-10-21/Enterprise Deployment (built 2026-10-21)

Hi, I need a clarification about declarative security.

The reference describes the two requires attributes as cumulative:

DataSource.requires, if specified, applies before operationBinding.requires is evaluated. In this case, both requires expressions must be true for the request to be accepted.

and that is what I see: setting them to true and false in turn, the request is accepted only when both evaluate to true.

But for requiresRole the reference says:

Note that if DataSource.requiresRole is set, all operations on the DataSource require the roles set for the DataSource as a whole, even if they declare individual requiresRole attributes.

which reads the same way to me, but here either one of the two is sufficient.

Same user, same fetch, changing only the two attribute values:

DataSource.requiresRole operationBinding.requiresRole roles held by the user result
bar foo neither denied
ROLE_ADMIN foo ROLE_ADMIN only allowed
bar ROLE_ADMIN ROLE_ADMIN only allowed

If requiresRole is meant to combine differently from requires, would it be worth saying so
explicitly in the reference? As written, the two pairs read the same way to me.

This is a bug. requiresRole at the DataSource level and requiresRole at the operationBinding level should be enforced independently — both must pass. The OR behavior you observed was incorrect.

This is now fixed and available in nightly builds starting Nov 1.

I can confirm it’s fixed, thank you very much