strfry icon indicating copy to clipboard operation
strfry copied to clipboard

Turn "Write policy plugins" into a NIP

Open alexgleason opened this issue 2 years ago • 3 comments

Basically take this: https://github.com/hoytech/strfry/blob/master/docs/plugins.md

Slap a NIP-one-hundred-something on it, add some words at the top and bottom and submit to nostr-protocol/nips

alexgleason avatar Apr 05 '23 00:04 alexgleason

Related: https://gitlab.com/minds/infrastructure/nostr-relay/-/issues/15

alexgleason avatar Apr 05 '23 14:04 alexgleason

Neat idea! I would definitely be open to proposing this as a NIP. My only worry is that maybe with some more applications we might come up with some improvements, and wouldn't want to have the old behaviour ossified and have to be supported forever.

BTW, do you use the "look-behind" feature? I thought it would be quite useful for re-calculating rate-limits when restarting a server, but maybe it's not actually a good solution for that?

hoytech avatar Apr 07 '23 02:04 hoytech

I'm not using look-behind at all. My rate-limit policy stores data in an squite database: https://gitlab.com/soapbox-pub/strfry-policies/-/blob/develop/src/policies/rate-limit-policy.ts

alexgleason avatar Apr 07 '23 03:04 alexgleason