Monorepo for Tangled tangled.org

Require fewer OAuth permissions #209

Closed notjack.space
Closed opened by notjack.space

I was showing Tangled to a friend of mine, and she was very interested but spooked off by the broad access permissions Tangled requires to a user's Bluesky account. But now that ATproto supports narrowing down requested permissions to just specific kinds of records, I think it should be possible for Tangled to greatly reduce how much access it requests.

this has been implemented!

This comment was deleted.

I think there are still a number of low-hanging fruits:

  • For the identity:handle scope, why not just navigate the user to the settings page of their PDS?
  • The rpc:com.atproto.repo.* scopes should be covered by the repo:* and blob:* resources (Unless they are they used for asking knots for manipulating their records on the user’s behalf. But if that’s the case, I dare say, the design decision that reusing the native com.atproto.repo.* procedures instead of bespoke procedures to delegate record manipulations is prone to excessive permissions)
  • The rpc:com.atproto.server.describeServer?aud=* scope can be dropped since the com.atproto.server.describeServer method doesn’t require authentication
  • For the rest of the scopes that interact with the resources under the org.tangled.* namespace, it’d be nice to group them in a permission set, which would significantly reduce the size of the list of permissions the user needs to review
  • And for RPC scopes for Tangled services, I think the aud parameter can be replaced with the inheritAud parameter, as long as they are used to authenticate against a specific Bobbin instance instead of arbitrary knots/spindles
This comment was deleted.

(Sorry, ignore the “This comment was deleted.” message. I tried to actually bypass the OAuth and directly make the comment using service auth, but it seems that I somehow messed up the replyTo property.

Tangentially, performing an inter-service call of the com.atproto.repo.createRecord procedure was tricky because the official Bluesky PDS ignored the atproto-proxy header for the com.atproto.repo.createRecord call, so I had to resort to com.atproto.server.getServiceAuth. This may or may not be another reason not to reuse the com.atproto.repo.* procedures for the delegation purpose.)

Sign up or Sign in to add to the discussion.