restricted decrypt permission

restricted decrypt permission enables or disables restricted decrypt permission in all databases, and is a dynamic configuration option: you need not restart Adaptive Server for it to take affect.

The SSO runs this command to enable or disable restricted decrypt permission in all databases:

sp_configure "restricted decrypt permission", [1 | 0]

When restricted decrypt permission is set to 0 (off), decrypt permission on encrypted columns acts the same as in versions earlier than 15.0.2:

When restricted decrypt permission is set to 1 (on):

If you change restricted decrypt permission from 0 to 1, currently executing statements that use implicit decrypt permission finish; however any subsequent statements that use implicit decrypt permission fail with this error until the SSO grants the user decrypt permission on the necessary columns:

Msg 10330 "DECRYPT permission denied on object object_name, database
database_name, owner owner_name."

If you change restricted decrypt permission from 1 to 0, the rows that reflect explicit grants remain in the sysprotects system table. However, these rows have no effect on implicitly granted decrypt permissions because Adaptive Server does not check sysprotects to make sure decrypt permission can be implicitly granted. sp_helprotect displays misleading information for only those users who were granted or revoked explicit decrypt permission before you reconfigure the system, and who now have implicit decrypt permission.

Sybase recommends that, to keep the system consistent, you revoke any explicit decrypt permissions granted to users before you switch between enabling or disabling restricted decrypt permission to keep the system consistent.