Removing Page Level Privileges

Implementing Content Security 15-7 for i in 1 .. l_itemown_username_array.count loop -- Get the user ID from the wwsec_api.id_sso API. l_itemown_userid_arrayi := wwsec_api.id_sso p_username = l_itemown_username_arrayi ; end loop; wwsbr_api.add_item_ils_privileges p_master_item_id = 453, p_caid = 33, p_folder_id = 45, p_itemown_user = l_itemown_userid_array ; -- Process cache invalidation messages. wwpro_api_invalidation.execute_cache_invalidation; exception ... end; ■ p_master_item_id is the master ID of the item. You can find this value in the MASTERID column of the WWSBR_ALL_ITEMS view. ■ p_caid is the ID of the page group to which the item belongs. ■ p_folder_id is the ID of the page on which the item appears. ■ p_itemown_user is an array of user IDs to which you want to grant Manage privileges. If you pass the same user or group in more than one of the privilege arrays, the user or group is granted the highest privilege level specified.

15.3.2 Removing Item Level Privileges

If for some reason, you need to remove a user or groups privileges on an item, use the delete_ils_privilege API, as shown in Example 15–10 . Example 15–10 Removing Item Level Privileges delete_ils_privilege API declare l_user_id number := 334; l_page_group_id number := 75; l_page_id number := 1; l_item_id number := 74637; begin wwsbr_api.delete_ils_privilege p_user_or_group_id = l_user_id, p_caid = l_page_group_id, p_folder_id = l_page_id, p_master_item_id = l_item_id ; -- Process cache invalidation messages. wwpro_api_invalidation.execute_cache_invalidation; exception ... end; Tip: You can also update the access privileges for an item using the add_item_ils_privileges API. 15-8 Oracle Fusion Middleware Developers Guide for Oracle Portal ■ p_user_or_group_id is the ID of the user or group for which you want to remove privileges. ■ p_caid is the ID of the page group to which the item belongs. ■ p_folder_id is the ID of the page on which the item appears. ■ p_master_item_id is the master ID of the item. You can find this value in the MASTERID column of the WWSBR_ALL_ITEMS view.

15.3.3 Inheriting Item Level Privileges from the Page

If you decide that an item that has its own privileges defined should, in fact, simply inherit its privileges from the page instead, use the inherit_folder_privileges API to disable ILS this is the same as selecting Inherit Parent Page Access Privileges in the Oracle Portal user interface. Example 15–11 shows how to use the inherit_ folder_privileges API. Example 15–11 Inheriting Item Privileges from the Parent Page inherit_folder_privileges API begin wwsbr_api.inherit_folder_privileges p_master_item_id = 453, p_caid = 33, p_folder_id = 45 ; -- Process cache invalidation messages. wwpro_api_invalidation.execute_cache_invalidation; exception ... end; ■ p_master_item_id is the master ID of the item. You can find this value in the MASTERID column of the WWSBR_ALL_ITEMS view. ■ p_caid is the ID of the page group to which the item belongs. ■ p_folder_id is the ID of the page on which the item appears. Tip: If you want to edit other attributes for the item as well as the ILS setting, you can use the modify_item or modify_item_post_ upload APIs instead. To enable ILS set the p_access_level parameter to wwsbr_api.ITEM_ACCESS, to disable ILS set the parameter to wwsbr_api.FOLDER_ACCESS.