Coder Social home page Coder Social logo

auth0-lab / fga-go-sdk Goto Github PK

View Code? Open in Web Editor NEW
12.0 12.0 1.0 298 KB

Auth0 FGA SDK for Go - Use https://github.com/openfga/go-sdk instead

Home Page: https://fga.dev

License: MIT License

Go 100.00%
security authorization fga zanzibar fine-grained-authorization auth0-fga auth0-project-sandcastle

fga-go-sdk's People

Contributors

rhamzeh avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

fga-go-sdk's Issues

Is the Auth0 Fine Grained Authorization open-source?

Hello, how are you guys?

I have a question based on this text part:

Auth0 Fine Grained Authorization (FGA) is an open source Fine-Grained Authorization solution inspired by Google's Zanzibar paper. It was created by the FGA team at Auth0 based on Auth0 Fine-Grained Authorization (FGA), available under a permissive license (Apache-2) and welcomes community contributions.

Where is the source code of Auth0 Fine Grained Authorization?
I'm evaluating open-source projects like Zanzibar to use here in my company.

Readme fix body of WriteAuthorizationModelRequest

fga-go-sdk/README.md

Lines 143 to 161 in 8af084d

body := auth0fga.WriteAuthorizationModelRequest{TypeDefinitions: []auth0fga.TypeDefinition{
{
Type: "user",
},
{
Type: "document",
Relations: &map[string]auth0fga.Userset{
"writer": {This: &map[string]interface{}{}},
"viewer": {Union: &auth0fga.Usersets{
Child: &[]auth0fga.Userset{
{This: &map[string]interface{}{}},
{ComputedUserset: &auth0fga.ObjectRelation{
Object: auth0fga.PtrString(""),
Relation: auth0fga.PtrString("writer"),
}},
},
}},
},
},

This is missing the Metadata, no? Something like

Body(auth0fga.WriteAuthorizationModelRequest{
	SchemaVersion: auth0fga.PtrString("1.1"),
	TypeDefinitions: []auth0fga.TypeDefinition{
		{
			Type: "user",
		},
		{
			Type: "repo",
			Relations: &map[string]auth0fga.Userset{
				"reader": {This: &map[string]interface{}{}},
			},
			Metadata: &auth0fga.Metadata{Relations: &map[string]auth0fga.RelationMetadata{
				"reader": {DirectlyRelatedUserTypes: &[]auth0fga.RelationReference{
					{Type: "user"},
				},
				},
			},
			},
		},
	},
}).

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.