keygen-api
Action Policy
keygen-api | Action Policy | |
---|---|---|
23 | 10 | |
577 | 1,337 | |
12.3% | - | |
9.7 | 6.3 | |
2 days ago | 4 days ago | |
Gherkin | Ruby | |
GNU General Public License v3.0 or later | MIT License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
keygen-api
-
"Useless Ruby sugar": Pattern matching (Pt. 1)
I don't have an Elixir background, but I absolutely utilize pattern matching in my Ruby code bases:
- https://github.com/keygen-sh/typed_params/blob/4e4982b7d2b26...
- https://github.com/keygen-sh/typed_params/blob/4e4982b7d2b26...
- https://github.com/keygen-sh/keygen-api/blob/master/app/migr...
- https://github.com/keygen-sh/keygen-api/blob/36cd61db143cc1c...
- https://github.com/keygen-sh/typed_params/blob/4e4982b7d2b26...
I love it. I want even more pattern matching too, like with defp: https://bugs.ruby-lang.org/issues/19764.
-
I don’t buy “duplication is cheaper than the wrong abstraction” (2021)
Honestly, I don't have many resources to provide. I read a lot of policy tests via GitHub search (e.g. path:spec/policies/*/*.rb), but couldn't find anything that looked like what I wanted. I wrote the DSL as-needed in order to fully test my app's authz while migrating from Pundit to ActionPolicy.
It's not the prettiest when you actually look beneath the covers [0], but it does what I wanted -- provides a way to write exhaustive authz tests. Without the DSL, I probably wouldn't have written. The PR for said migration was massive [1], and was a precursor to going open source [2].
[0]: https://github.com/keygen-sh/keygen-api/blob/master/spec/sup...
[1]: https://github.com/keygen-sh/keygen-api/pull/647
[2]: https://github.com/keygen-sh/keygen-api/issues/644
-
Let's Talk About Open Source
Yes, I can see why you might make this argument. [1]
[1] https://github.com/keygen-sh/keygen-api/blob/master/LICENSE....
-
Keygen: a software licensing and distribution API
And not at all set on WorkOS. It just looked like the easiest way to set up SSO last time I researched the topic. Feel free to comment on the issue with any recommendations.
-
Introducing New Heroku Postgres Plans
Since when can you run heroku pg:upgrade to switch database tiers? I was following an upgrade sequence I put together over the years [^0], but I guess Heroku automated this at some point? What would be really funny is if this had been possible all long...
[^0]: https://github.com/keygen-sh/keygen-api/blob/master/.notes/d...
- GitHub - keygen/api: an open, source-available software licensing and distribution API built with Ruby on Rails
-
How to connect my desktop app to MySql db
Maybe use keygen-sh?
-
NPM won't publish packages containing the word keygen
I run a business called Keygen [^0], and own the @keygen namespace on npm. We’re working on a Node SDK, so this isn’t good to hear. I’ll open up a discussion with them and see what we can do.
[^0]: https://keygen.sh
- Show HN: Keygen – an open, source-available software licensing/distribution API
-
GitHub support for PHP Packages: “no longer planned”
- org-2.php.pkg.github.com/package
I wonder if that had any impact on their decision.
[0]: https://github.com/keygen-sh/keygen-api/issues/490
Action Policy
-
Using Action Policy for a Ruby on Rails App: The Basics
Action Policy is a flexible, extensible, and performant authorization framework for Ruby and Rails apps. It uses multiple caching strategies out of the box, making it very fast, especially if your authorization rules require database queries.
-
Pundit VS Action Policy - a user suggested alternative
2 projects | 2 Jul 2023
Action Policy is the latest Authorization framework I've seen recommended. What is more, it is maintained by the nice and experienced team from Evil Martians.
-
GitHub - keygen/api: an open, source-available software licensing and distribution API built with Ruby on Rails
Lots of goodies here, such as token authentication, role- and permission-based authorization (including a move from Pundit to ActionPolicy), and how I test the API end-to-end using *raises flame shield* Cucumber.
- Authentication, Roles, and Authorization... oh my.
-
Five Ruby Gems for Authentication and Authorization
Also, ActionPolicy is better than Pundit for most applications. Give it a try.
-
Concerns about authorization when going in production
Use Action Policy or Pundit, and write tests for your policies. Authz is worth testing with near complete coverage.
- Service Objects (with dry-monads) and authorization
-
Access control gem for your Rails application (the 2nd)
You may ask what's makes Active Entry better or different from other gems like Pundit, Action Policy (especially), or CanCanCan.
-
Rails: How to Reduce Friction at the Authorization Layer
At work, we've recently faced similar issues and moved to ActionPolicy as a result. It's designed slightly differently, but there is a lot of overlap with what John came up with.
What are some alternatives?
ruby-next - Ruby Next makes modern Ruby code run in older versions and alternative implementations
Pundit - Minimal authorization through OO design and pure Ruby classes
ecoji - Encodes (and decodes) data as emojis
CanCanCan - The authorization Gem for Ruby on Rails.
typed_params - An alternative to Rails strong_parameters. Define structured and strongly-typed parameter schemas for your Rails controllers.
rolify - Role management library with resource scoping
machineid - Get the unique machine id of any host (without admin privileges)
jay_doubleu_tee - A JWT authorization middleware for any web application.
Zulip - Zulip server and web application. Open-source team chat that helps teams stay productive and focused.
AccessGranted - Multi-role and whitelist based authorization gem for Rails (and not only Rails!)
roadmap - GitHub public roadmap
Declarative Authorization - An unmaintained authorization plugin for Rails. Please fork to support current versions of Rails