summaryrefslogtreecommitdiff
path: root/test/fixtures
diff options
context:
space:
mode:
authorMark Felder <feld@feld.me>2024-07-25 14:33:51 -0400
committerMark Felder <feld@feld.me>2024-07-25 14:34:55 -0400
commita964368e31ddf8a22dd36bbf2aae51f7d91bbdaf (patch)
treeb75298233be2d9efca60b03418624a3354ccd9de /test/fixtures
parent1b9c887dbb8d87814f8d9cc11cfcbc8802348b22 (diff)
downloadpleroma-a964368e31ddf8a22dd36bbf2aae51f7d91bbdaf.tar.gz
pleroma-a964368e31ddf8a22dd36bbf2aae51f7d91bbdaf.zip
Add test to fetch and validate an activity that originally failed signature
Diffstat (limited to 'test/fixtures')
-rw-r--r--test/fixtures/bastianallgeier.json117
-rw-r--r--test/fixtures/denniskoch.json112
-rw-r--r--test/fixtures/receiver_worker_signature_activity.json62
3 files changed, 291 insertions, 0 deletions
diff --git a/test/fixtures/bastianallgeier.json b/test/fixtures/bastianallgeier.json
new file mode 100644
index 000000000..6b47e7db9
--- /dev/null
+++ b/test/fixtures/bastianallgeier.json
@@ -0,0 +1,117 @@
+{
+ "@context": [
+ "https://www.w3.org/ns/activitystreams",
+ "https://w3id.org/security/v1",
+ {
+ "Curve25519Key": "toot:Curve25519Key",
+ "Device": "toot:Device",
+ "Ed25519Key": "toot:Ed25519Key",
+ "Ed25519Signature": "toot:Ed25519Signature",
+ "EncryptedMessage": "toot:EncryptedMessage",
+ "PropertyValue": "schema:PropertyValue",
+ "alsoKnownAs": {
+ "@id": "as:alsoKnownAs",
+ "@type": "@id"
+ },
+ "cipherText": "toot:cipherText",
+ "claim": {
+ "@id": "toot:claim",
+ "@type": "@id"
+ },
+ "deviceId": "toot:deviceId",
+ "devices": {
+ "@id": "toot:devices",
+ "@type": "@id"
+ },
+ "discoverable": "toot:discoverable",
+ "featured": {
+ "@id": "toot:featured",
+ "@type": "@id"
+ },
+ "featuredTags": {
+ "@id": "toot:featuredTags",
+ "@type": "@id"
+ },
+ "fingerprintKey": {
+ "@id": "toot:fingerprintKey",
+ "@type": "@id"
+ },
+ "focalPoint": {
+ "@container": "@list",
+ "@id": "toot:focalPoint"
+ },
+ "identityKey": {
+ "@id": "toot:identityKey",
+ "@type": "@id"
+ },
+ "indexable": "toot:indexable",
+ "manuallyApprovesFollowers": "as:manuallyApprovesFollowers",
+ "memorial": "toot:memorial",
+ "messageFranking": "toot:messageFranking",
+ "messageType": "toot:messageType",
+ "movedTo": {
+ "@id": "as:movedTo",
+ "@type": "@id"
+ },
+ "publicKeyBase64": "toot:publicKeyBase64",
+ "schema": "http://schema.org#",
+ "suspended": "toot:suspended",
+ "toot": "http://joinmastodon.org/ns#",
+ "value": "schema:value"
+ }
+ ],
+ "attachment": [
+ {
+ "name": "Website",
+ "type": "PropertyValue",
+ "value": "<a href=\"https://bastianallgeier.com\" target=\"_blank\" rel=\"nofollow noopener noreferrer me\" translate=\"no\"><span class=\"invisible\">https://</span><span class=\"\">bastianallgeier.com</span><span class=\"invisible\"></span></a>"
+ },
+ {
+ "name": "Project",
+ "type": "PropertyValue",
+ "value": "<a href=\"https://getkirby.com\" target=\"_blank\" rel=\"nofollow noopener noreferrer me\" translate=\"no\"><span class=\"invisible\">https://</span><span class=\"\">getkirby.com</span><span class=\"invisible\"></span></a>"
+ },
+ {
+ "name": "Github",
+ "type": "PropertyValue",
+ "value": "<a href=\"https://github.com/bastianallgeier\" target=\"_blank\" rel=\"nofollow noopener noreferrer me\" translate=\"no\"><span class=\"invisible\">https://</span><span class=\"\">github.com/bastianallgeier</span><span class=\"invisible\"></span></a>"
+ }
+ ],
+ "devices": "https://mastodon.social/users/bastianallgeier/collections/devices",
+ "discoverable": true,
+ "endpoints": {
+ "sharedInbox": "https://mastodon.social/inbox"
+ },
+ "featured": "https://mastodon.social/users/bastianallgeier/collections/featured",
+ "featuredTags": "https://mastodon.social/users/bastianallgeier/collections/tags",
+ "followers": "https://mastodon.social/users/bastianallgeier/followers",
+ "following": "https://mastodon.social/users/bastianallgeier/following",
+ "icon": {
+ "mediaType": "image/jpeg",
+ "type": "Image",
+ "url": "https://files.mastodon.social/accounts/avatars/000/007/393/original/0180a20079617c71.jpg"
+ },
+ "id": "https://mastodon.social/users/bastianallgeier",
+ "image": {
+ "mediaType": "image/jpeg",
+ "type": "Image",
+ "url": "https://files.mastodon.social/accounts/headers/000/007/393/original/13d644ab46d50478.jpeg"
+ },
+ "inbox": "https://mastodon.social/users/bastianallgeier/inbox",
+ "indexable": false,
+ "manuallyApprovesFollowers": false,
+ "memorial": false,
+ "name": "Bastian Allgeier",
+ "outbox": "https://mastodon.social/users/bastianallgeier/outbox",
+ "preferredUsername": "bastianallgeier",
+ "publicKey": {
+ "id": "https://mastodon.social/users/bastianallgeier#main-key",
+ "owner": "https://mastodon.social/users/bastianallgeier",
+ "publicKeyPem": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA3fz+hpgVztO9z6HUhyzv\nwP++ERBBoIwSLKf1TyIM8bvzGFm2YXaO5uxu1HvumYFTYc3ACr3q4j8VUb7NMxkQ\nlzu4QwPjOFJ43O+fY+HSPORXEDW5fXDGC5DGpox4+i08LxRmx7L6YPRUSUuPN8nI\nWyq1Qsq1zOQrNY/rohMXkBdSXxqC3yIRqvtLt4otCgay/5tMogJWkkS6ZKyFhb9z\nwVVy1fsbV10c9C+SHy4NH26CKaTtpTYLRBMjhTCS8bX8iDSjGIf2aZgYs1ir7gEz\n9wf5CvLiENmVWGwm64t6KSEAkA4NJ1hzgHUZPCjPHZE2SmhO/oHaxokTzqtbbENJ\n1QIDAQAB\n-----END PUBLIC KEY-----\n"
+ },
+ "published": "2016-11-01T00:00:00Z",
+ "summary": "<p>Designer &amp; developer. Creator of Kirby CMS</p>",
+ "tag": [],
+ "type": "Person",
+ "url": "https://mastodon.social/@bastianallgeier"
+}
diff --git a/test/fixtures/denniskoch.json b/test/fixtures/denniskoch.json
new file mode 100644
index 000000000..7aa4de508
--- /dev/null
+++ b/test/fixtures/denniskoch.json
@@ -0,0 +1,112 @@
+{
+ "@context": [
+ "https://www.w3.org/ns/activitystreams",
+ "https://w3id.org/security/v1",
+ {
+ "Curve25519Key": "toot:Curve25519Key",
+ "Device": "toot:Device",
+ "Ed25519Key": "toot:Ed25519Key",
+ "Ed25519Signature": "toot:Ed25519Signature",
+ "EncryptedMessage": "toot:EncryptedMessage",
+ "PropertyValue": "schema:PropertyValue",
+ "alsoKnownAs": {
+ "@id": "as:alsoKnownAs",
+ "@type": "@id"
+ },
+ "cipherText": "toot:cipherText",
+ "claim": {
+ "@id": "toot:claim",
+ "@type": "@id"
+ },
+ "deviceId": "toot:deviceId",
+ "devices": {
+ "@id": "toot:devices",
+ "@type": "@id"
+ },
+ "discoverable": "toot:discoverable",
+ "featured": {
+ "@id": "toot:featured",
+ "@type": "@id"
+ },
+ "featuredTags": {
+ "@id": "toot:featuredTags",
+ "@type": "@id"
+ },
+ "fingerprintKey": {
+ "@id": "toot:fingerprintKey",
+ "@type": "@id"
+ },
+ "focalPoint": {
+ "@container": "@list",
+ "@id": "toot:focalPoint"
+ },
+ "identityKey": {
+ "@id": "toot:identityKey",
+ "@type": "@id"
+ },
+ "indexable": "toot:indexable",
+ "manuallyApprovesFollowers": "as:manuallyApprovesFollowers",
+ "memorial": "toot:memorial",
+ "messageFranking": "toot:messageFranking",
+ "messageType": "toot:messageType",
+ "movedTo": {
+ "@id": "as:movedTo",
+ "@type": "@id"
+ },
+ "publicKeyBase64": "toot:publicKeyBase64",
+ "schema": "http://schema.org#",
+ "suspended": "toot:suspended",
+ "toot": "http://joinmastodon.org/ns#",
+ "value": "schema:value"
+ }
+ ],
+ "attachment": [
+ {
+ "name": "GitHub",
+ "type": "PropertyValue",
+ "value": "<a href=\"https://github.com/pxlrbt/\" target=\"_blank\" rel=\"nofollow noopener noreferrer me\" translate=\"no\"><span class=\"invisible\">https://</span><span class=\"\">github.com/pxlrbt/</span><span class=\"invisible\"></span></a>"
+ },
+ {
+ "name": "Discord",
+ "type": "PropertyValue",
+ "value": "pxlrbt#6029"
+ }
+ ],
+ "devices": "https://phpc.social/users/denniskoch/collections/devices",
+ "discoverable": true,
+ "endpoints": {
+ "sharedInbox": "https://phpc.social/inbox"
+ },
+ "featured": "https://phpc.social/users/denniskoch/collections/featured",
+ "featuredTags": "https://phpc.social/users/denniskoch/collections/tags",
+ "followers": "https://phpc.social/users/denniskoch/followers",
+ "following": "https://phpc.social/users/denniskoch/following",
+ "icon": {
+ "mediaType": "image/jpeg",
+ "type": "Image",
+ "url": "https://media.phpc.social/accounts/avatars/109/364/097/179/042/485/original/6e770c7b3f5ef72d.jpg"
+ },
+ "id": "https://phpc.social/users/denniskoch",
+ "image": {
+ "mediaType": "image/jpeg",
+ "type": "Image",
+ "url": "https://media.phpc.social/accounts/headers/109/364/097/179/042/485/original/709da24705260c04.jpg"
+ },
+ "inbox": "https://phpc.social/users/denniskoch/inbox",
+ "indexable": true,
+ "manuallyApprovesFollowers": false,
+ "memorial": false,
+ "name": "Dennis Koch",
+ "outbox": "https://phpc.social/users/denniskoch/outbox",
+ "preferredUsername": "denniskoch",
+ "publicKey": {
+ "id": "https://phpc.social/users/denniskoch#main-key",
+ "owner": "https://phpc.social/users/denniskoch",
+ "publicKeyPem": "-----BEGIN PUBLIC KEY-----\nMIIBIjANBgkqhkiG9w0BAQEFAAOCAQ8AMIIBCgKCAQEA4dmcSlqLj18gPvuslkmt\nQTniZ8ybO4pgvMvPLYtBuTBUjo49vJ/8Sw6jB5zcKb1haqIdny7Rv/vY3kCdCXcP\nloh1I+jthEgqLT8JpZWGwLGwg9piFhrMGADmt3N8du7HfglzuZ8LlVpnZ8feCw7I\nS2ua/ZCxE47mI45Z3ed2kkFYKWopWWqFn2lan/1OyHrcFKtCvaVjRdvo0UUt2tgl\nvyJI4+zN8FnrCbsMtcbI5nSzfJIrOc4LeaGmLJh+0o2rwoOQZc2487XWbeyfhjsq\nPRBpYN7pfHWQDvzQIN075LHTf9zDFsm6+HqY7Zs5rYxr72rvcX7d9JcP6CasIosY\nqwIDAQAB\n-----END PUBLIC KEY-----\n"
+ },
+ "published": "2022-11-18T00:00:00Z",
+ "summary": "<p>🧑‍💻 Full Stack Developer<br />🚀 Laravel, Filament, Livewire, Vue, Inertia<br />🌍 Germany</p>",
+ "tag": [],
+ "type": "Person",
+ "url": "https://phpc.social/@denniskoch"
+}
diff --git a/test/fixtures/receiver_worker_signature_activity.json b/test/fixtures/receiver_worker_signature_activity.json
new file mode 100644
index 000000000..3c3fb3fd2
--- /dev/null
+++ b/test/fixtures/receiver_worker_signature_activity.json
@@ -0,0 +1,62 @@
+{
+ "@context": [
+ "https://www.w3.org/ns/activitystreams",
+ {
+ "atomUri": "ostatus:atomUri",
+ "blurhash": "toot:blurhash",
+ "conversation": "ostatus:conversation",
+ "focalPoint": {
+ "@container": "@list",
+ "@id": "toot:focalPoint"
+ },
+ "inReplyToAtomUri": "ostatus:inReplyToAtomUri",
+ "ostatus": "http://ostatus.org#",
+ "sensitive": "as:sensitive",
+ "toot": "http://joinmastodon.org/ns#",
+ "votersCount": "toot:votersCount"
+ }
+ ],
+ "atomUri": "https://chaos.social/users/distantnative/statuses/109336635639931467",
+ "attachment": [
+ {
+ "blurhash": "UAK1zS00OXIUxuMxIUM{?b-:-;W:Di?b%2M{",
+ "height": 960,
+ "mediaType": "image/jpeg",
+ "name": null,
+ "type": "Document",
+ "url": "https://assets.chaos.social/media_attachments/files/109/336/634/286/114/657/original/2e6122063d8bfb26.jpeg",
+ "width": 346
+ }
+ ],
+ "attributedTo": "https://chaos.social/users/distantnative",
+ "cc": [
+ "https://chaos.social/users/distantnative/followers"
+ ],
+ "content": "<p>Favorite piece of anthropology meta discourse.</p>",
+ "contentMap": {
+ "en": "<p>Favorite piece of anthropology meta discourse.</p>"
+ },
+ "conversation": "tag:chaos.social,2022-11-13:objectId=71843781:objectType=Conversation",
+ "id": "https://chaos.social/users/distantnative/statuses/109336635639931467",
+ "inReplyTo": null,
+ "inReplyToAtomUri": null,
+ "published": "2022-11-13T13:04:20Z",
+ "replies": {
+ "first": {
+ "items": [],
+ "next": "https://chaos.social/users/distantnative/statuses/109336635639931467/replies?only_other_accounts=true&page=true",
+ "partOf": "https://chaos.social/users/distantnative/statuses/109336635639931467/replies",
+ "type": "CollectionPage"
+ },
+ "id": "https://chaos.social/users/distantnative/statuses/109336635639931467/replies",
+ "type": "Collection"
+ },
+ "sensitive": false,
+ "summary": null,
+ "tag": [],
+ "to": [
+ "https://www.w3.org/ns/activitystreams#Public"
+ ],
+ "type": "Note",
+ "url": "https://chaos.social/@distantnative/109336635639931467"
+}