286 Commits

Author SHA1 Message Date
fiatjaf
e8637afa38 policies: timestamps policies take time.Duration v0.7.6 2024-08-20 10:40:29 -03:00
fiatjaf
e38036a5e6 add a sample to docs landing page. 2024-08-20 08:01:37 -03:00
fiatjaf
6a9dcdcbd4 add a fuzz test. v0.7.5 2024-08-14 09:30:02 -03:00
fiatjaf
5ae4d1194a this fix was stupidly missing yesterday. 2024-08-14 08:29:28 -03:00
fiatjaf
753a1191b9 add test for that. v0.7.4 2024-08-13 13:59:08 -03:00
fiatjaf
3e6d763a79 fix wrong matching on listener remove when router is used.
pablo's crash, see https://t.me/nip29_temp/670
2024-08-13 13:21:41 -03:00
fiatjaf
3b03f6700c convert the random listener tests into fuzzy tests. 2024-08-13 11:42:22 -03:00
fiatjaf
d7056f1515 tests that caught the previous two bugs. v0.7.3 2024-08-04 17:44:12 -03:00
fiatjaf
4e0971bafe fix removeListenerId() -- do not replace twice with the same last item when a client has repeated ids. 2024-08-04 17:43:25 -03:00
fiatjaf
07ea3a35ec removeClientAndListeners() -- stop confusing listeners when removing from the same ws. 2024-08-04 17:25:19 -03:00
fiatjaf
ef57f54a28 fix listeners convoluted magic and add tests for it. v0.7.2 2024-08-01 18:16:08 -03:00
fiatjaf
a103353254 fix development mess. v0.7.1 2024-08-01 12:41:27 -03:00
fiatjaf
5f0f9eec99 .PreventBroadcast slice of functions for controlling what events get broadcasted and to whom.
addresses https://t.me/nip29_temp/303
2024-07-31 10:34:53 -03:00
fiatjaf
a63dc829df routing. v0.7.0 2024-07-30 12:53:27 -03:00
Barry Deen
096890804f Add instructions to download the framework 2024-07-30 08:44:45 -03:00
fiatjaf
5a90326695 fix sentence in docs. 2024-07-23 16:49:11 -03:00
fiatjaf
214b92ba3b management: check 'u' tag on authorization event. 2024-07-16 13:30:14 -03:00
fiatjaf
b79f735e7a docs: link to go docs from home. 2024-07-15 13:44:46 -03:00
fiatjaf
28d7b83186 docs: fix cookbook link on home. 2024-07-15 13:36:26 -03:00
fiatjaf
82ab43075a docs: add source code. 2024-07-15 13:35:40 -03:00
fiatjaf
bb8b36df80 add docs. 2024-07-15 13:25:07 -03:00
fiatjaf
5c7121a3f6 update go-nostr to fix some bugs. v0.6.1 2024-07-12 13:47:25 -03:00
fiatjaf
433be401c2 rename a file I don't remember why. v0.6.0 2024-07-11 15:37:30 -03:00
fiatjaf
71daea9d7b nip86: fix hash checking and always return a valid RPC response with an error instead of http errors. 2024-07-11 15:37:09 -03:00
fiatjaf
9d6dad073a fix nip86 route header matching. 2024-07-11 15:36:25 -03:00
fiatjaf
dea3e59c92 nip86: disallow old auth events. 2024-07-09 17:03:39 -03:00
fiatjaf
91c652ef48 nip86: add auth checks. 2024-07-09 00:11:07 -03:00
fiatjaf
535f4c90e0 split nip11 handler into its own file and implement nip86 (relay management api). 2024-07-08 15:42:42 -03:00
fiatjaf
0004c041e0 nip11: signal support for auth always. 2024-07-07 23:38:27 -03:00
fiatjaf
ef4a14a831 nip11: signal support for deletions and count if those handlers exist. 2024-07-07 23:37:43 -03:00
fiatjaf
3f73a9690a GetConnection() and GetAuthed() may return empty. v0.5.0 2024-07-03 22:16:44 -03:00
fiatjaf
2a8b704299 returning a nil chan from QueryEvents causes an immediate eose from that source. 2024-05-29 07:51:48 -03:00
fiatjaf
746f030f46 I'm a teapot -> Too many requests 2024-05-17 20:58:17 -03:00
fiatjaf
81ad56e85c simplify RestrictToSpecifiedKinds() 2024-05-12 20:54:53 -03:00
fiatjaf
f8afb51ee9 ratelimits. v0.4.3 2024-05-12 20:37:00 -03:00
fiatjaf
848e76c664 do not notify listeners when a duplicated event is received. 2024-04-26 14:56:50 -03:00
fiatjaf
8b1a7f2195 ApplySaneDefaults() 2024-04-19 15:38:34 -03:00
fiatjaf
8557c7a8dc policy to reject events with base64 media. 2024-04-19 15:33:15 -03:00
fiatjaf
f1f54a7bf3 stop and error on delete failed. v0.4.2 2024-04-18 21:20:46 -03:00
fiatjaf
e03a02fed7 prevent storing duplicates. 2024-04-18 21:20:35 -03:00
fiatjaf
255f7bc827 delete all previous replaceable events by default. v0.4.1 2024-04-10 21:34:23 -03:00
fiatjaf
3214dac302 fix pre-search on policies. 2024-03-30 14:23:17 -03:00
fiatjaf
5efadf6256 do not give away so much. 2024-03-29 18:25:47 -03:00
fiatjaf
27d6769009 format last commit. 2024-03-29 18:24:44 -03:00
Sebastix
44baacac42 * sort kinds before the binary search is run
* optimized return messages with more context why the policy blocks an event
2024-03-29 18:24:21 -03:00
fiatjaf
35053f6215 when LimitZero don't do any database queries. v0.4.0 2024-03-29 08:12:39 -03:00
fiatjaf
8854ad7a95
don't send a NOTICE when REQs are rejected anymore, just the CLOSED. 2024-03-25 10:55:59 -03:00
fiatjaf
c5c17029ba
basic kind validation policy. v0.3.2 2024-03-13 12:40:54 -03:00
fiatjaf
e174dd6a95
support 1, 11 and 70 on NIP-11 list. 2024-02-13 12:24:06 -03:00
fiatjaf
cd4c25c845
implement NIP-70 ["-"] tag support. 2024-02-13 12:22:15 -03:00