Compare commits

...

41 commits

Author SHA1 Message Date
74f94627f1 Merge remote-tracking branch 'origin/stable' into suyaplace 2023-09-25 21:48:20 +02:00
ebfb617b26 Update .woodpecker/build-amd64.yml
All checks were successful
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/push/build-arm64 Pipeline was successful
ci/woodpecker/push/build-amd64 Pipeline was successful
ci/woodpecker/push/docs Pipeline was successful
2023-08-26 13:41:52 +00:00
98a1092b5b Merge branch 'stable' of https://akkoma.dev/AkkomaGang/akkoma into suyaplace 2023-08-16 14:54:54 +02:00
0af8e93135 bump version
Some checks are pending
ci/woodpecker/tag/build-amd64 Pipeline is pending
ci/woodpecker/tag/build-arm64 Pipeline is pending
ci/woodpecker/tag/docs Pipeline is pending
ci/woodpecker/tag/test Pipeline is pending
ci/woodpecker/push/build-amd64 Pipeline was successful
ci/woodpecker/push/docs Pipeline was successful
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/push/build-arm64 Pipeline was successful
2023-08-16 10:44:57 +01:00
98a64ab145 Mix format 2023-08-16 00:35:08 +01:00
94d1af2c4c Disallow nil hosts in should_federate 2023-08-16 00:34:59 +01:00
aa3c5794c1 Revert "Stop exposing if a user blocks you over the API."
This reverts commit 1b560d547a.
2023-08-11 02:13:58 +02:00
43c5fd5db0 bullseye build (you owe me for this one)
All checks were successful
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/push/build-arm64 Pipeline was successful
ci/woodpecker/push/build-amd64 Pipeline was successful
ci/woodpecker/push/docs Pipeline was successful
2023-08-08 22:43:24 +01:00
c887dd4f2e Merge branch 'develop' into stable
Some checks failed
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/push/build-amd64 Pipeline was successful
ci/woodpecker/push/docs Pipeline was successful
ci/woodpecker/push/build-arm64 Pipeline was successful
ci/woodpecker/tag/test Pipeline was successful
ci/woodpecker/tag/build-amd64 Pipeline failed
ci/woodpecker/tag/docs unknown status
ci/woodpecker/tag/build-arm64 Pipeline failed
2023-08-06 15:13:13 +01:00
ba1ed37edf Merge branch 'develop' into stable
Some checks are pending
ci/woodpecker/tag/build-amd64 Pipeline is pending
ci/woodpecker/tag/build-arm64 Pipeline is pending
ci/woodpecker/tag/docs Pipeline is pending
ci/woodpecker/tag/test Pipeline is pending
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/push/build-amd64 Pipeline was successful
ci/woodpecker/push/docs Pipeline was successful
ci/woodpecker/push/build-arm64 Pipeline was successful
2023-08-05 14:12:59 +01:00
f1de9bd9ba Merge branch 'develop' into stable
Some checks are pending
ci/woodpecker/tag/build-amd64 Pipeline is pending
ci/woodpecker/tag/build-arm64 Pipeline is pending
ci/woodpecker/tag/docs Pipeline is pending
ci/woodpecker/tag/test Pipeline is pending
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/push/build-amd64 Pipeline was successful
ci/woodpecker/push/docs Pipeline was successful
ci/woodpecker/push/build-arm64 Pipeline was successful
2023-08-05 13:37:21 +01:00
a4bab7bdfa Merge branch 'develop' into stable 2023-08-05 13:36:43 +01:00
a7dbca885f Merge branch 'develop' into stable
Some checks failed
ci/woodpecker/tag/build-amd64 Pipeline is pending
ci/woodpecker/tag/build-arm64 Pipeline is pending
ci/woodpecker/tag/docs Pipeline is pending
ci/woodpecker/tag/test Pipeline is pending
ci/woodpecker/push/test Pipeline was successful
ci/woodpecker/push/build-amd64 Pipeline failed
ci/woodpecker/push/docs unknown status
ci/woodpecker/push/build-arm64 Pipeline failed
2023-08-05 13:26:54 +01:00
9d7c877de0 Merge branch 'develop' into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
2023-05-26 20:46:56 +01:00
39a878f530 Merge branch 'develop' into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
2023-05-26 12:07:05 +01:00
dcee1b109b Merge branch 'develop' into stable
Some checks are pending
ci/woodpecker/push/woodpecker Pipeline is pending
2023-05-26 12:05:11 +01:00
9a8373a3f5 Merge branch 'develop' into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
2023-05-23 14:10:19 +01:00
ccae7ef824 Merge branch 'develop' into stable
Some checks are pending
ci/woodpecker/tag/woodpecker Pipeline is pending
ci/woodpecker/push/woodpecker Pipeline was successful
2023-04-14 18:10:07 +01:00
8504878187 Merge branch 'develop' into stable 2023-04-14 18:09:32 +01:00
fef4bae006 Merge branch 'develop' into stable
Some checks are pending
ci/woodpecker/tag/woodpecker Pipeline is pending
ci/woodpecker/push/woodpecker Pipeline was successful
2023-03-11 18:25:07 +00:00
86dcf273c5 Merge branch 'develop' into stable
Some checks failed
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/tag/woodpecker Pipeline failed
2023-03-11 17:26:58 +00:00
36cb19dbf2 Merge branch 'develop' into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
2023-02-15 22:13:30 +00:00
71d08991ea Merge branch 'develop' into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
2023-02-11 11:19:42 +00:00
d756607112 Merge branch 'develop' into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
2023-02-11 10:59:04 +00:00
367bc9c818 Merge branch 'develop' into stable
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
2023-02-11 10:57:01 +00:00
81caf77223 Merge branch 'develop' into stable
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
ci/woodpecker/tag/woodpecker Pipeline is pending
2023-02-11 10:49:01 +00:00
551f92dd50 Merge branch 'develop' into stable 2023-02-11 10:43:22 +00:00
d9508474b6 Merge pull request 'clean-up docs to avoid version-mismatches in BE and FE in new installs (for stable)' (#378) from stefan230/akkoma:stable into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
Reviewed-on: #378
2022-12-19 10:59:34 +00:00
f676007b18 clean-up docs to avoid mismatches in BE and FE. Clearly state that stable-versions are installed
Some checks are pending
ci/woodpecker/pr/woodpecker Pipeline is pending
2022-12-16 17:23:31 +01:00
63f2d1cbef Merge branch 'develop' into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
2022-12-10 14:50:35 +00:00
f91b896731 Merge branch 'develop' into stable
Some checks are pending
ci/woodpecker/tag/woodpecker Pipeline is pending
ci/woodpecker/push/woodpecker Pipeline was successful
2022-11-12 15:34:19 +00:00
af90a4e51b Merge branch 'develop' into stable
Some checks are pending
ci/woodpecker/tag/woodpecker Pipeline is pending
ci/woodpecker/push/woodpecker Pipeline was successful
2022-10-14 12:49:46 +01:00
5e7be063c7 Merge branch 'develop' into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/tag/woodpecker Pipeline was successful
2022-10-08 12:12:52 +01:00
a1317bf541 use on-release tag
Some checks failed
ci/woodpecker/tag/woodpecker Pipeline was successful
ci/woodpecker/push/woodpecker Pipeline failed
2022-09-20 13:36:28 +01:00
a0dd670e68 ensure we use the same OTP for all releases 2022-09-20 13:34:50 +01:00
11d29d27b8 Ensure migrations succeed (#216)
Some checks failed
ci/woodpecker/tag/woodpecker Pipeline is pending
ci/woodpecker/push/woodpecker Pipeline failed
Co-authored-by: FloatingGhost <hannah@coffee-and-dreams.uk>
Reviewed-on: #216
2022-09-16 12:53:45 +01:00
44da806a77 Merge branch 'develop' into stable
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
ci/woodpecker/tag/woodpecker Pipeline was successful
2022-09-10 17:13:49 +01:00
d7c805b0bb Merge pull request '2022.09 stable' (#208) from develop into stable
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
Reviewed-on: #208
2022-09-10 16:06:18 +00:00
c52982e9c5 add finch outbound proxy support (#158)
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
Reviewed-on: #158
2022-08-24 16:03:17 +01:00
2e433e106f generate-keys-at-registration-time (#181)
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
Reviewed-on: #181
2022-08-24 15:39:30 +01:00
bfbe4e8dce Merge pull request 'stable release' (#160) from develop into stable
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
Reviewed-on: #160
2022-08-12 15:25:01 +00:00
10 changed files with 66 additions and 26 deletions

View file

@ -65,6 +65,33 @@ pipeline:
- export DEST=scaleway:akkoma-updates/$${CI_COMMIT_TAG:-"$CI_COMMIT_BRANCH"}/akkoma-amd64-ubuntu-jammy.zip
- /bin/sh /entrypoint.sh
debian-bullseye:
image: hexpm/elixir:1.15.4-erlang-25.3.2.5-debian-bullseye-20230612
<<: *on-release
environment:
MIX_ENV: prod
DEBIAN_FRONTEND: noninteractive
commands:
- apt-get update && apt-get install -y cmake libmagic-dev rclone zip imagemagick libmagic-dev git build-essential g++ wget
- *clean
- echo "import Config" > config/prod.secret.exs
- *setup-hex
- *mix-clean
- *tag-build
- mix deps.get --only prod
- mix release --path release
- zip akkoma-amd64-debian-bullseye.zip -r release
release-debian-bullseye:
image: akkoma/releaser
<<: *on-release
secrets: *scw-secrets
commands:
- export SOURCE=akkoma-amd64-debian-bullseye.zip
# AMD64
- export DEST=scaleway:akkoma-updates/$${CI_COMMIT_TAG:-"$CI_COMMIT_BRANCH"}/akkoma-amd64-debian-bullseye.zip
- /bin/sh /entrypoint.sh
# Canonical amd64-musl
musl:
image: hexpm/elixir:1.14.3-erlang-25.2.2-alpine-3.18.0

View file

@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## Unreleased
## Fixed
- Issue where a bad inbox URL could break federation
## 2023.08
## Added
@ -233,6 +238,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
## 2022.08
### Removed
- Non-finch HTTP adapters. `:tesla, :adapter` is now highly recommended to be set to the default.
## 2022.08
### Added
- extended runtime module support, see config cheatsheet
- quote posting; quotes are limited to public posts

View file

@ -115,13 +115,18 @@ defp allowed_instances do
def should_federate?(url) do
%{host: host} = URI.parse(url)
with allowed <- allowed_instances(),
with {nil, false} <- {nil, is_nil(host)},
allowed <- allowed_instances(),
false <- Enum.empty?(allowed) do
allowed
|> Pleroma.Web.ActivityPub.MRF.instance_list_from_tuples()
|> Pleroma.Web.ActivityPub.MRF.subdomains_regex()
|> Pleroma.Web.ActivityPub.MRF.subdomain_match?(host)
else
# oi!
{nil, true} ->
false
_ ->
quarantined_instances =
blocked_instances()

View file

@ -767,7 +767,7 @@ defp array_of_relationships do
"showing_reblogs" => true,
"followed_by" => true,
"blocking" => false,
"blocked_by" => false,
"blocked_by" => true,
"muting" => false,
"muting_notifications" => false,
"note" => "",
@ -783,7 +783,7 @@ defp array_of_relationships do
"showing_reblogs" => true,
"followed_by" => true,
"blocking" => false,
"blocked_by" => false,
"blocked_by" => true,
"muting" => true,
"muting_notifications" => false,
"note" => "",

View file

@ -13,10 +13,7 @@ defmodule Pleroma.Web.ApiSpec.Schemas.AccountRelationship do
description: "Relationship between current account and requested account",
type: :object,
properties: %{
blocked_by: %Schema{
type: :boolean,
description: "Represents being blocked by this user. Always false."
},
blocked_by: %Schema{type: :boolean},
blocking: %Schema{type: :boolean},
domain_blocking: %Schema{type: :boolean},
endorsed: %Schema{type: :boolean},

View file

@ -124,7 +124,14 @@ def render(
target,
&User.blocks_user?(&1, &2)
),
blocked_by: false,
blocked_by:
UserRelationship.exists?(
user_relationships,
:block,
target,
reading_user,
&User.blocks_user?(&1, &2)
),
muting:
UserRelationship.exists?(
user_relationships,

View file

@ -34,7 +34,9 @@ def perform(%Plug.Conn{assigns: assigns} = conn, %{scopes: scopes} = options) do
permissions = Enum.join(missing_scopes, " #{op} ")
error_message =
dgettext("errors", "Insufficient permissions: %{permissions}.", permissions: permissions)
dgettext("errors", "Insufficient permissions: %{permissions}.",
permissions: permissions
)
conn
|> put_resp_content_type("application/json")

View file

@ -4,7 +4,7 @@ defmodule Pleroma.Mixfile do
def project do
[
app: :pleroma,
version: version("3.10.3"),
version: version("3.10.4"),
elixir: "~> 1.14",
elixirc_paths: elixirc_paths(Mix.env()),
compilers: [:phoenix] ++ Mix.compilers(),

View file

@ -487,4 +487,11 @@ test "publish to url with with different ports" do
)
end
end
describe "should_federate/1" do
test "should not obliterate itself if the inbox URL is bad" do
url = "/inbox"
refute Pleroma.Web.ActivityPub.Publisher.should_federate?(url)
end
end
end

View file

@ -399,22 +399,7 @@ test "represent a relationship for the blocking and blocked user" do
expected =
Map.merge(
@blank_response,
%{following: false, blocking: true, blocked_by: false, id: to_string(other_user.id)}
)
test_relationship_rendering(user, other_user, expected)
end
test "blocks are not visible to the blocked user" do
user = insert(:user)
other_user = insert(:user)
{:ok, _user_relationship} = User.block(other_user, user)
expected =
Map.merge(
@blank_response,
%{following: false, blocking: false, blocked_by: false, id: to_string(other_user.id)}
%{following: false, blocking: true, blocked_by: true, id: to_string(other_user.id)}
)
test_relationship_rendering(user, other_user, expected)