Popularity
2.7
Growing
Activity
0.0
Stable
42
1
8
Programming language: Go
License: MIT License
Tags:
Authentication & OAuth
scope alternatives and similar packages
Based on the "Authentication and OAuth" category.
Alternatively, view scope alternatives based on common mentions on social networks and blogs.
-
keto
The most scalable and customizable permission server on the market. Fix your slow or broken permission system with Google's proven "Zanzibar" approach. Supports ACL, RBAC, and more. Written in Go, cloud native, headless, API-first. Available as a service on Ory Network and for self-hosters. -
oidc
Easy to use OpenID Connect client and server library written for Go and certified by the OpenID Foundation -
go-guardian
Go-Guardian is a golang library that provides a simple, clean, and idiomatic way to create powerful modern API and web authentication. -
signedvalue
DISCONTINUED. Compatibility layer for tornado's signed values (and secure cookies consequently) -
sessiongate-go
A driver for the SessionGate Redis module - easy session management using the Go language. -
gosession
This is quick session for net/http in GoLang. This package is perhaps the best implementation of the session mechanism, at least it tries to become one.
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
Promo
www.saashub.com
Do you think we are missing an alternative of scope or a related project?
Popular Comparisons
README
Scope
Easily Manage OAuth2 Scopes In Go
Scope Matching Using Wildcard Strategy
import "github.com/SonicRoshan/scope"
scopeA := "read:user:*"
scopeB := "read:user:username"
doesMatch := scope.MatchScopes(scopeA, scopeB)
This strategy will work like this :-
users.*matchesusers.readusers.*matchesusers.read.foousers.readmatchesusers.readusersdoes not matchusers.readusers.read.*does not matchusers.readusers.*.*does not matchusers.readusers.*.*matchesusers.read.ownusers.*.*matchesusers.read.own.otherusers.read.*matchesusers.read.ownusers.read.*matchesusers.read.own.otherusers.write.*does not matchusers.read.ownusers.*.barmatchesusers.baz.barusers.*.bardoes notusers.baz.baz.bar
Filtering Struct For Read Request
When a client request certain data, this function will eliminate any data in the struct for which the client does not have a read scope.
type user struct {
username string `readScope:"user:read:username"`
email string `readScope:"user:read:email"`
}
func main() {
output := user{username : "Test", email : "Test@Test.com"}
scopesHeldByClient := []string{"user:read:username"}
scope.FilterRead(output, scopesHeldByClient)
// Now output.email will be nil as client does not have scope required to read email field
output := user{username : "Test", email : "Test@Test.com"}
scopesHeldByClient := []string{"user:read:*"}
scope.FilterRead(&output, scopesHeldByClient)
// Now none of the field in output will be nil as client has scopes to read everything in user struct
}