Commit graph

1,113 commits

Author SHA1 Message Date
Phantasm
bad04ab482
Sec: Bump cowboy to version 2.19.0
Fixes:
  cowboy 2.16.1 - EEF-CVE-2026-65624 (MEDIUM)
    aka: CVE-2026-65624
    Cowboy HTTP/1.1 max_headers Bypass via Duplicate Header Names Enables Memory Exhaustion
    https://osv.dev/vulnerability/EEF-CVE-2026-65624
2026-09-08 21:43:05 +02:00
Phantasm
92b8fba3e3
Sec: Bump cowlib to 2.20.0 and gun to 2.6.0
Fixes:
  cowlib:
    EEF-CVE-2026-43971 (MEDIUM)
    aka: CVE-2026-43971
    Link Header Directive Smuggling via Unescaped target/rel/Attribute Keys in cow_link:link/1
    https://osv.dev/vulnerability/EEF-CVE-2026-43971

    EEF-CVE-2026-43966 (MEDIUM)
    aka: CVE-2026-43966, GHSA-w4f7-4cxr-rv3c
    HTTP Response Splitting via Non-VCHAR Bytes in cow_http_struct_hd:escape_string/2
    https://osv.dev/vulnerability/EEF-CVE-2026-43966

    EEF-CVE-2026-43969 (LOW)
    aka: CVE-2026-43969, GHSA-g2wm-735q-3f56
    Cookie Request Header Injection via Unvalidated Encoder in cow_cookie:cookie/1
    https://osv.dev/vulnerability/EEF-CVE-2026-43969
  gun:
    GHSA-w4f7-4cxr-rv3c (MEDIUM)
    aka: CVE-2026-43966, EEF-CVE-2026-43966
    cowboy and gun affected by an HTTP Request/Response Splitting vulnerability
    https://osv.dev/vulnerability/GHSA-w4f7-4cxr-rv3c
2026-09-08 21:38:55 +02:00
Phantasm
770d827b50
Sec: Bump bandit to version 1.12.5
Fixes:
- EEF-CVE-2026-74836 (HIGH)
  aka: CVE-2026-74836, GHSA-xj8g-532w-jv94
  HTTP/2 connection-window starvation pins Plug processes indefinitely in Bandit
  https://osv.dev/vulnerability/EEF-CVE-2026-74836

- EEF-CVE-2026-75484 (MEDIUM)
  aka: CVE-2026-75484, GHSA-x3gh-xhj4-3vq8
  HTTP/2 header field values containing CR, LF or NUL are passed to the application unvalidated in Bandit
  https://osv.dev/vulnerability/EEF-CVE-2026-75484
2026-09-08 21:28:37 +02:00
Phantasm
45459c8398
Merge branch 'develop' into audit-mix-audit-report 2026-08-19 22:20:55 +02:00
Phantasm
5709531197
Sec: Bump Phoenix LiveView to 1.2.9
Technically 1.1.33 would also do...

Also updates:
  phoenix_pubsub 2.1.3 => 2.2.0
  ranch 2.2.0 => 2.2.1
  websock_adapter 0.5.8 => 0.5.9
2026-08-19 22:08:21 +02:00
Phantasm
c4ca9b41ad
Sec: Bump Phoenix to version 1.8.11 2026-08-19 22:08:20 +02:00
Phantasm
39d5648447
Sec: Bump bandit to 1.12.4
Also bumps:
  plug 1.20.2 => 1.20.3
  plug_crypto 2.1.1 => 2.2.0
  thousand_island 1.4.3 => 1.5.0
2026-08-19 22:07:22 +02:00
Phantasm
71cb70cd01
Sec: Bump postgrex to 0.22.4 2026-08-19 22:06:26 +02:00
Phantasm
59042e2793
Syslog: set runtime: false to fix OTP releases
The syslog package is not directly part of the runtime.
2026-08-18 21:41:48 +02:00
Phantasm
0e642d4c90 Merge pull request 'Syslog: Fix intermittent failure to compile due to old pc version' (#7965) from syslog-pc-fix into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7965
2026-08-18 18:53:17 +00:00
Phantasm
16890c051a
Syslog: Fix intermittent failure to compile due to old pc version
Upstream hasn't made a release with the fix, pin fixed commit
for the time being.
2026-08-18 19:54:42 +02:00
Phantasm
6a5ca6213a
Oban: Enable Reindexer plugin to reduce oban_jobs index DB bloat 2026-08-18 19:29:00 +02:00
Phantasm
48d6e9476b Merge pull request 'Revert "Merge pull request 'MediaProxy: detect images when there's no file extension' (#7933) from mediaproxy-content-type into develop"' (#7959) from revert-7933 into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7959
2026-08-14 20:24:56 +00:00
Phantasm
5ecc936444
Docs: split wall of install commands, fix downloading OTP bundle
Bundle could not be downloaded, because sudo does not cope with the
previous syntax that double quoted the whole command, and the download
link was single quoted.
2026-08-13 23:52:06 +02:00
Phantasm
f672ab337c
Revert "Merge pull request 'MediaProxy: detect images when there's no file extension' (#7933) from mediaproxy-content-type into develop"
A partial revert, keeping the updated @inline_content_types list and
cosmetic changes.

This reverts commit 4fe567064a, reversing
changes made to 9b8aa2e2ee.
2026-08-13 22:02:11 +02:00
nicole mikołajczyk
2876fed876 Embed notificaiton details for grouped move/reaction/chat/report notification
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
2026-08-02 22:13:31 +02:00
mkljczk
253bbb80f5
Add rollback migrations for Rebased
Signed-off-by: mkljczk <git@mkljczk.pl>
2026-07-29 15:22:13 +04:00
lain
e143e645d3 Merge pull request 'OpenRC: Automatically run migrations before starting pleroma' (#7680) from gitlab-mr-iid-4303 into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7680
2026-07-29 11:07:32 +00:00
lain
1dd6a345bf Merge pull request 'Respect activity restrictions in account statuses' (#7943) from mkljczk/pleroma:issue-2604-restrict-account-statuses into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7943
2026-07-29 06:44:26 +00:00
nicole mikołajczyk
5c85dadb29 Fix typo in spec
Signed-off-by: nicole mikołajczyk <git@mkljczk.pl>
2026-07-28 01:06:00 +02:00
lain
a45eb365ed Merge pull request 'Abort incomplete media proxy responses' (#7946) from lambadalambda/pleroma:fix/media-proxy-truncated-cache into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7946
2026-07-27 15:08:06 +00:00
lain
a22062a224 Merge pull request 'OAuth App: Fix test, optimize code.' (#7692) from gitlab-mr-iid-4315 into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7692
2026-07-27 14:42:53 +00:00
Lain Soykaf
bc999b3309
fix(media-proxy): abort truncated streams 2026-07-27 16:32:44 +04:00
lain
16581a2f6d Merge pull request 'Update Debian and Ubuntu installation requirements' (#7806) from gitlab-mr-iid-4429 into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7806
2026-07-27 12:16:12 +00:00
Lain Soykaf
3b71770cfa
docs: update Debian and Ubuntu requirements 2026-07-27 15:31:59 +04:00
Lain Soykaf
d30d205f0b
fix(oauth): preserve dependent app cleanup 2026-07-27 11:57:16 +04:00
Lain Soykaf
b4c624911c
Merge branch 'develop' into gitlab-mr-iid-4315 2026-07-27 11:34:31 +04:00
lain
8ab0e046b1 Merge pull request 'Allow creating accounts without a password in the AdminAPI, update docs' (#7937) from mkljczk/pleroma:admin-api-passwordless-user-creation into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7937
2026-07-27 07:17:14 +00:00
Lain Soykaf
2b32e3cf1f
fix(mastodon-api): restrict unauthenticated account statuses 2026-07-26 18:12:49 +04:00
Lain Soykaf
03e75d3b3e
fix(webhooks): merge develop and harden delivery 2026-07-26 17:00:14 +04:00
lain
b9ef1e2182 Merge pull request 'Restore preview cards tests and update their OpenAPI description' (#7444) from gitlab-mr-iid-4067 into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7444
2026-07-26 10:32:26 +00:00
lain
e210e16a37 Merge pull request 'MastoAPI: /api/{v1,v2}/admin/accounts, /api/v1/admin/reports' (#7842) from mkljczk/pleroma:mastodon-admin-api into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7842
2026-07-26 10:06:01 +00:00
Lain Soykaf
842e6bcaff
Merge remote-tracking branch 'origin/develop' into pr-7444-finish 2026-07-26 13:56:09 +04:00
Lain Soykaf
7a741736ea
Merge remote-tracking branch 'origin/develop' into pr-7444-finish 2026-07-26 13:20:50 +04:00
lain
3c916891f6 Merge branch 'develop' into paradedb-search-backend 2026-07-26 09:15:42 +00:00
lain
a5aad47cff Merge branch 'develop' into mastodon-admin-api 2026-07-26 08:52:01 +00:00
lain
d115b41848 Merge pull request 'Reject unsupported HTTP Message Signatures' (#7918) from activitypub-bot-federation into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7918
2026-07-26 08:50:16 +00:00
lain
f5dd75b1a3 Merge branch 'develop' into activitypub-bot-federation 2026-07-26 08:36:46 +00:00
Lain Soykaf
ce5c1b4c15
fix(activitypub): harden object normalization 2026-07-26 12:35:09 +04:00
Lain Soykaf
9df50eea82
fix: reject duplicate Signature headers 2026-07-26 12:26:35 +04:00
lain
51349f61f8 Merge branch 'develop' into mastodon-admin-api 2026-07-26 07:46:55 +00:00
Lain Soykaf
a9862dcaa0
chore: merge develop into ParadeDB backend 2026-07-26 11:24:37 +04:00
Lain Soykaf
42c100605e
fix(deps): pin Hackney to the connection-leak fix
An unpooled Hackney 4 connection that ends without a reusable socket -- a
body cut short by the peer, a bodyless 204/304, or a failed read -- parks
in its `closed` state forever, holding every refc binary it read.
read_full_body/2 hands back `socket = undefined`, so it never reaches the
reuse check; `closed(enter)` arms a stop timer only for pooled
connections; and an unpooled connection is owned by hackney_conn_sup, so
the owner-DOWN cleanup never fires.

Nothing here can work around it. Since 4.0 Hackney ignores `with_body`
and always returns a fully read binary, so a synchronous request never
yields a handle to close, and the short read still reports {:ok, body}.
Media proxy warming hits this whenever an attachment fetch is cut short
and the outbound proxy is used as a CONNECT tunnel, since tunnels are
never pooled.

Pin the fix, a single commit on top of the 4.7.2 tag, until it ships in a
release. While it is a git dep Hackney drops out of `mix deps.audit` and
`mix hex.outdated`, so this wants moving back to hex promptly.

benoitc/hackney#918, benoitc/hackney#919
2026-07-26 10:15:52 +04:00
Lain Soykaf
0615025f92
fix(http): enforce max_body again under Hackney 4
Hackney 4 ignores `with_body` and always returns a fully read binary, so
Tesla.Adapter.Hackney never reaches the clause that honours :max_body and
the option became a no-op. Only the gun path still enforced it, through
Pleroma.HTTP.Adapter.Gun. Pleroma.Web.RelMe relies on nothing else, so it
was fetching remote pages unbounded.

Add a middleware that applies the limit for every adapter: reject when
content-length already announces too much, and reject a body that came
back over the limit. Streaming bodies are left alone -- neither adapter
limits those and the caller owns the lease, so failing here on the header
would strand a connection RichMedia is still expected to release.

On the hackney path this bounds what callers are handed rather than peak
memory, since the adapter has read the body before any middleware runs.
2026-07-26 09:29:36 +04:00
Lain Soykaf
7d1cc56a78
Merge remote-tracking branch 'origin/develop' into audit-mix-audit-report
Conflict resolution notes:

- mix.lock: kept this branch's versions for cowlib, h2, hackney and hpax.
  Those upgrades are the point of the branch; develop is still on hackney
  1.20.1.

- .woodpecker/docker-armv7.yaml: accepted develop's deletion. It only
  existed here to build mdex_native on armv7, and mdex was already
  replaced with earmark again.

- lib/pleroma/reverse_proxy.ex: took develop's version. It independently
  grew request_with_constraints/5 and the invalid-status close, which
  supersede the equivalent fixes on this branch. Re-applied this branch's
  recv_timeout seeding, which develop does not have.

- lib/pleroma/gun/connection_pool/worker.ex and
  lib/pleroma/reverse_proxy/client/tesla.ex: took develop's versions. The
  gun pool rework (#7934) already guards the demonitor and makes
  release_conn/cancel_stream exit-safe, and it splits the Tesla client's
  graceful release from its abort path, so this branch's changes there are
  obsolete.

That leaves the client leak fix as a Hackney-only concern, which
stream_body/1 now handles the same way the gun client does.
2026-07-25 19:54:48 +04:00
Lain Soykaf
24bdd9774a
fix(reverse_proxy): release the HTTP client on every outcome
Three paths obtained a client ref and abandoned it without closing:
the content-length rejection in call/3, the invalid-status clause in
request/4, and the success branch of response/6.

Under Hackney 4 an abandoned ref is a permanent process leak. A conn
that finishes or errors without an explicit stop parks in `closed` or
`connected` and never terminates: closed/3 only arms its stop timer for
pooled conns, `connected` gets no state_timeout when idle_timeout is
infinity, and a non-pooled conn monitors hackney_conn_sup rather than
its caller, so the owner-DOWN cleanup never fires. Each parked process
pins every refc binary it read, which for proxied video is tens of MB.

Releasing on every outcome means the gun client must stop releasing in
stream_body/1, or the ref would be removed twice.

Hackney does reclaim a pooled connection itself for a response that
cannot carry a body (204, 304, HEAD), so those refs are marked and left
alone; stopping one would evict a connection another request may
already hold. The mark is gated on the request actually being pooled,
since a direct or proxy-tunnelled conn is never checked in and leaks
unless we stop it.
2026-07-25 18:46:43 +04:00
Lain Soykaf
9a6c2f909d
Merge remote-tracking branch 'origin/develop' into issue-3379-favourites-order 2026-07-25 10:31:57 +04:00
lain
cc1b95c88e Merge pull request 'Rework Gun connection pooling' (#7934) from issue-2263-gun-validation into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7934
2026-07-25 05:44:39 +00:00
Lain Soykaf
d5f48101b8
fix(media-proxy): safely detect extensionless images 2026-07-25 00:06:03 +04:00
lain
9b8aa2e2ee Merge pull request 'Woodpecker CI: Unify Docker builds, add arm32v7 to multi-arch images' (#7919) from woodpecker-armv7-fixups into develop
Reviewed-on: https://git.pleroma.social/pleroma/pleroma/pulls/7919
2026-07-24 18:12:46 +00:00