Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add admin fields to Platform entity #9

Closed
calebsheridan opened this issue Mar 2, 2020 · 0 comments
Closed

Add admin fields to Platform entity #9

calebsheridan opened this issue Mar 2, 2020 · 0 comments

Comments

@calebsheridan
Copy link
Member

Abstract

Timelocks are not used by all platforms. This could be because either:

  • The platform does not need a timelock for security (i.e. Uniswap)
  • The admins have decided not to use a timelock (i.e. Aave)

These platforms should still be included in the project.

Schema Update

type Platform @entity {
  id: ID!
  target: [Target]! @derivedFrom(field: "platform")
  timelock: [Timelock]! @derivedFrom(field: "platform")
  currentAdmin: String   # New field. Ethereum address or null (no admin)
  usesAdmin: Boolean!    # New field.
  usesTimelock: Boolean! # New field.
}

Example queries

Supported platforms with an admin and without a timelock

where: { 
  usesAdmin: true
  usesTimelock: false
}

Supported platforms with an admin and timelock

where: { 
  usesAdmin: true,
  usesTimelock: true,
}

Supported platforms without an admin

where: { 
  usesAdmin: false
}

See also

https://defiwatch.net/admin-key-config-and-opsec/project-reviews

#5

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant