UpdateResourceACLRequest: Difference between revisions
Jump to navigation
Jump to search
No edit summary |
Fernando187 (talk | contribs) (Remove obsolete Requirements section) |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 3: | Line 3: | ||
This function changes the access for one ACL request of the given resource. | This function changes the access for one ACL request of the given resource. | ||
{{Note|This function is protected by default and must be explicitly allowed in the server ACL.}} | |||
Note | |||
==Syntax== | ==Syntax== | ||
Line 32: | Line 31: | ||
end | end | ||
</syntaxhighlight> | </syntaxhighlight> | ||
==See Also== | ==See Also== | ||
{{Resource_functions}} | {{Resource_functions|server}} |
Latest revision as of 15:40, 7 November 2024
This function changes the access for one ACL request of the given resource.
Syntax
bool updateResourceACLRequest ( resource theResource, string rightName, bool access [, string byWho = "" ] )
Required Arguments
- theResource: the resource to set the ACL request for.
- rightName: a string with the name of the right to set the access for. This has to match an existing ACL request.
- access: a boolean value setting the access. True is for allow, and false for deny.
Optional Arguments
- byWho: a string value to identity who is changing the setting.
Returns
Returns true if the setting was changed, or false if no change was required or there was a problem with the arguments.
Example
This function will allow all ACL requests from 'theResource'
function allowAllACLRequests(theResource) local requests = getResourceACLRequests (theResource) for _,request in ipairs(requests) do updateResourceACLRequest ( theResource, request.name, true ) end end
See Also
- addResourceConfig
- addResourceMap
- callRemote
- copyResource
- createResource
- deleteResource
- getResourceACLRequests
- getResourceInfo
- getResourceLastStartTime
- getResourceLoadFailureReason
- getResourceLoadTime
- getResourceMapRootElement
- getResourceOrganizationalPath
- getResources
- isResourceArchived
- isResourceProtected
- refreshResources
- removeResourceFile
- renameResource
- restartResource
- setResourceInfo
- startResource
- stopResource
- updateResourceACLRequest
- Shared
- abortRemoteRequest
- call
- fetchRemote
- getResourceConfig
- getResourceDynamicElementRoot
- getResourceExportedFunctions
- getResourceFromName
- getResourceName
- getResourceRootElement
- getResourceState
- getThisResource
- getRemoteRequests
- getRemoteRequestInfo