Skip to content

Agent access control mechanism #124

Open
@mhasself

Description

@mhasself

As discussed on call today, it would be good to have a way of implementing privileges, mostly to prevent accidental manipulation of an Agent when coordinated events are happening (such as operation of the Observatory by the main Sequencer).

It's not super obvious how to do this. One way would be to have all clients send an access level (as an integer, say) with all Operation method calls. This would happen as part of the underlying protocol and not be accessible as an argument in the call signature. On the receiving end, the access level would be checked by OCSAgent code (not in the Agent's Operation implementation) and rejected if the access level is insufficient for the Agent's current minimum access level.

Finally... the Agent's minimum access level would be determined by it monitoring some pubsub channel(s). When a Sequencer starts working, it publishes messages of the form "hey all agents, raise your minimum access level to 5 for the next 2 minutes or until I let you know otherwise". When the Sequencer wants to relinquish exclusive access, it publishes "hey all agents, you may lower your minimum access level to 0."

We're mostly trying to avoid accidental conflicts here -- a given MatchedClient should default to access level 0 but should be able to escalate to level 5, say, through a keyword argument or data member set.

Does this make sense? Discuss.

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions