1857 Commits

Author SHA1 Message Date
github-actions[bot]
5e2f2617ab
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-20 11:41:33 -04:00
Matthieu Sieben
35a1264297
Remove non-standard *_endpoint_auth_method () 2024-08-20 17:26:19 +02:00
Matthieu Sieben
5131b027f0
Allow charset in content-type header of incoming requests ()
* Allow charset in content-type header of incoming requests
2024-08-20 11:24:56 +02:00
Matthieu Sieben
3ebcd4e616
Remove "exp" from DPoP proofs ()
* Remove "exp" from DPoP proofs

* Remove validity check on exp dpop proof claim
2024-08-20 11:21:11 +02:00
devin ivy
f9a2f3ed17
Fix calls from pds containing content-type but no body ()
* pds: fix calls from pds containing content-type but no body

* build
2024-08-18 19:32:35 -04:00
github-actions[bot]
40c145fb16
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-18 16:34:50 -04:00
Daniel Holmgren
50c0ec176c
Service auth method binding (lxm) ()
* add scopes to service auth impl

* add error to getServiceAuth

* send scoped tokens from pds

* clean up privileged access scopes & allow simple service auth tokens for app passwords

* integration into ozone

* fix up bsky tests

* cleanup xrpc-server tests

* fix up tests & types

* one more test

* fix read after write tests

* fix mod auth test

* convert scopes to be a single method name

* add scope check callback for auth verifier

* pds changes only

* fix feed generation tests

* use scope for ozone service profile

* dont verify scopes on pds yet

* tidy

* tidy imports

* changeset

* add tests

* tidy

* another changeset

* scope -> lxm

* tidy

* clean up scope references

* update nonce size

* pr feedback

* trim trailing slash

* nonce -> jti

* fix xrpc-server test

* allow service auth on uploadBlob

* fix build error

* changeset

* build, tidy

* xrpc-server: update lxm claim check error

* appview: temporarily permit labeler service calls to omit lxm claim

* xrpc-server: fix test

* changeset

* fix merged tests

---------

Co-authored-by: Devin Ivy <devinivy@gmail.com>
2024-08-18 15:46:07 -04:00
Shoshána Abigail
2c65cb9eb3
Fix getActorLikes documentation to reflect auth required ()
You can only view your own likes and this fixes the documentation to note that auth is required and that the actor must be the requesting account

https://github.com/bluesky-social/atproto/pull/1440#issuecomment-1700193127
2024-08-17 13:06:39 -04:00
Hailey
533774ce4a
exact matches always show profile regardless of block status ()
* exact matches always show profile regardless of block status

* return false if no actor

* tweaks

* update the duplicate test...
2024-08-16 15:42:55 -04:00
Hailey
17e2d29474
Don't return profiles in reference lists/starter packs that have a block relationship with the owner ()
* proposal

* clean

* create seed

* type

* update tests

* change pairs

* `maybeGetBlocksForReferenceList`

* add logic for filtering inside of `getStarterPack()`

* move seeding to test

* nits

* tweak getting blocks

* oops
2024-08-16 11:54:13 -04:00
Foysal Ahamed
bc131ebb01
Add index on createdAt column on moderation_event table ()
*  Add index on createdAt column on moderation_event table

* Execute dropIndex

Co-authored-by: devin ivy <devinivy@gmail.com>

* tidy

---------

Co-authored-by: devin ivy <devinivy@gmail.com>
2024-08-15 18:25:31 -04:00
Matthieu Sieben
04112783db
Provide a ponyfill for CustomEvent ()
* fix(oauth-client): provide a ponyfill for CustomEvent (required by NodeJS < 20)
2024-08-15 18:44:34 +02:00
Matthieu Sieben
acbacbbd56
Ensure presence of DPoP related response headers ()
* fix(pds): ensure presence of DPoP related response headers

* Expose the request context for AuthVerifier and StreamAuthVerifier as distinct types

* Properly type ReqCtx for stream auth
2024-08-13 16:41:36 +02:00
Devin Ivy
94df42debf prettier ignore changelogs, as changesets not resolving prettier config properly 2024-08-13 00:28:36 -04:00
github-actions[bot]
cf988a5b4c
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-12 22:55:19 -04:00
devin ivy
22af354a5d
Export AtpAgentOptions type from @atproto/api ()
Export AtpAgentOptions type to better support extending AtpAgent.
2024-08-12 18:00:56 -04:00
Devin Ivy
24fa446a2b tidy 2024-08-12 16:26:42 -04:00
github-actions[bot]
3940733bf0
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-12 16:11:19 -04:00
Matthieu Sieben
2bdf75d7a6
Update changeset to better reflect changes ()
* Update changeset to better reflect changes

* Remove un-necessary packages from changeset

* codegen

* expose lexicons instead of schemas

* export a copy of the internal lexicon

* typo

* fix minor typos in changesets

---------

Co-authored-by: Devin Ivy <devinivy@gmail.com>
2024-08-12 15:58:58 -04:00
Matthieu Sieben
b934b396b1
Client SDK rework ()
* feat(api): support creation of oauth based AtpAgents

* oauth: misc fixes for confidential clients

* fix(xprc): remove ReadableStream.from polyfill

* OAuth docs tweaks ()

* OAuth: clarification about client_name being shown

* OAuth: re-write handle resolution privacy concern

* avoid relying on ReadableStream.from in xrpc-server tests

* feat(oauth-types): expose "ALLOW_UNSECURE_ORIGINS" constant

* feat(handle-resolver): expose "AtprotoIdentityDidMethods" type

* fix(oauth-client): ensure that the oauth metadata document contains client_id_metadata_document_supported

* fix(oauth-types): prevent unknown query string in loopback client id

* fix(identity-resolver): check that handle is in did doc's "alsoKnownAs"

* feat(oauth-client:oauth-resolver): allow logging in using either the PDS URL or Entryway URL

* fix(oauth-client): return better error in case of invalid "oauth-protected-resource" status code

* refactor(did): group atproto specific checks in own

* feat(api): relax typing of "appLabelers" and "labelers" AtpClient properties

* allow any did as labeller (for tests mainly)

* fix(api): allow to override "atproto-proxy" on a per-request basis

* remove release candidate versions from changelog

* update changeset for api and xrpc packages

* Add missing changeset

* revert RC versions

* Proper wording in OAUTH.md api example

* remove "pre" changeset file

* xrpc: restore original behavior of setHEader and unsetHeader

* docs: add comment for XrpcClient 's constructor arg

* feat(api): expose "schemas" publicly

* feat(api): allow customizing the whatwg fetch function of the AtpAgent

* docs(api): improve migration docs

* docs: change reference to BskyAgent to AtpAgent

* docs: mention the breaking change regarding setSessionPersistHandler

* fix(api): better split AtpClient concerns

* fix(xrpc): remove unused import

* refactor(api): simplify class hierarchu by removeing AtpClient

* fix(api): mock proper method for facets detection

* restore ability to restore session asynchronously

* feat(api): allow instantiating Agent with same argument as super class

* docs(api): properly extend Agent class

* style(xrpc): var name

* docs(api): remove "async" to header getter

---------

Co-authored-by: Devin Ivy <devinivy@gmail.com>
Co-authored-by: bnewbold <bnewbold@robocracy.org>
Co-authored-by: Hailey <me@haileyok.com>
2024-08-12 19:57:21 +02:00
Daniel Holmgren
8092715ea0
Allow aud of pds or entryway for service auth tokens on pds ()
allow aud of pds or entryway for service auth tokens on pds
2024-08-06 19:02:00 -05:00
github-actions[bot]
1072ba6fd9
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-06 14:52:19 -05:00
Daniel Holmgren
08ef309c9c
Lex-cli prettier changes changeset () 2024-08-06 14:44:53 -05:00
github-actions[bot]
66484a1041
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-05 18:10:44 -05:00
Daniel Holmgren
269cbc87c5
PDS - inspect bearer tokens ()
* inspect bearer tokens to determine if theyre access tokens or service auth tokens

* changeset
2024-08-05 18:05:47 -05:00
github-actions[bot]
b0a5fa3d70
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-05 15:21:57 -05:00
Daniel Holmgren
dc471da267
Service auth method binding - PDS ()
* pds changes only

* use scope for ozone service profile

* dont verify scopes on pds yet

* tidy

* tidy imports

* changeset

* add tests

* another changeset

* scope -> lxm

* tidy

* update nonce size

* pr feedback

* trim trailing slash

* nonce -> jti

* fix xrpc-server test

* allow service auth on uploadBlob
2024-08-05 15:09:50 -05:00
bnewbold
a95a902bba
minor typos in descriptions and comments ()
* lex: typos in descriptions

* more minor typos

* codegen lexicon typos

* more comment typos
2024-08-05 09:49:25 -07:00
Eric Bailey
8d99b32c7d
Fix run-dev-env-logged command () 2024-08-05 09:31:51 -05:00
github-actions[bot]
c007e930ed
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-08-02 17:17:16 -05:00
Hailey
c7de8f07c5
Tweak some wording in oauth-client-browser readme () 2024-08-02 13:43:50 -07:00
Eric Bailey
951a3df15a
Remove detach ()
* Remove detach record

* Changeset
2024-08-02 15:19:29 -05:00
Hailey
1419114394
Run test env with updateSnapshot ()
* nit

* pds too
2024-08-01 13:41:59 -07:00
github-actions[bot]
c5c5203a6e
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-07-31 16:51:04 -05:00
Eric Bailey
ff803fd2bf
[Detach] Lexicons ()
* Define new detach record

* Codegen

* Add limit of 1k

* Codegen

* add protos

* tweak schema

* Add changeset

---------

Co-authored-by: dholms <dtholmgren@gmail.com>
2024-07-31 16:45:20 -05:00
github-actions[bot]
a5fbd8c0fa
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-07-31 16:37:45 -05:00
Eric Bailey
77c5306d2a
Update muted words handling, add attributes ()
* Sketch proposal for additional muted words attributes

* Rename ttl -> expiresAt

* Feedback

* Codegen

* Refactor muted words methods to integrate new attributes

* Add changeset

* Use datetime format

* Simplify migration

* Fix tests

* Format

* Re-integrate tests

* Let the lock cook

* Fix comments

* Integrate mute words enhancements ()

* Check expiry when comparing mute words

* Check actors when comparing

* Tweak lex, condegen

* Integrate new prop

* Remove fake timers

(cherry picked from commit ad31910560ce938e3ff64944d46355c64635ebf8)

* Update changeset

* Prevent deleting value when updating

* Include missing test

* Add default

* Apply default 'all' value to existing mute words to satisfy Typescript

* Fix types in tests

* Fix types on new tests
2024-07-31 16:22:19 -05:00
Eric Bailey
803d1b6c0d
Use default Statsig export () 2024-07-24 17:54:16 -05:00
bnewbold
66d650bc62
remove link to invite code form () 2024-07-24 11:57:46 -07:00
github-actions[bot]
5f2bcd1807
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-07-23 21:36:34 +01:00
Daniel Holmgren
76c91f8325
Priority notification setting ()
* priority notif settings in bsync

* lint

* priority notifications lexicon update

* codegen

* putNotificationPreferences -> putPreferences

* bsync: reorg around notif "priority", fix build, add validation & tests

* bsync: notif channel fix, tests fix

* bsky: update protos for priority notifs

* api prerelease

* add priority notif to actor state table

* dataplane impl

* appview: wire-up notif priority params

* appview: notif priority tests

* dataplane impl

* fix up tests

* tidy

* add changeset

---------

Co-authored-by: Samuel Newman <10959775+mozzius@users.noreply.github.com>
Co-authored-by: Devin Ivy <devinivy@gmail.com>
2024-07-23 12:33:01 -07:00
Yoshihiro Sugi
12dcdb668c
fix(api): hasMutedWord for facets with multiple features ()
* Fix hasMutedWord for facets with multiple features

* Add changeset
2024-07-19 14:07:03 -07:00
devin ivy
7e88f6fc1d
Appview: enable insight into full thread context ()
* appview: enable mods viewing full thread context

* build
2024-07-18 19:06:26 -07:00
Foysal Ahamed
5d2fdeba47
🐛 include takedowns in post thread for admins () 2024-07-16 23:56:30 -07:00
Matthieu Sieben
f7bf2dd24d
Minor OAuth client fixes ()
feat(oauth-client-browser): add staging and prod env config
2024-07-15 23:37:25 -07:00
github-actions[bot]
f2f8de63b3
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-07-12 17:34:56 +02:00
Matthieu Sieben
acc9093d28
OAuth: 2FA ()
* chore(ci): update setup-node & checkout actions to v4

* refactor(oauth): rename internal types to avoid conflicting types
fix(oauth): support building from parcel
feat(oauth): add runtime lock support to prevent concurrent session updates
feat(oauth): improve metadata validation
fix(oauth): allow use of handle as login hint
fix: proper parsing of authorization header
feat(oauth): add email 2fa support
feat(oauth): adapt auth UI to match app UI

* fix(oauth): improve parsing of digest algo

* fix(oauth-provider): dead code cleanup

* fix(oauth-provider): avoid inconsistent use of "id" prop in InputCheckbox

* style(oauth-provider): use if/else instead of switch

* feat(oauth-provider): stronger validation of customization data

Invalid oauth customization would cause the server to crash at startup.

* docs(oauth-client): explain why the abortRequest method is not mandatory

* fix(oauth-client): cancel fetch response body when not used

* docs: typo

Co-authored-by: devin ivy <devinivy@gmail.com>

* feat(oauth-provider:metadata): add client_id_metadata_document_supported metadata

* fix(oauth-provider): require the content-type to be set on client metadata response

* feat(common): add obfuscation utilities
fix(pds): show user did in logs
fix(ozone): show user did in logs

* tidy

* fix(simple-store): avoid leaking context when calling hooks

* fix: use patch level changeset

* chore(oauth-types): add changeset regarding client_id_metadata_document_supported

* chore: add changeset for bsky & ozone

* unify loggerMiddleware instantiation

* tidy

---------

Co-authored-by: devin ivy <devinivy@gmail.com>
2024-07-12 17:28:03 +02:00
github-actions[bot]
b899505293
Version packages ()
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2024-07-12 11:22:11 -04:00
Eric Bailey
8f22a2521c
Update data source for getSuggestedFollowsByActor ()
* Update lex

* Codegen

* Set up StatSig

* Integrate new implementation into old endpoint

* Add todo to crypto module

* Format

* Specify StatSig env

* Downgrade pnpm to match CI, bump lock

* Catch StatSig errors

* Use sep env

* Reset lockfile

* Re-add new dep using correct pnpm version

* tidy

* Integrate into AppContext and lifecycle

* Use camelCase

* Switcheroo

Co-authored-by: devin ivy <devinivy@gmail.com>

* Init prior to server listen start

* Move test env check up to server config

* Add logger and log

* Better comment

---------

Co-authored-by: devin ivy <devinivy@gmail.com>
2024-07-11 17:14:54 -04:00
Daniel Holmgren
2f40203fb4
Add in-memory did cache to Ozone backend ()
* add ozone in-memory did cache

* changeset
2024-07-10 16:21:30 -05:00