Compare commits
1178 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
c16d8a5912
|
|||
|
cb9eca0424
|
|||
|
d7858bab67
|
|||
|
5ce590029b
|
|||
|
4d92dec45c
|
|||
|
0a4e797eec
|
|||
|
38dffa414f
|
|||
|
eea56a742e
|
|||
|
56b7ee1d69
|
|||
|
3b564f7e7f
|
|||
|
93d2670063
|
|||
|
788165ac5b
|
|||
|
ec71125fa9
|
|||
|
adb231278c
|
|||
|
b3ae4ab36f
|
|||
|
3670fe0f10
|
|||
|
bb1a5155ed
|
|||
|
eb90dbbc5a
|
|||
|
a73d9f8ec0
|
|||
|
4c8f2e3251
|
|||
|
bc9d2ab8ce
|
|||
|
8bc01f1b97
|
|||
|
200cf3ec80
|
|||
|
d910d837eb
|
|||
|
56d1f14206
|
|||
|
a7c8a8d2ee
|
|||
|
411c71dae0
|
|||
|
a8430604f9
|
|||
|
fe37d219b7
|
|||
|
bc1ebc799a
|
|||
|
37940ef12a
|
|||
|
5d0469e187
|
|||
|
7ad7ab53a6
|
|||
|
6b0343d3dc
|
|||
|
f541580281
|
|||
|
6e7eedc026
|
|||
|
5d5bda7925
|
|||
|
48e66580c3
|
|||
|
836449e3f4
|
|||
|
804dd029b1
|
|||
|
e13928b03f
|
|||
|
5c14236603
|
|||
|
738ed357bf
|
|||
|
0876ab9b74
|
|||
|
7071399cd8
|
|||
|
af23df6e48
|
|||
|
e7e7cc424b
|
|||
|
56ad8f60ea
|
|||
|
026dd3eb01
|
|||
|
72baf0ca5c
|
|||
|
82cb8c7ff9
|
|||
|
a266177628
|
|||
|
2474c7f97c
|
|||
|
1716afd66c
|
|||
|
78a3cd6dd2
|
|||
|
d655840e85
|
|||
|
2e3e988125
|
|||
|
2a94ed5171
|
|||
|
0948810993
|
|||
|
689965c582
|
|||
|
ac82fdb8c8
|
|||
|
d94baab877
|
|||
|
0a179acb13
|
|||
|
33686b83e3
|
|||
|
09abe79f6a
|
|||
|
b0b227f36b
|
|||
|
62a45317a9
|
|||
|
f727882b93
|
|||
|
ba6d6ef97a
|
|||
|
c904826c49
|
|||
|
595aa45378
|
|||
|
a481b1b82f
|
|||
|
2df31e4244
|
|||
|
9c1eb8e5bc
|
|||
|
4d095aa333
|
|||
|
fb62ce7735
|
|||
|
b258df56c9
|
|||
|
2bf54099f9
|
|||
|
eb89d9223a
|
|||
|
87a54625aa
|
|||
|
30b2c0a0b4
|
|||
|
59c34ada40
|
|||
|
67a522753e
|
|||
|
e6338e8a5a
|
|||
|
cb7eef943c
|
|||
|
7a56e7882e
|
|||
|
b0085c2ab0
|
|||
|
d3f990691e
|
|||
|
46a773cfe9
|
|||
|
f5fb5d8a98
|
|||
|
4d87ca7cca
|
|||
|
e16a04bd5a
|
|||
|
d68b39f80f
|
|||
|
b7360f1f91
|
|||
|
5f094aca4b
|
|||
|
6010c17900
|
|||
|
2ee6b3514c
|
|||
|
8c83ee9b88
|
|||
|
18c81503f1
|
|||
|
53137aed3f
|
|||
|
b2aa8b8ec1
|
|||
|
b13a4f5bcf
|
|||
|
8fe703ef6d
|
|||
|
2297fb3c47
|
|||
|
580663dcda
|
|||
|
de20803119
|
|||
|
fb51d2076f
|
|||
|
d8485954fa
|
|||
|
d7746d14e4
|
|||
|
648d5225f6
|
|||
|
9d4d0f2e48
|
|||
|
fe386163f4
|
|||
|
ac2cee10e5
|
|||
|
9c370647dd
|
|||
|
7516e197fe
|
|||
|
71c372ab6c
|
|||
|
25f23f7f93
|
|||
|
51853698b9
|
|||
|
39ed5393ab
|
|||
|
782b3f1b08
|
|||
|
3ef2f13dd3
|
|||
|
36b0f55a47
|
|||
|
bc7a6e865e
|
|||
|
2ff60fc4ff
|
|||
|
ea93aa144e
|
|||
|
e4cd0c99df
|
|||
|
dff84dde58
|
|||
|
16c7b7e764
|
|||
|
240509ceff
|
|||
|
91da9768c1
|
|||
|
60b8e2bcad
|
|||
|
504e4d55ad
|
|||
|
38a15bb62a
|
|||
|
9d03faf594
|
|||
|
fd79c11d18
|
|||
|
c4ac256896
|
|||
|
c1fc8ea3fe
|
|||
|
29574ada88
|
|||
|
7369f5d88c
|
|||
|
5b3c138ebe
|
|||
|
562bdf62e9
|
|||
|
a73672925e
|
|||
|
c585522c35
|
|||
|
6aba84e506
|
|||
|
c6f104afc7
|
|||
|
4181fd0090
|
|||
|
84bca9601a
|
|||
|
31b83b2d27
|
|||
|
dfcb089c69
|
|||
|
fe365e8c6d
|
|||
|
b5262137ad
|
|||
|
11e93314c7
|
|||
|
c8658bc0ca
|
|||
|
b2f689693b
|
|||
|
33ec0b1d9a
|
|||
|
f698385494
|
|||
|
6ecdf89d20
|
|||
|
683f686540
|
|||
|
6a115ab1cc
|
|||
|
d05283d3b1
|
|||
|
b9653e7264
|
|||
|
87d1c8b320
|
|||
|
22eb54b61f
|
|||
|
a90ad2debc
|
|||
|
2f00bf660d
|
|||
|
322a93324c
|
|||
|
c3a3be0807
|
|||
|
27c7c8f039
|
|||
|
a7960da362
|
|||
|
64ab30b0a9
|
|||
|
935e6d5833
|
|||
|
938b128b1e
|
|||
|
c9764daa20
|
|||
|
7bc44e8f06
|
|||
|
4a7ff96a8b
|
|||
|
e759d5f46c
|
|||
|
f5ca6a37bf
|
|||
|
5fc8859f3b
|
|||
|
e30e7adbe2
|
|||
|
68be4db160
|
|||
|
aa91e376ca
|
|||
|
caffb85588
|
|||
|
521b192205
|
|||
|
77ac0428ea
|
|||
|
88c8227c66
|
|||
|
b20d8350a8
|
|||
|
98b27bed0e
|
|||
|
3a7d8b1a0d
|
|||
|
b4801d6af6
|
|||
|
aab5b957af
|
|||
|
43d706a184
|
|||
|
98df275f88
|
|||
|
5663df6ef1
|
|||
|
e996a0c95f
|
|||
|
a090e93f57
|
|||
|
c69034c071
|
|||
|
369ea6cf5b
|
|||
|
2e371b5296
|
|||
|
2e9d61bcfa
|
|||
|
9c2b5b0dfa
|
|||
|
3b40f515b3
|
|||
|
5ee61dbef2
|
|||
|
b151ef6686
|
|||
|
ff934d0f08
|
|||
|
abe5ded896
|
|||
|
f1d72a5215
|
|||
|
864cbe73b7
|
|||
|
108a6da074
|
|||
|
f9a09599c9
|
|||
|
9067dadd3e
|
|||
|
09f8df1e78
|
|||
|
2c5f246c55
|
|||
|
a66c6ea654
|
|||
|
3ad4bb4518
|
|||
|
53f0dcb825
|
|||
|
557f5a2389
|
|||
|
78f14f890f
|
|||
|
77b2effb34
|
|||
|
f02b4abf65
|
|||
|
3f37c4f761
|
|||
|
5deb910fa4
|
|||
|
f50a19f573
|
|||
|
98c8a356e8
|
|||
|
d0c16ea08f
|
|||
|
f2c1b2a531
|
|||
|
3061f0c5a9
|
|||
|
98f7f33c65
|
|||
|
d9af5d32fd
|
|||
|
f2031697ec
|
|||
|
9b85b7573c
|
|||
|
4fb739b33b
|
|||
|
c03ba3bc3a
|
|||
|
fc65440420
|
|||
|
7b85533184
|
|||
|
77d9eb60c6
|
|||
|
4d8953cd22
|
|||
|
fafa460fe8
|
|||
|
faf3a677d4
|
|||
|
0f644a0234
|
|||
|
18d16fdd57
|
|||
|
18e890d63c
|
|||
|
9c5e50c16a
|
|||
|
96a2c8182e
|
|||
|
56b27c3e82
|
|||
|
ad4bf94195
|
|||
|
b77a832d8a
|
|||
|
5e61805db7
|
|||
|
35b96b0bd2
|
|||
|
c8ad791ff3
|
|||
|
1e908502dc
|
|||
|
715ce1a368
|
|||
|
548c9963ee
|
|||
|
db5199438a
|
|||
|
4409a6fb1e
|
|||
|
26a24b0e41
|
|||
|
9b948d259b
|
|||
|
1f713b5b2b
|
|||
|
f92cfafda4
|
|||
|
fa208b44d7
|
|||
|
94adecafbb
|
|||
|
0303ef4a93
|
|||
|
c2b18ce10b
|
|||
|
0767bb53ce
|
|||
|
b233f9a410
|
|||
|
256024fb46
|
|||
|
4a80aaf24d
|
|||
|
aafd160c44
|
|||
|
4a800725e3
|
|||
|
24791b3293
|
|||
|
3ac263d483
|
|||
|
2445d8adf8
|
|||
|
d4f95bbbf4
|
|||
|
943e4b7b5c
|
|||
|
7edc02a1d3
|
|||
|
3f9881e943
|
|||
|
50c25e919c
|
|||
|
99fb08dd55
|
|||
|
e43bc6b8a8
|
|||
|
c247cdf81c
|
|||
|
3ffa730505
|
|||
|
1cc34d3073
|
|||
|
96a919cc4e
|
|||
|
e7e3bfcadf
|
|||
|
a8617a5040
|
|||
|
d94f8d004f
|
|||
|
d93b066979
|
|||
|
320664a547
|
|||
|
98f4698d5b
|
|||
|
82397dd087
|
|||
|
4ec10ceb47
|
|||
|
4b03b45a0d
|
|||
|
7a72d32649
|
|||
|
5152dd13ea
|
|||
|
fd377aa7af
|
|||
|
67044148f1
|
|||
|
92bc43e4df
|
|||
|
a1a7b34c86
|
|||
|
40c0e052cf
|
|||
|
9a75228e38
|
|||
|
a9fd75cc45
|
|||
|
a713b30d93
|
|||
|
e516f0a862
|
|||
|
429b966c4b
|
|||
|
f14da0d3a2
|
|||
|
d201182bd2
|
|||
|
6f6422c15e
|
|||
|
9f6ae639ee
|
|||
|
35f4d7d885
|
|||
|
a9c8f49797
|
|||
|
5e9341a19c
|
|||
|
645a6dca93
|
|||
|
ea8e7ead2d
|
|||
|
5f2f083d72
|
|||
|
5cf40e27de
|
|||
|
1ab7295918
|
|||
|
07f191171c
|
|||
|
4a5dac248e
|
|||
|
3b983a6444
|
|||
|
4607b77355
|
|||
|
7957e4894a
|
|||
|
f94f80c375
|
|||
|
74fa2215a6
|
|||
|
0d11435feb
|
|||
|
e22598b0a6
|
|||
|
84cfe643f5
|
|||
|
05ac04e9a2
|
|||
|
66f283d6e8
|
|||
|
c779c7523c
|
|||
|
ac7cb29afe
|
|||
|
935aa77223
|
|||
|
24e5b3b824
|
|||
|
0391893b32
|
|||
|
b8d24876c8
|
|||
|
0493661f9a
|
|||
|
b40afde00f
|
|||
|
78a4022531
|
|||
|
8a291c80b7
|
|||
|
1395d65b76
|
|||
|
eb4942e0ed
|
|||
|
f254cfa81e
|
|||
|
4927795260
|
|||
|
e4019dadc8
|
|||
|
5e7d77e1a1
|
|||
|
bfcbed035c
|
|||
|
5ebefae961
|
|||
|
d4758674bb
|
|||
|
f5f1ddc0ea
|
|||
|
2720b59485
|
|||
|
29b1ac7fce
|
|||
|
83ca5551ad
|
|||
| 611cb024a9 | |||
|
74fb56891d
|
|||
|
ac4fa5eb85
|
|||
|
8857718709
|
|||
|
dd17b2b9c1
|
|||
|
848439f664
|
|||
|
f83117424d
|
|||
|
8c19c32c76
|
|||
|
d62b2bed80
|
|||
|
5a23eb1768
|
|||
|
5f6e4763d3
|
|||
|
580c36fb89
|
|||
|
6c25af3b30
|
|||
|
a1da72d447
|
|||
|
ab4120cc22
|
|||
|
52eff0fa25
|
|||
|
beeb28abf2
|
|||
|
c0ab3837ac
|
|||
|
59d38c0d8d
|
|||
|
bd2247ce86
|
|||
|
da2d3f7f17
|
|||
|
7497b77384
|
|||
|
f542d9fa97
|
|||
|
e70439870e
|
|||
|
d764b042fe
|
|||
|
a76b97d1d2
|
|||
|
cfbe6e580b
|
|||
|
f08b9e057f
|
|||
|
0509f37c96
|
|||
|
a7dc9ac6fa
|
|||
|
caf2f5f1f6
|
|||
|
12b79af3a2
|
|||
|
88f149584e
|
|||
|
877001b802
|
|||
| fec28f6223 | |||
| 85005ff9c3 | |||
| e3c92a3c55 | |||
| 9e9fbc5d6a | |||
| 8d1d836b52 | |||
| bc60ce5d42 | |||
| c093123e3a | |||
| 3de73538c7 | |||
| ba8d5cee09 | |||
|
5ee2e70442
|
|||
|
53a3a32907
|
|||
|
9a628779d9
|
|||
|
b60bd63d0c
|
|||
|
01cc71fd47
|
|||
|
a2b0cd0b6a
|
|||
|
7f971bcee3
|
|||
|
7de98a1731
|
|||
|
b52eb95b14
|
|||
|
b3ef7d6ad0
|
|||
|
d28c11940d
|
|||
|
504322c2dd
|
|||
|
a07ec3ca36
|
|||
| d96691e920 | |||
|
6273b2d917
|
|||
|
ab90d244b5
|
|||
|
dc6af6d9e5
|
|||
|
0ca801d963
|
|||
|
3edcdd72af
|
|||
|
402bb3fe04
|
|||
|
8ba55eb1be
|
|||
|
983ae2a1fc
|
|||
|
6fc94001b3
|
|||
|
44dbcfdc94
|
|||
|
b57caf56db
|
|||
|
dbcd1b6d36
|
|||
|
a8055de910
|
|||
|
49b15e7674
|
|||
|
e2369c40db
|
|||
|
44c5d91620
|
|||
|
7a5a2407b7
|
|||
|
234434f102
|
|||
|
9c3b228d02
|
|||
|
82682cae9a
|
|||
|
fcbd5fe680
|
|||
|
ad91b17af7
|
|||
|
24fa637329
|
|||
|
926ae5402f
|
|||
|
1a37d384e6
|
|||
|
d4cf598f69
|
|||
|
0106c08891
|
|||
|
9697def808
|
|||
|
6572875229
|
|||
|
66590b9079
|
|||
|
08b9604b55
|
|||
|
0602bbd277
|
|||
|
76e7ba7898
|
|||
|
6e6616b236
|
|||
|
071d51b25e
|
|||
|
a958362461
|
|||
|
6749bb00fe
|
|||
|
11fb20c673
|
|||
|
a7990f83db
|
|||
|
5f4cdf7937
|
|||
|
3330ca14dd
|
|||
|
1719b1c8fe
|
|||
|
3c2c51bfaf
|
|||
|
239d6750ff
|
|||
|
8b0c91977a
|
|||
|
f74cca8464
|
|||
|
08091d51bf
|
|||
|
481190811b
|
|||
|
4b32b65d1c
|
|||
|
50ac7109bb
|
|||
|
62da279c71
|
|||
|
fde6dbf891
|
|||
|
613bf4fb42
|
|||
|
00ae586016
|
|||
|
ea0d132dce
|
|||
|
aa2df1e847
|
|||
|
50672795f3
|
|||
|
383de9568d
|
|||
|
01fa228e45
|
|||
|
1e71ad33a6
|
|||
|
92c0260ecd
|
|||
|
0a161ad255
|
|||
|
c003f27b9a
|
|||
|
19db8309c4
|
|||
|
aa72ce08e8
|
|||
|
4639b00b86
|
|||
|
cc5460ea55
|
|||
|
eafac811e6
|
|||
|
e3be691596
|
|||
|
aa180a1358
|
|||
|
c2707b8af1
|
|||
|
62fd0500f3
|
|||
|
eeae865cc8
|
|||
|
cdf1413fe0
|
|||
|
327b4c04f1
|
|||
|
bd903ce29c
|
|||
|
1b8ecb15ce
|
|||
|
d4e380a97a
|
|||
|
126048b4fa
|
|||
|
8bec18813d
|
|||
|
1ae81794b1
|
|||
|
2a7d12de48
|
|||
|
64c60ead48
|
|||
| 001549b190 | |||
| 4595865ad3 | |||
|
|
1834643167 | ||
|
|
0e816eaa3e | ||
|
|
7c1f24b824 | ||
|
c6594ea2ce
|
|||
|
3bec6e683e
|
|||
|
83e92e2eed
|
|||
|
|
b7d44d96ba | ||
|
a83b929d42
|
|||
|
9423affa75
|
|||
|
cda23db609
|
|||
|
61074bc5a3
|
|||
|
5feafa9255
|
|||
|
e604577c1f
|
|||
|
af0ddd1273
|
|||
|
8a6bb34808
|
|||
|
4ef8445c77
|
|||
|
ec39ad6ca3
|
|||
|
eabb3154f1
|
|||
|
910bf20eef
|
|||
|
5efa9b2ae8
|
|||
|
dd3e39e891
|
|||
|
b6896ded23
|
|||
|
f28a73ff9c
|
|||
|
a014b64235
|
|||
|
7e0e7c20d7
|
|||
|
389fa515ba
|
|||
|
681ead02eb
|
|||
|
8d1c145b0b
|
|||
|
51b4754182
|
|||
|
8a2b321701
|
|||
|
f685a7a249
|
|||
|
76009147e9
|
|||
|
ce12f28e56
|
|||
|
3604373a1e
|
|||
|
9704a4c2c7
|
|||
|
67def56ad1
|
|||
|
1be33916af
|
|||
|
e8ff1bfd22
|
|||
|
3ae56f3d89
|
|||
|
707143e998
|
|||
|
1fd34eb2a3
|
|||
|
d7ca41e946
|
|||
|
ad9fb0719a
|
|||
|
e2d315afd4
|
|||
|
6124dbfd79
|
|||
|
5327f04ec0
|
|||
|
41c56a2319
|
|||
|
f9d033542e
|
|||
|
91784e65e6
|
|||
|
9d39c6a825
|
|||
|
537e49f1a4
|
|||
|
75bbd4df71
|
|||
|
6ef4580d93
|
|||
|
6ffd498761
|
|||
|
27157e7cc1
|
|||
|
bbb07d574a
|
|||
|
c660a419e2
|
|||
|
c3f61467c8
|
|||
|
9bc47df452
|
|||
|
9ef8ca4d45
|
|||
|
b55cbd08d1
|
|||
|
8c6bd0feaa
|
|||
|
7dd4b20628
|
|||
|
fec0cb7640
|
|||
|
75deb04a2b
|
|||
|
7c7ed21a96
|
|||
|
a201f20793
|
|||
|
598c51bc1a
|
|||
|
e1ea61c5f1
|
|||
|
ac424bde36
|
|||
|
b43b70df3f
|
|||
|
4321aa621a
|
|||
|
d5d275fb43
|
|||
|
6bb3307144
|
|||
|
391604d4a2
|
|||
|
1d9361c12f
|
|||
|
a129b9cdd0
|
|||
|
3bf815ac61
|
|||
|
77bae4d6fd
|
|||
|
0a301c4c9b
|
|||
|
27b390a51c
|
|||
|
018386d14e
|
|||
|
3825d7c6c7
|
|||
|
bf930291e4
|
|||
|
a8c4988790
|
|||
|
28dd204b1a
|
|||
|
3cbc1a59a7
|
|||
|
277e9ae3d1
|
|||
|
27b3ca25b7
|
|||
|
f871cd3b62
|
|||
|
a8a59ee30c
|
|||
|
2cd1416a13
|
|||
|
6be7dfbc61
|
|||
|
1abbd85614
|
|||
|
31ac5ad07c
|
|||
|
ae2ba495e9
|
|||
|
637aa44548
|
|||
|
44dbfc36d9
|
|||
|
5dbe7371cb
|
|||
|
6c91093198
|
|||
|
3f640b7898
|
|||
|
7db164fda6
|
|||
|
6df1d96cc9
|
|||
|
122a796f8c
|
|||
|
fbc7812a16
|
|||
|
0b1a23e81a
|
|||
|
c87e6cfe07
|
|||
|
53d51b8a0e
|
|||
|
337ae39e08
|
|||
|
8fe3a664a6
|
|||
|
3bfc0b8181
|
|||
| ac2951479b | |||
| 2bfd13d843 | |||
| 28db6f9f01 | |||
|
a4f7b8415d
|
|||
|
2255d3d591
|
|||
|
97792ae734
|
|||
|
a5d13250cc
|
|||
|
de9e235d0c
|
|||
|
56fb5451cd
|
|||
|
870de961f5
|
|||
|
22bf6d1c33
|
|||
|
5b62f89531
|
|||
|
b1326d8f04
|
|||
|
fffca4a78c
|
|||
|
42bd7f97cb
|
|||
| 6377856ae0 | |||
| 0f1c52b9e3 | |||
| 6ed6f60fbc | |||
| e65a414065 | |||
| 214d5c4a53 | |||
| fe33931304 | |||
| 113309257e | |||
| b95a8b2ed2 | |||
|
|
e922971a5e | ||
| 9d5b71bead | |||
| 890efa2efb | |||
| 674097e425 | |||
|
3379dcb7f3
|
|||
| eb5a849e1f | |||
|
4981a23e8e
|
|||
|
c64d4bacb6
|
|||
|
838d18013b
|
|||
|
3f7902e463
|
|||
|
54560ad5d8
|
|||
|
0c729db639
|
|||
|
1fbaac8d88
|
|||
|
b9dc724f0b
|
|||
|
a2cc55696f
|
|||
|
e79f857feb
|
|||
|
affba29c04
|
|||
|
756746b144
|
|||
|
28b6eade48
|
|||
| 1de7ef8c96 | |||
| 67eac5dcf5 | |||
|
7a44bfa075
|
|||
|
1c2f25a152
|
|||
|
be26ea280e
|
|||
|
b4996d069f
|
|||
|
bf4892b34d
|
|||
|
5f84751fd5
|
|||
|
457d1bac60
|
|||
|
02ec11845b
|
|||
|
612f1bf004
|
|||
|
fd80b713ad
|
|||
|
508805368c
|
|||
|
98eb28a4ec
|
|||
|
d1a2f59dd1
|
|||
|
bb9adb963a
|
|||
|
83e40cd860
|
|||
|
c06fb12f6a
|
|||
|
6600cf4df8
|
|||
|
4293daaa2f
|
|||
|
866674ddde
|
|||
|
27d478ba4f
|
|||
|
cccade763f
|
|||
|
f760b85186
|
|||
|
e68c5f4f92
|
|||
|
b0f3b6b5c3
|
|||
|
cb2af379fa
|
|||
|
38f8103265
|
|||
|
06bb18bdaa
|
|||
|
84c38500d0
|
|||
|
9529bbf08b
|
|||
|
8baf77bcf7
|
|||
|
b2ac5fbef2
|
|||
|
c79b1d7aab
|
|||
|
|
4f55a8209c | ||
|
|
ace302111a | ||
|
|
1391fa0dde | ||
|
|
cbdc7acdcd | ||
|
|
b80d91825a | ||
|
|
1a703b7eba | ||
|
|
3621ea7744 | ||
|
|
b638343f02 | ||
|
|
269a64cabb | ||
|
406e5187a8
|
|||
|
9bdd08d8dd
|
|||
|
d737232dcf
|
|||
|
c9d751479e
|
|||
|
a2c2bfe585
|
|||
|
c7f9da0dee
|
|||
|
|
a243cda1df | ||
|
|
7b238f32fd | ||
|
313af28d7f
|
|||
|
c64e1e208c
|
|||
|
c9b07a9a2a
|
|||
| 55c0e355f1 | |||
| be414891ec | |||
| 787876ab6a | |||
|
8578cde620
|
|||
|
14d55d45a8
|
|||
|
724391584e
|
|||
| 3a5e45808a | |||
|
488055955c
|
|||
|
|
313ebc64cc | ||
|
|
1ed8b1d0c1 | ||
| 4af816d931 | |||
| 1c058a4323 | |||
| 461ed1fcda | |||
|
5363afa558
|
|||
|
f0d2737da8
|
|||
|
1f2f80aa3e
|
|||
|
240a872e65
|
|||
| c1ec6f0849 | |||
| ab42686d4d | |||
|
c9727e92b8
|
|||
|
9b8768061d
|
|||
|
0949f0da54
|
|||
|
215ca705ac
|
|||
|
03457af04a
|
|||
|
73c6a1febf
|
|||
|
ba8d30bcde
|
|||
|
8449658b47
|
|||
|
c7f417234e
|
|||
|
6c847ee1e1
|
|||
|
18ad4d376e
|
|||
|
c4d5ba5c9d
|
|||
|
1069669049
|
|||
|
aa648fec62
|
|||
|
541900673a
|
|||
|
265502ffd0
|
|||
|
3bd79350d1
|
|||
|
5294d1fb23
|
|||
|
ec1269dcf1
|
|||
|
edb0a25f34
|
|||
|
7cd10118cc
|
|||
|
fcddc8f345
|
|||
|
1cc34240da
|
|||
|
013f7f02bc
|
|||
|
4e79e4100f
|
|||
|
feda1f067f
|
|||
|
fe0e192a43
|
|||
|
93df294142
|
|||
|
78d65c39f3
|
|||
|
18b0dbd797
|
|||
|
80cc8cbb40
|
|||
|
646e95a9fc
|
|||
|
6f9d51673b
|
|||
|
f8c6887769
|
|||
|
cd2a507b7f
|
|||
|
3cafce00a2
|
|||
|
837f3fbe98
|
|||
|
ca7cc5d7ee
|
|||
|
ef2c14daa2
|
|||
|
3a17837cc6
|
|||
|
2617a64acf
|
|||
|
afe1e12a3b
|
|||
|
be80f5ff85
|
|||
|
3281d69eba
|
|||
|
77b6ce9937
|
|||
|
39275f61b5
|
|||
|
72193ba8f3
|
|||
|
98dd9b6617
|
|||
|
a22b94a263
|
|||
|
9c75eafdb3
|
|||
|
28fda3d0c7
|
|||
|
187c2ea43e
|
|||
|
ae7d967461
|
|||
|
1ce71f1fa1
|
|||
|
9b68808c77
|
|||
|
|
99b7bf8199 | ||
|
|
eb9bb73c31 | ||
|
|
a8c3830d67 | ||
|
|
07a5a19141 | ||
| ecc100ac45 | |||
| 573b76d3ff | |||
| f7dad5e419 | |||
| 9f2f1c0848 | |||
| 580d9fd979 | |||
| 3b375abc09 | |||
| c527b5e67c | |||
| e9f09bbe54 | |||
| 3aece9316c | |||
| a61c889c6c | |||
| 0dd3221a56 | |||
| 66918521f8 | |||
| bb1846e462 | |||
| a976a6eaf4 | |||
| 4252f66fd3 | |||
| f2d780b48f | |||
| 300541f9bb | |||
| 43787bb813 | |||
| 3417c51a3b | |||
| f98e603e82 | |||
| c9b71701c8 | |||
| 28e98488f1 | |||
| b4d476613e | |||
| b48a1aac44 | |||
| 596d212593 | |||
| 54f290327e | |||
| 16f248ceab | |||
| 856d811187 | |||
| d07b194c04 | |||
| 2554b58be6 | |||
| a627b5838e | |||
| c479a9f381 | |||
| 02057e663b | |||
| 6501594100 | |||
| c6599edc3d | |||
| 709a0620b6 | |||
| f9b2a96c7c | |||
| 4dca6189cb | |||
| c7f5b63fe5 | |||
| 96c2f45c85 | |||
| 06f04eb3a5 | |||
| 8af97e43b4 | |||
| d1e8234b93 | |||
| a03d6015a6 | |||
| 246ac52d0a | |||
| abf395ff9a | |||
| 4fdc8eb1d0 | |||
| d7dcde898c | |||
| f85484d3ed | |||
| 5060bd30c9 | |||
| 3959f2260b | |||
| 6f4f1216ad | |||
| f401ffbf81 | |||
| 0251697951 | |||
| 178c12b893 | |||
| 4beda9200e | |||
| 7dfe411053 | |||
| 1232318a5d | |||
|
|
56f41b6c0e | ||
|
|
3ea717d25a | ||
| 1fe4889460 | |||
| cdf2722268 | |||
| a127b5bace | |||
| b2097cf044 | |||
| 701f29748d | |||
| 9e40ed4600 | |||
| c90e6fe661 | |||
| 569483300d | |||
| bab602d98b | |||
| b4f2bb803a | |||
| 03bfed6f46 | |||
| f98e5a0aec | |||
| 3d473e2fec | |||
| 0b6efa373a | |||
| 9b60e96cde | |||
| 81cd9b2082 | |||
| 923d5d7514 | |||
| 7169aff841 | |||
| fac3efb50c | |||
| e809aadaea | |||
| f33b569221 | |||
| e5f2e2d146 | |||
| 11368d064f | |||
| 246b163aec | |||
| 10e0d2fe5f | |||
| 99e10cb612 | |||
| 1db6941431 | |||
| 8370da4fe3 | |||
| 2bdf7029e9 | |||
| 86682a3a9a | |||
| c3925e81b5 | |||
| 6f1f488490 | |||
| 31b2de2e46 | |||
| 412dcfa62a | |||
| ffdc7e81ae | |||
| 1d3357803d | |||
| 6c48aa2356 | |||
| 466e354679 | |||
| 5d4b896f70 | |||
| a04dffdfe8 | |||
| ff871943cf | |||
| 1a892ab227 | |||
| af1b303211 | |||
| 6fd702eba8 | |||
| d220d43cd2 | |||
| 6892afb974 | |||
| 007b46b080 | |||
| 67d130dc34 | |||
| 7e923c77fe | |||
| a593b52812 | |||
|
|
520dc80303 | ||
| 001897bbcd | |||
|
|
bab29c23e3 | ||
| 76b39f2df3 | |||
| 509b3e145b | |||
| 2b80ebc2d0 | |||
| 0ab908dd2a | |||
| 6007467e7a | |||
| 3745157c42 | |||
| 94481ec7bd | |||
| fbfe8cbdee | |||
| fbbab0a981 | |||
| ae2fb3b303 | |||
| 3d7a4666ed | |||
| 5d3e0fb800 | |||
| 85ff52a661 | |||
| da7fd64a43 | |||
| 3902633217 | |||
| f478ea8b84 | |||
| 0f481aff5b | |||
| 7a31663310 | |||
| 0239c53c04 | |||
| 16987c758e | |||
| 3a36915140 | |||
| 4bde708878 | |||
| 2f0cf560f8 | |||
| cf355a95fd | |||
| 2f43073172 | |||
| 8236d31ecc | |||
| 459a7dade0 | |||
| e6000a660a | |||
| 75abaac205 | |||
| 603d5c3f73 | |||
| 4e4bd99598 | |||
| d1fbe5f15e | |||
| c061ef2132 | |||
| c378309bdd | |||
| b2c5d64fc5 | |||
|
|
5371637b16 | ||
| c5cbf0af37 | |||
| 1a31e22450 | |||
|
|
49db54529d | ||
| 8e0c0c6054 | |||
| f3d1183076 | |||
| a9f7f0cce0 | |||
| f2943f8411 | |||
| 808e7dcffa | |||
| 9bed4fa6fb | |||
| e6255a340b | |||
| 78bf319fb7 | |||
| 36a966d582 | |||
| f72b268d36 | |||
| 44ef31034e | |||
| 229dc2186f | |||
| a2f9a1efb4 | |||
|
|
823e3c5de6 | ||
|
|
faac7bac35 | ||
| 1fac1bfe02 | |||
| 9394b1d9c8 | |||
| 43dd13bac4 | |||
| 65bc372103 | |||
| 6558854a7a | |||
| 892035ab27 | |||
| 87ae8d2ff4 | |||
| 15c2dbaa0d | |||
| 6b3338b885 | |||
| bb00b1bc6a | |||
| 5e1a15ada2 | |||
| 9bdf8ba346 | |||
| 204c087f29 | |||
| 1def3e1895 | |||
| 550c74e544 | |||
| a39565f012 | |||
| aa9755e6a7 | |||
| b25e8d661a | |||
| 4b253ac3ec | |||
| 5d1b875d3c | |||
| e2e103fa67 | |||
| 43c90da4e3 | |||
| fa210dd98f | |||
| 43d9ca92bf | |||
| 5e592c143f | |||
| 0c59816f26 | |||
| 19c2457895 | |||
| af8d87857e | |||
| d05f63a36a | |||
| e2dc520012 | |||
| cff9c15e31 | |||
| f00135c4bf | |||
| 30b8a6c30f | |||
| b9c4ee31b1 | |||
| 87870af866 | |||
| b83cb0fb0b | |||
| 7fd1fe34e5 | |||
| 1c18330891 | |||
| d320879ad0 | |||
| 950150e119 | |||
| 3c4a9767e1 | |||
| 5df2445f3f | |||
| 56543d7b4c | |||
| 4c6fea1242 | |||
| fff43de9e3 | |||
| b31a915544 | |||
| 8956723ac5 | |||
| ccc3ac415e | |||
| 8c47a59b80 | |||
| a6d869ebf6 | |||
| f3a8699389 | |||
| d345c00e84 | |||
| a706f127b6 | |||
| 680ece0b6a | |||
| b976c6ed37 | |||
| 6ae6b132de | |||
| 95aec7c95b | |||
| edd760fbcb | |||
| ba269dbbb8 | |||
| 1aa45dd9f1 | |||
| 92685d7410 | |||
| c8e351514d | |||
| f3900825e3 | |||
| 2cc6652f75 | |||
| 4d4409de2e | |||
| e1286c797f | |||
| bec037622f | |||
| a0d8c1a9b3 | |||
| 26135d2116 | |||
| 71b67fd22d | |||
| 855072dfea | |||
| b39e2e2d64 | |||
| 84b1d6a346 | |||
| 28335dd548 | |||
| 7253e2d3ef | |||
| 4d489425fa | |||
| 890a8a44cf | |||
| 8e3583f57a | |||
| d0ff14659f | |||
| 1f7caaeaac | |||
| 9f9f42071a | |||
| 6bd6e994cb | |||
| 02e68d76ee | |||
| d04b06089c | |||
| 9be6fea2e0 | |||
| 6b1214a06f | |||
| 4597373ac9 | |||
| 047c8d93aa | |||
| 715f95ca22 | |||
| ba709012d7 | |||
| fd186f8391 | |||
| 262d36cd2d | |||
| f320855348 | |||
| ed90152462 | |||
| 6e5c5f1690 | |||
| 7c92dee097 | |||
| e4bb031138 | |||
| 97226ae96b | |||
| d8cd33e79a | |||
| 5ecd39b6a9 | |||
| 8854305e99 | |||
| 903cade296 | |||
| e48410a528 | |||
| 170ea4f2c0 | |||
| 19f0e11384 | |||
| 80bf6c3bbe | |||
| 8352ce8b5b | |||
| c06abf6e42 | |||
| 37cc0a5291 | |||
| 25ae18d6a9 | |||
| 18db50d80c | |||
| 903008d397 | |||
| 4499d4ec8e | |||
| 3a4faac8cb | |||
| e6c58b7b63 | |||
| a7454edec0 | |||
| cbf1952eb7 | |||
| 6d06f0a1b4 | |||
| f2d2a9efd8 | |||
| d44c8217b0 | |||
| 446c33d8b0 | |||
| 996462f1fd | |||
| 778f6bb79f | |||
| 8747f948b9 | |||
| 9546d6e4b8 | |||
| f8d1940af6 | |||
| b2b0891d24 | |||
| 274168d4bc | |||
| 2c98b348d5 | |||
| afc7887ddd | |||
| 99ff78a3d5 | |||
| 2ad85addf6 | |||
| 552b4b2572 | |||
| 594ac39e3d | |||
| 23321171f3 | |||
| ee72d79c93 | |||
| a20c2598fc | |||
| 2eba871a6d | |||
| 46919dec31 | |||
| 9dd6cffe0c | |||
| 2ea9f5e907 | |||
| 050750a808 | |||
| f479b9fc8b | |||
| 13ea182707 | |||
| 14183a7316 | |||
| 9fc9b87608 | |||
| 53c2445ba9 | |||
| d414695eb3 | |||
|
|
27bc17079e | ||
|
|
295188459b | ||
|
|
66115258a7 | ||
|
|
2cf2c515b4 | ||
|
|
925cb2b423 | ||
|
|
0a2804a404 | ||
|
|
12bbcbf69c | ||
|
|
52ce490725 | ||
| 82067fb3aa | |||
| 007acedf29 | |||
| 8e903ec6c1 | |||
| b55e56c3c4 | |||
| 6f9de431b1 | |||
| a8efd26262 | |||
| e367fc3f5c | |||
| 8a1af120ea | |||
| f03f0181f8 | |||
| 6c7d42c31a | |||
| d6c829c26a | |||
| 666a2dfbf5 | |||
| fd979c3a35 | |||
| 847fc6e864 | |||
| 356b7bf01a | |||
| 450d5ebc81 | |||
| f04285848f | |||
| c4becb0a05 | |||
| d22619396b | |||
| fe8640a6db | |||
| ff475d43dd | |||
| 9e8f6d57df | |||
| 79227a12e2 | |||
| a23dcfe702 | |||
| 243ecb3f71 | |||
| b8dec9f798 | |||
| 536375729f | |||
| 5939a1dc5b | |||
| 9d115a5712 | |||
| f511612a53 | |||
| 180fbcc558 | |||
| 047cb9dc0d | |||
| 786f851a97 | |||
| 4deff5a920 | |||
| 0361f031db | |||
| e90b35f19f | |||
| f2829b2012 | |||
| 825e6b5b6d | |||
| 2a3276973c | |||
| f4e10afa8f | |||
| 60c5e584be | |||
| 2b237eaad9 | |||
|
|
891a0b999c | ||
| 01da729365 | |||
| cef313b356 | |||
| 8bc8556f06 | |||
| 1a8abe5849 | |||
| 86258acc6e | |||
| 0062d3baf0 | |||
| a7c9a2281c | |||
| 06e1623a86 | |||
| 434256e61e | |||
| b275b8328d | |||
| 63230c16ff | |||
| 47c31ddec2 | |||
| b89cffeb18 | |||
| 568d70fffb | |||
| 2287995cb4 | |||
| e485f0499f | |||
| 99992a39ba | |||
| 6d68b20122 | |||
| ffbe399614 | |||
| 9482594117 | |||
| ea512183d2 | |||
| abd89b538c | |||
| 9367a515f4 | |||
| 4c0ad5ef32 | |||
| 35b79d7562 | |||
| 4728df93e2 | |||
| 3fd9cd4547 | |||
| beda47ff7e | |||
| d1506f10ef | |||
| 006841cf82 | |||
| f73cf10a54 | |||
| b39248cc58 | |||
| 4ba809a8d6 | |||
| a6d1ca57d7 | |||
| fbbe373ce8 |
14
.github/workflows/build.yml
vendored
@@ -3,7 +3,7 @@ name: Build Release
|
||||
on:
|
||||
push:
|
||||
tags:
|
||||
- '*'
|
||||
- "*"
|
||||
workflow_dispatch:
|
||||
|
||||
jobs:
|
||||
@@ -41,6 +41,15 @@ jobs:
|
||||
with:
|
||||
name: build-output-windows
|
||||
path: build/windows/x64/runner/Release
|
||||
- name: Compile Installer
|
||||
uses: Minionguyjpro/Inno-Setup-Action@v1.2.2
|
||||
with:
|
||||
path: setup.iss
|
||||
- name: Archive installer artifacts
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: build-output-windows-installer
|
||||
path: Installer/windows-x86_64-setup.exe
|
||||
build-linux:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
@@ -59,6 +68,7 @@ jobs:
|
||||
sudo apt-get install -y libnotify-dev
|
||||
sudo apt-get install -y libgstreamer1.0-dev libgstreamer-plugins-base1.0-dev
|
||||
sudo apt-get install -y gstreamer-1.0
|
||||
sudo apt-get install -y libsecret-1-dev
|
||||
- run: flutter pub get
|
||||
- run: flutter build linux
|
||||
- name: Archive production artifacts
|
||||
@@ -80,4 +90,4 @@ jobs:
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: build-output-linux-appimage
|
||||
path: './*.AppImage*'
|
||||
path: "./*.AppImage*"
|
||||
|
||||
3
.gitignore
vendored
@@ -12,6 +12,9 @@
|
||||
.swiftpm/
|
||||
migrate_working_dir/
|
||||
|
||||
# Inno Setup
|
||||
Installer/
|
||||
|
||||
# IntelliJ related
|
||||
*.iml
|
||||
*.ipr
|
||||
|
||||
41
CODE_OF_CONDUCT.md
Normal file
@@ -0,0 +1,41 @@
|
||||
# Code of Conduct
|
||||
|
||||
Welcome to the Solar Network / HyperNet project!
|
||||
|
||||
We're welcome for any contribution, from bug reports to feature requests to code contributions.
|
||||
|
||||
To get started, start from fork the repository.
|
||||
|
||||
## Project Structure
|
||||
|
||||
The current repository you're visiting is the front-end project for the Solar Network project. It's built by Flutter and also manages all feature requests and issues reports in this repository.
|
||||
|
||||
The backend of the Solar Network is written in Go and is a microservices app. The code is stored separately in different repositories. They're linked in the README.MD, you can have a look and try to contribute if you want.
|
||||
|
||||
## Commit Messages
|
||||
|
||||
We're using the gitmoji to clarify the reason and changes of the commit. To learn more about gitmoji, visit <https://gitmoji.dev>
|
||||
|
||||
All the commit message should follow `:[gitmoji]: <commit message>` syntax
|
||||
|
||||
## Translations & Localization
|
||||
|
||||
We're not accepting translation and localization improvements, or fixes on the GitHub or Solsynth Git Repository. If you want to contribute to those, please head to our Crowdin project: <https://crowdin.com/project/solian>
|
||||
|
||||
## New Features
|
||||
|
||||
To contribute new features, please create an issue or mention the feature you want in our official development chat channel. You should discuss the feature with us and the community first. You shouldn't just create a Pull Request for the feature you want, it will not be merged.
|
||||
|
||||
## Bug Reports / Ask for help
|
||||
|
||||
Read the error message, check for the update (including pre-releases), and wiki before creating an issue. At the same time, be respectful and don't argue with our developers and contributors in the development chat or GitHub issue. Otherwise your issue may got deleted and your Solar Network Account may got a strike.
|
||||
|
||||
## Styles of Code
|
||||
|
||||
Before you create a Pull Request, make sure your code has pass the `flutter analyze` check, if there is any notes, fix as much as possible, if there is no way to fix, do ignore.
|
||||
|
||||
When the code contains comments, use English. We do not any other language of comments existing in the codebase. It might confuse future contributors, cause the code hard to understand and maintaiance.
|
||||
|
||||
-----------
|
||||
|
||||
We appreciate every single commit you contributed. Let's work together and create a better Solar Network!
|
||||
661
LICENSE.txt
Normal file
@@ -0,0 +1,661 @@
|
||||
GNU AFFERO GENERAL PUBLIC LICENSE
|
||||
Version 3, 19 November 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <https://fsf.org/>
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The GNU Affero General Public License is a free, copyleft license for
|
||||
software and other kinds of works, specifically designed to ensure
|
||||
cooperation with the community in the case of network server software.
|
||||
|
||||
The licenses for most software and other practical works are designed
|
||||
to take away your freedom to share and change the works. By contrast,
|
||||
our General Public Licenses are intended to guarantee your freedom to
|
||||
share and change all versions of a program--to make sure it remains free
|
||||
software for all its users.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
them if you wish), that you receive source code or can get it if you
|
||||
want it, that you can change the software or use pieces of it in new
|
||||
free programs, and that you know you can do these things.
|
||||
|
||||
Developers that use our General Public Licenses protect your rights
|
||||
with two steps: (1) assert copyright on the software, and (2) offer
|
||||
you this License which gives you legal permission to copy, distribute
|
||||
and/or modify the software.
|
||||
|
||||
A secondary benefit of defending all users' freedom is that
|
||||
improvements made in alternate versions of the program, if they
|
||||
receive widespread use, become available for other developers to
|
||||
incorporate. Many developers of free software are heartened and
|
||||
encouraged by the resulting cooperation. However, in the case of
|
||||
software used on network servers, this result may fail to come about.
|
||||
The GNU General Public License permits making a modified version and
|
||||
letting the public access it on a server without ever releasing its
|
||||
source code to the public.
|
||||
|
||||
The GNU Affero General Public License is designed specifically to
|
||||
ensure that, in such cases, the modified source code becomes available
|
||||
to the community. It requires the operator of a network server to
|
||||
provide the source code of the modified version running there to the
|
||||
users of that server. Therefore, public use of a modified version, on
|
||||
a publicly accessible server, gives the public access to the source
|
||||
code of the modified version.
|
||||
|
||||
An older license, called the Affero General Public License and
|
||||
published by Affero, was designed to accomplish similar goals. This is
|
||||
a different license, not a version of the Affero GPL, but Affero has
|
||||
released a new version of the Affero GPL which permits relicensing under
|
||||
this license.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
TERMS AND CONDITIONS
|
||||
|
||||
0. Definitions.
|
||||
|
||||
"This License" refers to version 3 of the GNU Affero General Public License.
|
||||
|
||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||
works, such as semiconductor masks.
|
||||
|
||||
"The Program" refers to any copyrightable work licensed under this
|
||||
License. Each licensee is addressed as "you". "Licensees" and
|
||||
"recipients" may be individuals or organizations.
|
||||
|
||||
To "modify" a work means to copy from or adapt all or part of the work
|
||||
in a fashion requiring copyright permission, other than the making of an
|
||||
exact copy. The resulting work is called a "modified version" of the
|
||||
earlier work or a work "based on" the earlier work.
|
||||
|
||||
A "covered work" means either the unmodified Program or a work based
|
||||
on the Program.
|
||||
|
||||
To "propagate" a work means to do anything with it that, without
|
||||
permission, would make you directly or secondarily liable for
|
||||
infringement under applicable copyright law, except executing it on a
|
||||
computer or modifying a private copy. Propagation includes copying,
|
||||
distribution (with or without modification), making available to the
|
||||
public, and in some countries other activities as well.
|
||||
|
||||
To "convey" a work means any kind of propagation that enables other
|
||||
parties to make or receive copies. Mere interaction with a user through
|
||||
a computer network, with no transfer of a copy, is not conveying.
|
||||
|
||||
An interactive user interface displays "Appropriate Legal Notices"
|
||||
to the extent that it includes a convenient and prominently visible
|
||||
feature that (1) displays an appropriate copyright notice, and (2)
|
||||
tells the user that there is no warranty for the work (except to the
|
||||
extent that warranties are provided), that licensees may convey the
|
||||
work under this License, and how to view a copy of this License. If
|
||||
the interface presents a list of user commands or options, such as a
|
||||
menu, a prominent item in the list meets this criterion.
|
||||
|
||||
1. Source Code.
|
||||
|
||||
The "source code" for a work means the preferred form of the work
|
||||
for making modifications to it. "Object code" means any non-source
|
||||
form of a work.
|
||||
|
||||
A "Standard Interface" means an interface that either is an official
|
||||
standard defined by a recognized standards body, or, in the case of
|
||||
interfaces specified for a particular programming language, one that
|
||||
is widely used among developers working in that language.
|
||||
|
||||
The "System Libraries" of an executable work include anything, other
|
||||
than the work as a whole, that (a) is included in the normal form of
|
||||
packaging a Major Component, but which is not part of that Major
|
||||
Component, and (b) serves only to enable use of the work with that
|
||||
Major Component, or to implement a Standard Interface for which an
|
||||
implementation is available to the public in source code form. A
|
||||
"Major Component", in this context, means a major essential component
|
||||
(kernel, window system, and so on) of the specific operating system
|
||||
(if any) on which the executable work runs, or a compiler used to
|
||||
produce the work, or an object code interpreter used to run it.
|
||||
|
||||
The "Corresponding Source" for a work in object code form means all
|
||||
the source code needed to generate, install, and (for an executable
|
||||
work) run the object code and to modify the work, including scripts to
|
||||
control those activities. However, it does not include the work's
|
||||
System Libraries, or general-purpose tools or generally available free
|
||||
programs which are used unmodified in performing those activities but
|
||||
which are not part of the work. For example, Corresponding Source
|
||||
includes interface definition files associated with source files for
|
||||
the work, and the source code for shared libraries and dynamically
|
||||
linked subprograms that the work is specifically designed to require,
|
||||
such as by intimate data communication or control flow between those
|
||||
subprograms and other parts of the work.
|
||||
|
||||
The Corresponding Source need not include anything that users
|
||||
can regenerate automatically from other parts of the Corresponding
|
||||
Source.
|
||||
|
||||
The Corresponding Source for a work in source code form is that
|
||||
same work.
|
||||
|
||||
2. Basic Permissions.
|
||||
|
||||
All rights granted under this License are granted for the term of
|
||||
copyright on the Program, and are irrevocable provided the stated
|
||||
conditions are met. This License explicitly affirms your unlimited
|
||||
permission to run the unmodified Program. The output from running a
|
||||
covered work is covered by this License only if the output, given its
|
||||
content, constitutes a covered work. This License acknowledges your
|
||||
rights of fair use or other equivalent, as provided by copyright law.
|
||||
|
||||
You may make, run and propagate covered works that you do not
|
||||
convey, without conditions so long as your license otherwise remains
|
||||
in force. You may convey covered works to others for the sole purpose
|
||||
of having them make modifications exclusively for you, or provide you
|
||||
with facilities for running those works, provided that you comply with
|
||||
the terms of this License in conveying all material for which you do
|
||||
not control copyright. Those thus making or running the covered works
|
||||
for you must do so exclusively on your behalf, under your direction
|
||||
and control, on terms that prohibit them from making any copies of
|
||||
your copyrighted material outside their relationship with you.
|
||||
|
||||
Conveying under any other circumstances is permitted solely under
|
||||
the conditions stated below. Sublicensing is not allowed; section 10
|
||||
makes it unnecessary.
|
||||
|
||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||
|
||||
No covered work shall be deemed part of an effective technological
|
||||
measure under any applicable law fulfilling obligations under article
|
||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||
similar laws prohibiting or restricting circumvention of such
|
||||
measures.
|
||||
|
||||
When you convey a covered work, you waive any legal power to forbid
|
||||
circumvention of technological measures to the extent such circumvention
|
||||
is effected by exercising rights under this License with respect to
|
||||
the covered work, and you disclaim any intention to limit operation or
|
||||
modification of the work as a means of enforcing, against the work's
|
||||
users, your or third parties' legal rights to forbid circumvention of
|
||||
technological measures.
|
||||
|
||||
4. Conveying Verbatim Copies.
|
||||
|
||||
You may convey verbatim copies of the Program's source code as you
|
||||
receive it, in any medium, provided that you conspicuously and
|
||||
appropriately publish on each copy an appropriate copyright notice;
|
||||
keep intact all notices stating that this License and any
|
||||
non-permissive terms added in accord with section 7 apply to the code;
|
||||
keep intact all notices of the absence of any warranty; and give all
|
||||
recipients a copy of this License along with the Program.
|
||||
|
||||
You may charge any price or no price for each copy that you convey,
|
||||
and you may offer support or warranty protection for a fee.
|
||||
|
||||
5. Conveying Modified Source Versions.
|
||||
|
||||
You may convey a work based on the Program, or the modifications to
|
||||
produce it from the Program, in the form of source code under the
|
||||
terms of section 4, provided that you also meet all of these conditions:
|
||||
|
||||
a) The work must carry prominent notices stating that you modified
|
||||
it, and giving a relevant date.
|
||||
|
||||
b) The work must carry prominent notices stating that it is
|
||||
released under this License and any conditions added under section
|
||||
7. This requirement modifies the requirement in section 4 to
|
||||
"keep intact all notices".
|
||||
|
||||
c) You must license the entire work, as a whole, under this
|
||||
License to anyone who comes into possession of a copy. This
|
||||
License will therefore apply, along with any applicable section 7
|
||||
additional terms, to the whole of the work, and all its parts,
|
||||
regardless of how they are packaged. This License gives no
|
||||
permission to license the work in any other way, but it does not
|
||||
invalidate such permission if you have separately received it.
|
||||
|
||||
d) If the work has interactive user interfaces, each must display
|
||||
Appropriate Legal Notices; however, if the Program has interactive
|
||||
interfaces that do not display Appropriate Legal Notices, your
|
||||
work need not make them do so.
|
||||
|
||||
A compilation of a covered work with other separate and independent
|
||||
works, which are not by their nature extensions of the covered work,
|
||||
and which are not combined with it such as to form a larger program,
|
||||
in or on a volume of a storage or distribution medium, is called an
|
||||
"aggregate" if the compilation and its resulting copyright are not
|
||||
used to limit the access or legal rights of the compilation's users
|
||||
beyond what the individual works permit. Inclusion of a covered work
|
||||
in an aggregate does not cause this License to apply to the other
|
||||
parts of the aggregate.
|
||||
|
||||
6. Conveying Non-Source Forms.
|
||||
|
||||
You may convey a covered work in object code form under the terms
|
||||
of sections 4 and 5, provided that you also convey the
|
||||
machine-readable Corresponding Source under the terms of this License,
|
||||
in one of these ways:
|
||||
|
||||
a) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by the
|
||||
Corresponding Source fixed on a durable physical medium
|
||||
customarily used for software interchange.
|
||||
|
||||
b) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by a
|
||||
written offer, valid for at least three years and valid for as
|
||||
long as you offer spare parts or customer support for that product
|
||||
model, to give anyone who possesses the object code either (1) a
|
||||
copy of the Corresponding Source for all the software in the
|
||||
product that is covered by this License, on a durable physical
|
||||
medium customarily used for software interchange, for a price no
|
||||
more than your reasonable cost of physically performing this
|
||||
conveying of source, or (2) access to copy the
|
||||
Corresponding Source from a network server at no charge.
|
||||
|
||||
c) Convey individual copies of the object code with a copy of the
|
||||
written offer to provide the Corresponding Source. This
|
||||
alternative is allowed only occasionally and noncommercially, and
|
||||
only if you received the object code with such an offer, in accord
|
||||
with subsection 6b.
|
||||
|
||||
d) Convey the object code by offering access from a designated
|
||||
place (gratis or for a charge), and offer equivalent access to the
|
||||
Corresponding Source in the same way through the same place at no
|
||||
further charge. You need not require recipients to copy the
|
||||
Corresponding Source along with the object code. If the place to
|
||||
copy the object code is a network server, the Corresponding Source
|
||||
may be on a different server (operated by you or a third party)
|
||||
that supports equivalent copying facilities, provided you maintain
|
||||
clear directions next to the object code saying where to find the
|
||||
Corresponding Source. Regardless of what server hosts the
|
||||
Corresponding Source, you remain obligated to ensure that it is
|
||||
available for as long as needed to satisfy these requirements.
|
||||
|
||||
e) Convey the object code using peer-to-peer transmission, provided
|
||||
you inform other peers where the object code and Corresponding
|
||||
Source of the work are being offered to the general public at no
|
||||
charge under subsection 6d.
|
||||
|
||||
A separable portion of the object code, whose source code is excluded
|
||||
from the Corresponding Source as a System Library, need not be
|
||||
included in conveying the object code work.
|
||||
|
||||
A "User Product" is either (1) a "consumer product", which means any
|
||||
tangible personal property which is normally used for personal, family,
|
||||
or household purposes, or (2) anything designed or sold for incorporation
|
||||
into a dwelling. In determining whether a product is a consumer product,
|
||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||
product received by a particular user, "normally used" refers to a
|
||||
typical or common use of that class of product, regardless of the status
|
||||
of the particular user or of the way in which the particular user
|
||||
actually uses, or expects or is expected to use, the product. A product
|
||||
is a consumer product regardless of whether the product has substantial
|
||||
commercial, industrial or non-consumer uses, unless such uses represent
|
||||
the only significant mode of use of the product.
|
||||
|
||||
"Installation Information" for a User Product means any methods,
|
||||
procedures, authorization keys, or other information required to install
|
||||
and execute modified versions of a covered work in that User Product from
|
||||
a modified version of its Corresponding Source. The information must
|
||||
suffice to ensure that the continued functioning of the modified object
|
||||
code is in no case prevented or interfered with solely because
|
||||
modification has been made.
|
||||
|
||||
If you convey an object code work under this section in, or with, or
|
||||
specifically for use in, a User Product, and the conveying occurs as
|
||||
part of a transaction in which the right of possession and use of the
|
||||
User Product is transferred to the recipient in perpetuity or for a
|
||||
fixed term (regardless of how the transaction is characterized), the
|
||||
Corresponding Source conveyed under this section must be accompanied
|
||||
by the Installation Information. But this requirement does not apply
|
||||
if neither you nor any third party retains the ability to install
|
||||
modified object code on the User Product (for example, the work has
|
||||
been installed in ROM).
|
||||
|
||||
The requirement to provide Installation Information does not include a
|
||||
requirement to continue to provide support service, warranty, or updates
|
||||
for a work that has been modified or installed by the recipient, or for
|
||||
the User Product in which it has been modified or installed. Access to a
|
||||
network may be denied when the modification itself materially and
|
||||
adversely affects the operation of the network or violates the rules and
|
||||
protocols for communication across the network.
|
||||
|
||||
Corresponding Source conveyed, and Installation Information provided,
|
||||
in accord with this section must be in a format that is publicly
|
||||
documented (and with an implementation available to the public in
|
||||
source code form), and must require no special password or key for
|
||||
unpacking, reading or copying.
|
||||
|
||||
7. Additional Terms.
|
||||
|
||||
"Additional permissions" are terms that supplement the terms of this
|
||||
License by making exceptions from one or more of its conditions.
|
||||
Additional permissions that are applicable to the entire Program shall
|
||||
be treated as though they were included in this License, to the extent
|
||||
that they are valid under applicable law. If additional permissions
|
||||
apply only to part of the Program, that part may be used separately
|
||||
under those permissions, but the entire Program remains governed by
|
||||
this License without regard to the additional permissions.
|
||||
|
||||
When you convey a copy of a covered work, you may at your option
|
||||
remove any additional permissions from that copy, or from any part of
|
||||
it. (Additional permissions may be written to require their own
|
||||
removal in certain cases when you modify the work.) You may place
|
||||
additional permissions on material, added by you to a covered work,
|
||||
for which you have or can give appropriate copyright permission.
|
||||
|
||||
Notwithstanding any other provision of this License, for material you
|
||||
add to a covered work, you may (if authorized by the copyright holders of
|
||||
that material) supplement the terms of this License with terms:
|
||||
|
||||
a) Disclaiming warranty or limiting liability differently from the
|
||||
terms of sections 15 and 16 of this License; or
|
||||
|
||||
b) Requiring preservation of specified reasonable legal notices or
|
||||
author attributions in that material or in the Appropriate Legal
|
||||
Notices displayed by works containing it; or
|
||||
|
||||
c) Prohibiting misrepresentation of the origin of that material, or
|
||||
requiring that modified versions of such material be marked in
|
||||
reasonable ways as different from the original version; or
|
||||
|
||||
d) Limiting the use for publicity purposes of names of licensors or
|
||||
authors of the material; or
|
||||
|
||||
e) Declining to grant rights under trademark law for use of some
|
||||
trade names, trademarks, or service marks; or
|
||||
|
||||
f) Requiring indemnification of licensors and authors of that
|
||||
material by anyone who conveys the material (or modified versions of
|
||||
it) with contractual assumptions of liability to the recipient, for
|
||||
any liability that these contractual assumptions directly impose on
|
||||
those licensors and authors.
|
||||
|
||||
All other non-permissive additional terms are considered "further
|
||||
restrictions" within the meaning of section 10. If the Program as you
|
||||
received it, or any part of it, contains a notice stating that it is
|
||||
governed by this License along with a term that is a further
|
||||
restriction, you may remove that term. If a license document contains
|
||||
a further restriction but permits relicensing or conveying under this
|
||||
License, you may add to a covered work material governed by the terms
|
||||
of that license document, provided that the further restriction does
|
||||
not survive such relicensing or conveying.
|
||||
|
||||
If you add terms to a covered work in accord with this section, you
|
||||
must place, in the relevant source files, a statement of the
|
||||
additional terms that apply to those files, or a notice indicating
|
||||
where to find the applicable terms.
|
||||
|
||||
Additional terms, permissive or non-permissive, may be stated in the
|
||||
form of a separately written license, or stated as exceptions;
|
||||
the above requirements apply either way.
|
||||
|
||||
8. Termination.
|
||||
|
||||
You may not propagate or modify a covered work except as expressly
|
||||
provided under this License. Any attempt otherwise to propagate or
|
||||
modify it is void, and will automatically terminate your rights under
|
||||
this License (including any patent licenses granted under the third
|
||||
paragraph of section 11).
|
||||
|
||||
However, if you cease all violation of this License, then your
|
||||
license from a particular copyright holder is reinstated (a)
|
||||
provisionally, unless and until the copyright holder explicitly and
|
||||
finally terminates your license, and (b) permanently, if the copyright
|
||||
holder fails to notify you of the violation by some reasonable means
|
||||
prior to 60 days after the cessation.
|
||||
|
||||
Moreover, your license from a particular copyright holder is
|
||||
reinstated permanently if the copyright holder notifies you of the
|
||||
violation by some reasonable means, this is the first time you have
|
||||
received notice of violation of this License (for any work) from that
|
||||
copyright holder, and you cure the violation prior to 30 days after
|
||||
your receipt of the notice.
|
||||
|
||||
Termination of your rights under this section does not terminate the
|
||||
licenses of parties who have received copies or rights from you under
|
||||
this License. If your rights have been terminated and not permanently
|
||||
reinstated, you do not qualify to receive new licenses for the same
|
||||
material under section 10.
|
||||
|
||||
9. Acceptance Not Required for Having Copies.
|
||||
|
||||
You are not required to accept this License in order to receive or
|
||||
run a copy of the Program. Ancillary propagation of a covered work
|
||||
occurring solely as a consequence of using peer-to-peer transmission
|
||||
to receive a copy likewise does not require acceptance. However,
|
||||
nothing other than this License grants you permission to propagate or
|
||||
modify any covered work. These actions infringe copyright if you do
|
||||
not accept this License. Therefore, by modifying or propagating a
|
||||
covered work, you indicate your acceptance of this License to do so.
|
||||
|
||||
10. Automatic Licensing of Downstream Recipients.
|
||||
|
||||
Each time you convey a covered work, the recipient automatically
|
||||
receives a license from the original licensors, to run, modify and
|
||||
propagate that work, subject to this License. You are not responsible
|
||||
for enforcing compliance by third parties with this License.
|
||||
|
||||
An "entity transaction" is a transaction transferring control of an
|
||||
organization, or substantially all assets of one, or subdividing an
|
||||
organization, or merging organizations. If propagation of a covered
|
||||
work results from an entity transaction, each party to that
|
||||
transaction who receives a copy of the work also receives whatever
|
||||
licenses to the work the party's predecessor in interest had or could
|
||||
give under the previous paragraph, plus a right to possession of the
|
||||
Corresponding Source of the work from the predecessor in interest, if
|
||||
the predecessor has it or can get it with reasonable efforts.
|
||||
|
||||
You may not impose any further restrictions on the exercise of the
|
||||
rights granted or affirmed under this License. For example, you may
|
||||
not impose a license fee, royalty, or other charge for exercise of
|
||||
rights granted under this License, and you may not initiate litigation
|
||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||
any patent claim is infringed by making, using, selling, offering for
|
||||
sale, or importing the Program or any portion of it.
|
||||
|
||||
11. Patents.
|
||||
|
||||
A "contributor" is a copyright holder who authorizes use under this
|
||||
License of the Program or a work on which the Program is based. The
|
||||
work thus licensed is called the contributor's "contributor version".
|
||||
|
||||
A contributor's "essential patent claims" are all patent claims
|
||||
owned or controlled by the contributor, whether already acquired or
|
||||
hereafter acquired, that would be infringed by some manner, permitted
|
||||
by this License, of making, using, or selling its contributor version,
|
||||
but do not include claims that would be infringed only as a
|
||||
consequence of further modification of the contributor version. For
|
||||
purposes of this definition, "control" includes the right to grant
|
||||
patent sublicenses in a manner consistent with the requirements of
|
||||
this License.
|
||||
|
||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||
patent license under the contributor's essential patent claims, to
|
||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||
propagate the contents of its contributor version.
|
||||
|
||||
In the following three paragraphs, a "patent license" is any express
|
||||
agreement or commitment, however denominated, not to enforce a patent
|
||||
(such as an express permission to practice a patent or covenant not to
|
||||
sue for patent infringement). To "grant" such a patent license to a
|
||||
party means to make such an agreement or commitment not to enforce a
|
||||
patent against the party.
|
||||
|
||||
If you convey a covered work, knowingly relying on a patent license,
|
||||
and the Corresponding Source of the work is not available for anyone
|
||||
to copy, free of charge and under the terms of this License, through a
|
||||
publicly available network server or other readily accessible means,
|
||||
then you must either (1) cause the Corresponding Source to be so
|
||||
available, or (2) arrange to deprive yourself of the benefit of the
|
||||
patent license for this particular work, or (3) arrange, in a manner
|
||||
consistent with the requirements of this License, to extend the patent
|
||||
license to downstream recipients. "Knowingly relying" means you have
|
||||
actual knowledge that, but for the patent license, your conveying the
|
||||
covered work in a country, or your recipient's use of the covered work
|
||||
in a country, would infringe one or more identifiable patents in that
|
||||
country that you have reason to believe are valid.
|
||||
|
||||
If, pursuant to or in connection with a single transaction or
|
||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||
covered work, and grant a patent license to some of the parties
|
||||
receiving the covered work authorizing them to use, propagate, modify
|
||||
or convey a specific copy of the covered work, then the patent license
|
||||
you grant is automatically extended to all recipients of the covered
|
||||
work and works based on it.
|
||||
|
||||
A patent license is "discriminatory" if it does not include within
|
||||
the scope of its coverage, prohibits the exercise of, or is
|
||||
conditioned on the non-exercise of one or more of the rights that are
|
||||
specifically granted under this License. You may not convey a covered
|
||||
work if you are a party to an arrangement with a third party that is
|
||||
in the business of distributing software, under which you make payment
|
||||
to the third party based on the extent of your activity of conveying
|
||||
the work, and under which the third party grants, to any of the
|
||||
parties who would receive the covered work from you, a discriminatory
|
||||
patent license (a) in connection with copies of the covered work
|
||||
conveyed by you (or copies made from those copies), or (b) primarily
|
||||
for and in connection with specific products or compilations that
|
||||
contain the covered work, unless you entered into that arrangement,
|
||||
or that patent license was granted, prior to 28 March 2007.
|
||||
|
||||
Nothing in this License shall be construed as excluding or limiting
|
||||
any implied license or other defenses to infringement that may
|
||||
otherwise be available to you under applicable patent law.
|
||||
|
||||
12. No Surrender of Others' Freedom.
|
||||
|
||||
If conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot convey a
|
||||
covered work so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you may
|
||||
not convey it at all. For example, if you agree to terms that obligate you
|
||||
to collect a royalty for further conveying from those to whom you convey
|
||||
the Program, the only way you could satisfy both those terms and this
|
||||
License would be to refrain entirely from conveying the Program.
|
||||
|
||||
13. Remote Network Interaction; Use with the GNU General Public License.
|
||||
|
||||
Notwithstanding any other provision of this License, if you modify the
|
||||
Program, your modified version must prominently offer all users
|
||||
interacting with it remotely through a computer network (if your version
|
||||
supports such interaction) an opportunity to receive the Corresponding
|
||||
Source of your version by providing access to the Corresponding Source
|
||||
from a network server at no charge, through some standard or customary
|
||||
means of facilitating copying of software. This Corresponding Source
|
||||
shall include the Corresponding Source for any work covered by version 3
|
||||
of the GNU General Public License that is incorporated pursuant to the
|
||||
following paragraph.
|
||||
|
||||
Notwithstanding any other provision of this License, you have
|
||||
permission to link or combine any covered work with a work licensed
|
||||
under version 3 of the GNU General Public License into a single
|
||||
combined work, and to convey the resulting work. The terms of this
|
||||
License will continue to apply to the part which is the covered work,
|
||||
but the work with which it is combined will remain governed by version
|
||||
3 of the GNU General Public License.
|
||||
|
||||
14. Revised Versions of this License.
|
||||
|
||||
The Free Software Foundation may publish revised and/or new versions of
|
||||
the GNU Affero General Public License from time to time. Such new versions
|
||||
will be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the
|
||||
Program specifies that a certain numbered version of the GNU Affero General
|
||||
Public License "or any later version" applies to it, you have the
|
||||
option of following the terms and conditions either of that numbered
|
||||
version or of any later version published by the Free Software
|
||||
Foundation. If the Program does not specify a version number of the
|
||||
GNU Affero General Public License, you may choose any version ever published
|
||||
by the Free Software Foundation.
|
||||
|
||||
If the Program specifies that a proxy can decide which future
|
||||
versions of the GNU Affero General Public License can be used, that proxy's
|
||||
public statement of acceptance of a version permanently authorizes you
|
||||
to choose that version for the Program.
|
||||
|
||||
Later license versions may give you additional or different
|
||||
permissions. However, no additional obligations are imposed on any
|
||||
author or copyright holder as a result of your choosing to follow a
|
||||
later version.
|
||||
|
||||
15. Disclaimer of Warranty.
|
||||
|
||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. Limitation of Liability.
|
||||
|
||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||
SUCH DAMAGES.
|
||||
|
||||
17. Interpretation of Sections 15 and 16.
|
||||
|
||||
If the disclaimer of warranty and limitation of liability provided
|
||||
above cannot be given local legal effect according to their terms,
|
||||
reviewing courts shall apply local law that most closely approximates
|
||||
an absolute waiver of all civil liability in connection with the
|
||||
Program, unless a warranty or assumption of liability accompanies a
|
||||
copy of the Program in return for a fee.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
state the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) <year> <name of author>
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU Affero General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU Affero General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU Affero General Public License
|
||||
along with this program. If not, see <https://www.gnu.org/licenses/>.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If your software can interact with users remotely through a computer
|
||||
network, you should also make sure that it provides a way for users to
|
||||
get its source. For example, if your program is a web application, its
|
||||
interface could display a "Source" link that leads users to an archive
|
||||
of the code. There are many ways you could offer source, and different
|
||||
solutions will be better for different programs; see section 13 for the
|
||||
specific requirements.
|
||||
|
||||
You should also get your employer (if you work as a programmer) or school,
|
||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||
For more information on this, and how to apply and follow the GNU AGPL, see
|
||||
<https://www.gnu.org/licenses/>.
|
||||
17
README.md
@@ -1,12 +1,16 @@
|
||||
# Solar Network
|
||||
|
||||
> [!IMPORTANT]
|
||||
> You're visiting the Solar Network v3 branch, which is the next version and still under active development. **NOT READY FOR USE / PRODUCTION!**
|
||||

|
||||
|
||||

|
||||
[](https://crowdin.com/project/solian)
|
||||
|
||||
*Tap the badge above to help us tranlate!*
|
||||
|
||||
Hello there! Welcome to the main repository of the DysonNetwork (also known as the Solar Network). The code here is mainly about the front-end app (also known as Solian). But you can still post issues here to get help and request new features!
|
||||
|
||||
如果你看得懂这行字,你可以前往我们的文档来了解更多:
|
||||
[Suki - Solar Network](https://kb.solsynth.dev/zh/solar-network)
|
||||
|
||||
## Server
|
||||
|
||||
The backend of the Solar Network project is located at [Solsynth/DysonNetwork](https://github.com/Solsynth/DysonNetwork)
|
||||
@@ -24,8 +28,6 @@ The content below will lead you to the world of Solar Network.
|
||||
|
||||
### For Normal Users
|
||||
|
||||
**The v3 Release is not ready, yet.**
|
||||
|
||||
1. Go to the Github Releases page, and download the latest release / pre-release according to your platform.
|
||||
- **What's the difference between stable and pre-release?** The pre-release is untested by the other users and includes the new cutting-edge features, usually the pre-release is the feature drop. At the same time, due to we're not doing the API versioning, some breaking changes may break the stable release, so use the pre-release one instead.
|
||||
2. Create an account on the Solar Network
|
||||
@@ -61,3 +63,8 @@ If you want to build the release version, use the flutter build command. Learn m
|
||||
flutter build <platform>
|
||||
```
|
||||
|
||||
### Known Issues
|
||||
|
||||
Due to the issues with the flutter build tools, [see](https://github.com/flutter/flutter/issues/160622).
|
||||
|
||||
Since there is a watchOS app for iOS, you're unable to use the flutter cli to run iOS app. Use xcode instead.
|
||||
@@ -1,19 +1,31 @@
|
||||
import java.util.Properties
|
||||
import java.io.FileInputStream
|
||||
|
||||
plugins {
|
||||
id("com.android.application")
|
||||
// START: FlutterFire Configuration
|
||||
id("com.google.gms.google-services")
|
||||
id("com.google.firebase.crashlytics")
|
||||
// END: FlutterFire Configuration
|
||||
id("kotlin-android")
|
||||
// The Flutter Gradle Plugin must be applied after the Android and Kotlin Gradle plugins.
|
||||
id("dev.flutter.flutter-gradle-plugin")
|
||||
}
|
||||
|
||||
val keystoreProperties = Properties()
|
||||
val keystorePropertiesFile = rootProject.file("key.properties")
|
||||
if (keystorePropertiesFile.exists()) {
|
||||
keystoreProperties.load(FileInputStream(keystorePropertiesFile))
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = "dev.solsynth.solian"
|
||||
compileSdk = flutter.compileSdkVersion
|
||||
ndkVersion = "29.0.13113456"
|
||||
|
||||
compileOptions {
|
||||
isCoreLibraryDesugaringEnabled = true
|
||||
|
||||
sourceCompatibility = JavaVersion.VERSION_17
|
||||
targetCompatibility = JavaVersion.VERSION_17
|
||||
}
|
||||
@@ -31,23 +43,36 @@ android {
|
||||
}
|
||||
|
||||
signingConfigs {
|
||||
release {
|
||||
keyAlias = keystoreProperties['keyAlias']
|
||||
keyPassword = keystoreProperties['keyPassword']
|
||||
storeFile = keystoreProperties['storeFile'] ? file(keystoreProperties['storeFile']) : null
|
||||
storePassword = keystoreProperties['storePassword']
|
||||
create("release") {
|
||||
keyAlias = keystoreProperties["keyAlias"] as String
|
||||
keyPassword = keystoreProperties["keyPassword"] as String
|
||||
storeFile = keystoreProperties["storeFile"]?.let { file(it) }
|
||||
storePassword = keystoreProperties["storePassword"] as String
|
||||
}
|
||||
}
|
||||
|
||||
buildTypes {
|
||||
release {
|
||||
signingConfig = signingConfigs.getByName("release")
|
||||
minifyEnabled = true
|
||||
shrinkResources = true
|
||||
|
||||
isMinifyEnabled = true
|
||||
proguardFiles(
|
||||
getDefaultProguardFile("proguard-android-optimize.txt"),
|
||||
"proguard-rules.pro"
|
||||
)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
dependencies {
|
||||
coreLibraryDesugaring("com.android.tools:desugar_jdk_libs:2.1.4")
|
||||
|
||||
implementation("com.google.android.material:material:1.12.0")
|
||||
implementation("com.github.bumptech.glide:glide:4.16.0")
|
||||
implementation("com.squareup.okhttp3:okhttp:5.1.0")
|
||||
}
|
||||
|
||||
flutter {
|
||||
source = "../.."
|
||||
}
|
||||
|
||||
|
||||
@@ -12,7 +12,12 @@
|
||||
"package_name": "dev.solsynth.solian"
|
||||
}
|
||||
},
|
||||
"oauth_client": [],
|
||||
"oauth_client": [
|
||||
{
|
||||
"client_id": "961776991058-963m1qin2vtp8fv693b5fdrab5hmpl89.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
}
|
||||
],
|
||||
"api_key": [
|
||||
{
|
||||
"current_key": "AIzaSyDvFNudXYs29uDtcCv6pFR8h5tXBs90FYk"
|
||||
@@ -20,7 +25,20 @@
|
||||
],
|
||||
"services": {
|
||||
"appinvite_service": {
|
||||
"other_platform_oauth_client": []
|
||||
"other_platform_oauth_client": [
|
||||
{
|
||||
"client_id": "961776991058-963m1qin2vtp8fv693b5fdrab5hmpl89.apps.googleusercontent.com",
|
||||
"client_type": 3
|
||||
},
|
||||
{
|
||||
"client_id": "961776991058-stt7et4qvn3cpscl4r61gl1hnlatqkig.apps.googleusercontent.com",
|
||||
"client_type": 2,
|
||||
"ios_info": {
|
||||
"bundle_id": "dev.solsynth.solian",
|
||||
"app_store_id": "6499032345"
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
5
android/app/proguard-rules.pro
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
# JNI Zero initialization (required for WebRTC native method registration)
|
||||
-keep class livekit.org.jni_zero.JniInit {
|
||||
# Keep the init method un-obfuscated for native code callback
|
||||
private static java.lang.Object[] init();
|
||||
}
|
||||
@@ -4,6 +4,7 @@
|
||||
<uses-permission android:name="android.permission.INTERNET" />
|
||||
<uses-permission android:name="android.permission.CAMERA" />
|
||||
<uses-permission android:name="android.permission.RECORD_AUDIO" />
|
||||
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
|
||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||
<uses-permission android:name="android.permission.CHANGE_NETWORK_STATE" />
|
||||
<uses-permission android:name="android.permission.MODIFY_AUDIO_SETTINGS" />
|
||||
@@ -11,6 +12,8 @@
|
||||
<uses-permission android:name="android.permission.BLUETOOTH_ADMIN" android:maxSdkVersion="30" />
|
||||
<uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE"
|
||||
android:maxSdkVersion="29" />
|
||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="android.permission.MANAGE_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
|
||||
<uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" />
|
||||
<uses-permission android:name="com.google.android.c2dm.permission.RECEIVE" />
|
||||
@@ -23,7 +26,7 @@
|
||||
<activity
|
||||
android:name=".MainActivity"
|
||||
android:exported="true"
|
||||
android:launchMode="singleInstance"
|
||||
android:launchMode="singleTask"
|
||||
android:taskAffinity=""
|
||||
android:theme="@style/LaunchTheme"
|
||||
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|smallestScreenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
|
||||
@@ -41,8 +44,77 @@
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
<category android:name="android.intent.category.LAUNCHER" />
|
||||
</intent-filter>
|
||||
|
||||
<!-- App protocol -->
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<category android:name="android.intent.category.BROWSABLE" />
|
||||
<!-- Accepts URIs that begin with YOUR_SCHEME://YOUR_HOST -->
|
||||
<data android:scheme="solian" />
|
||||
</intent-filter>
|
||||
|
||||
<!-- Deeplinking -->
|
||||
<intent-filter android:autoVerify="true">
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<category android:name="android.intent.category.BROWSABLE" />
|
||||
<data android:scheme="http" android:host="solian.app" />
|
||||
<data android:scheme="https" />
|
||||
</intent-filter>
|
||||
<intent-filter android:autoVerify="true">
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<category android:name="android.intent.category.BROWSABLE" />
|
||||
<data android:scheme="solian" />
|
||||
</intent-filter>
|
||||
|
||||
<!-- Share Intent Filters -->
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.SEND" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="image/*" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.SEND_MULTIPLE" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="image/*" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.SEND" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="video/*" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.SEND_MULTIPLE" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="video/*" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.SEND" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="text/*" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.SEND" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="application/*" />
|
||||
</intent-filter>
|
||||
<intent-filter>
|
||||
<action android:name="android.intent.action.SEND_MULTIPLE" />
|
||||
<category android:name="android.intent.category.DEFAULT" />
|
||||
<data android:mimeType="application/*" />
|
||||
</intent-filter>
|
||||
</activity>
|
||||
|
||||
<!-- Livekit Screenshare -->
|
||||
<service
|
||||
android:name="de.julianassmann.flutter_background.IsolateHolderService"
|
||||
android:enabled="true"
|
||||
android:exported="false"
|
||||
android:foregroundServiceType="mediaProjection" />
|
||||
|
||||
<!-- Sign in with Apple -->
|
||||
<activity
|
||||
android:name="com.aboutyou.dart_packages.sign_in_with_apple.SignInWithAppleCallback"
|
||||
@@ -58,6 +130,11 @@
|
||||
</intent-filter>
|
||||
</activity>
|
||||
|
||||
<receiver
|
||||
android:name=".receiver.ReplyReceiver"
|
||||
android:enabled="true"
|
||||
android:exported="true" />
|
||||
|
||||
<provider
|
||||
android:name="androidx.core.content.FileProvider"
|
||||
android:authorities="dev.solsynth.solian.provider"
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
package dev.solsynth.solian
|
||||
|
||||
import io.flutter.embedding.android.FlutterActivity
|
||||
import io.flutter.embedding.engine.FlutterEngine
|
||||
import io.flutter.plugins.sharedpreferences.LegacySharedPreferencesPlugin
|
||||
|
||||
class MainActivity : FlutterActivity()
|
||||
{
|
||||
override fun configureFlutterEngine(flutterEngine: FlutterEngine) {
|
||||
super.configureFlutterEngine(flutterEngine)
|
||||
// https://github.com/flutter/flutter/issues/153075#issuecomment-2693189362
|
||||
flutterEngine.plugins.add(LegacySharedPreferencesPlugin())
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,39 @@
|
||||
package dev.solsynth.solian
|
||||
|
||||
import android.content.Intent
|
||||
import io.flutter.embedding.android.FlutterActivity
|
||||
import io.flutter.embedding.engine.FlutterEngine
|
||||
import io.flutter.plugin.common.MethodChannel
|
||||
import io.flutter.plugins.sharedpreferences.LegacySharedPreferencesPlugin
|
||||
|
||||
class MainActivity : FlutterActivity()
|
||||
{
|
||||
private val CHANNEL = "dev.solsynth.solian/notifications"
|
||||
|
||||
override fun configureFlutterEngine(flutterEngine: FlutterEngine) {
|
||||
super.configureFlutterEngine(flutterEngine)
|
||||
// https://github.com/flutter/flutter/issues/153075#issuecomment-2693189362
|
||||
flutterEngine.plugins.add(LegacySharedPreferencesPlugin())
|
||||
|
||||
MethodChannel(flutterEngine.dartExecutor.binaryMessenger, CHANNEL).setMethodCallHandler { call, result ->
|
||||
if (call.method == "initialLink") {
|
||||
val roomId = intent.getStringExtra("room_id")
|
||||
if (roomId != null) {
|
||||
result.success("/rooms/$roomId")
|
||||
} else {
|
||||
result.success(null)
|
||||
}
|
||||
} else {
|
||||
result.notImplemented()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun onNewIntent(intent: Intent) {
|
||||
super.onNewIntent(intent)
|
||||
val roomId = intent.getStringExtra("room_id")
|
||||
if (roomId != null) {
|
||||
MethodChannel(flutterEngine!!.dartExecutor.binaryMessenger, CHANNEL).invokeMethod("newLink", "/rooms/$roomId")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,47 @@
|
||||
package dev.solsynth.solian.network
|
||||
|
||||
import android.content.Context
|
||||
import android.content.SharedPreferences
|
||||
import okhttp3.Call
|
||||
import okhttp3.Callback
|
||||
import okhttp3.MediaType.Companion.toMediaType
|
||||
import okhttp3.OkHttpClient
|
||||
import okhttp3.Request
|
||||
import okhttp3.RequestBody.Companion.toRequestBody
|
||||
import okhttp3.Response
|
||||
import org.json.JSONObject
|
||||
import java.io.IOException
|
||||
|
||||
class ApiClient(private val context: Context) {
|
||||
private val client = OkHttpClient()
|
||||
private val sharedPreferences: SharedPreferences = context.getSharedPreferences("FlutterSharedPreferences", Context.MODE_PRIVATE)
|
||||
|
||||
fun sendMessage(roomId: String, message: String, replyTo: String, callback: (Boolean) -> Unit) {
|
||||
val token = sharedPreferences.getString("flutter.token", null)
|
||||
if (token == null) {
|
||||
callback(false)
|
||||
return
|
||||
}
|
||||
|
||||
val json = JSONObject().apply {
|
||||
put("content", message)
|
||||
put("reply_to", replyTo)
|
||||
}
|
||||
val body = json.toString().toRequestBody("application/json; charset=utf-8".toMediaType())
|
||||
val request = Request.Builder()
|
||||
.url("https://solian.dev/api/rooms/$roomId/messages")
|
||||
.header("Authorization", "Bearer $token")
|
||||
.post(body)
|
||||
.build()
|
||||
|
||||
client.newCall(request).enqueue(object : Callback {
|
||||
override fun onFailure(call: Call, e: IOException) {
|
||||
callback(false)
|
||||
}
|
||||
|
||||
override fun onResponse(call: Call, response: Response) {
|
||||
callback(response.isSuccessful)
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,27 @@
|
||||
package dev.solsynth.solian.receiver
|
||||
|
||||
import android.app.NotificationManager
|
||||
import android.content.BroadcastReceiver
|
||||
import android.content.Context
|
||||
import android.content.Intent
|
||||
import androidx.core.app.RemoteInput
|
||||
import dev.solsynth.solian.network.ApiClient
|
||||
|
||||
class ReplyReceiver : BroadcastReceiver() {
|
||||
override fun onReceive(context: Context, intent: Intent) {
|
||||
val remoteInput = RemoteInput.getResultsFromIntent(intent)
|
||||
if (remoteInput != null) {
|
||||
val replyText = remoteInput.getCharSequence("key_text_reply").toString()
|
||||
val roomId = intent.getStringExtra("room_id")
|
||||
val messageId = intent.getStringExtra("message_id")
|
||||
val notificationId = intent.getIntExtra("notification_id", 0)
|
||||
|
||||
if (roomId != null && messageId != null) {
|
||||
ApiClient(context).sendMessage(roomId, replyText, messageId) {
|
||||
val notificationManager = context.getSystemService(Context.NOTIFICATION_SERVICE) as NotificationManager
|
||||
notificationManager.cancel(notificationId)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
41
android/app/src/main/res/drawable/ic_notification.xml
Normal file
@@ -0,0 +1,41 @@
|
||||
<vector xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
android:width="192dp"
|
||||
android:height="192dp"
|
||||
android:viewportWidth="192"
|
||||
android:viewportHeight="192">
|
||||
<path
|
||||
android:pathData="M54,147h86"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="12"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#000"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M57,111s-2,-4.5 -2,-10m22,22s-4,7 -11,4m9,-22s-2,-4.5 -2,-10"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="10"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#000"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M54,147a32,32 0,0 1,-12 -61.67A39,39 0,0 1,81 46m59,101a30,30 0,0 0,29.93 -28"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="12"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#000"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M132,75m-4,0a4,4 0,1 1,8 0a4,4 0,1 1,-8 0"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="8"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#000"
|
||||
android:strokeLineCap="round"/>
|
||||
<path
|
||||
android:pathData="M112.5,41.22C100.84,47.96 93,60.56 93,75c0,6.38 1.53,12.39 4.24,17.71m69.51,-35.42A38.84,38.84 0,0 1,171 75c0,14.43 -7.84,27.03 -19.49,33.78m-0.79,-43.32A20.9,20.9 0,0 1,153 75c0,7.77 -4.22,14.56 -10.49,18.19m-21,-36.38C115.22,60.44 111,67.23 111,75a20.9,20.9 0,0 0,2.28 9.53"
|
||||
android:strokeLineJoin="round"
|
||||
android:strokeWidth="10"
|
||||
android:fillColor="#00000000"
|
||||
android:strokeColor="#000"
|
||||
android:strokeLineCap="round"/>
|
||||
</vector>
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- Theme applied to the Android Window while the process is starting when the OS's Dark Mode setting is on -->
|
||||
<style name="LaunchTheme" parent="@android:style/Theme.Black.NoTitleBar">
|
||||
<style name="LaunchTheme" parent="Theme.MaterialComponents.DayNight.NoActionBar">
|
||||
<!-- Show a splash screen on the activity. Automatically removed when
|
||||
the Flutter engine draws its first frame -->
|
||||
<item name="android:windowBackground">@drawable/launch_background</item>
|
||||
@@ -16,7 +16,7 @@
|
||||
running.
|
||||
|
||||
This Theme is only used starting with V2 of Flutter's Android embedding. -->
|
||||
<style name="NormalTheme" parent="@android:style/Theme.Black.NoTitleBar">
|
||||
<style name="NormalTheme" parent="Theme.MaterialComponents.DayNight.NoActionBar">
|
||||
<item name="android:windowBackground">?android:colorBackground</item>
|
||||
</style>
|
||||
</resources>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<resources>
|
||||
<!-- Theme applied to the Android Window while the process is starting when the OS's Dark Mode setting is off -->
|
||||
<style name="LaunchTheme" parent="@android:style/Theme.Light.NoTitleBar">
|
||||
<style name="LaunchTheme" parent="Theme.MaterialComponents.Light.NoActionBar">
|
||||
<!-- Show a splash screen on the activity. Automatically removed when
|
||||
the Flutter engine draws its first frame -->
|
||||
<item name="android:windowBackground">@drawable/launch_background</item>
|
||||
@@ -16,7 +16,7 @@
|
||||
running.
|
||||
|
||||
This Theme is only used starting with V2 of Flutter's Android embedding. -->
|
||||
<style name="NormalTheme" parent="@android:style/Theme.Light.NoTitleBar">
|
||||
<style name="NormalTheme" parent="Theme.MaterialComponents.Light.NoActionBar">
|
||||
<item name="android:windowBackground">?android:colorBackground</item>
|
||||
</style>
|
||||
</resources>
|
||||
|
||||
@@ -2,4 +2,4 @@ distributionBase=GRADLE_USER_HOME
|
||||
distributionPath=wrapper/dists
|
||||
zipStoreBase=GRADLE_USER_HOME
|
||||
zipStorePath=wrapper/dists
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-all.zip
|
||||
distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-all.zip
|
||||
|
||||
@@ -18,11 +18,12 @@ pluginManagement {
|
||||
|
||||
plugins {
|
||||
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
|
||||
id("com.android.application") version "8.10.1" apply false
|
||||
id("com.android.application") version "8.12.0" apply false
|
||||
// START: FlutterFire Configuration
|
||||
id("com.google.gms.google-services") version("4.3.15") apply false
|
||||
id("com.google.firebase.crashlytics") version("2.8.1") apply false
|
||||
// END: FlutterFire Configuration
|
||||
id("org.jetbrains.kotlin.android") version "1.8.22" apply false
|
||||
id("org.jetbrains.kotlin.android") version("2.2.0") apply false
|
||||
}
|
||||
|
||||
include(":app")
|
||||
|
||||
1546
assets/i18n/es-ES.json
Normal file
1546
assets/i18n/ja-JP.json
Normal file
1546
assets/i18n/ko-KR.json
Normal file
1546
assets/i18n/zh-OG.json
Normal file
12
assets/icons/icon-outline.svg
Normal file
@@ -0,0 +1,12 @@
|
||||
<svg xmlns="http://www.w3.org/2000/svg" width="192" height="192" fill="none">
|
||||
<path stroke="#fff" stroke-linecap="round" stroke-linejoin="round" stroke-width="12"
|
||||
d="M54 147h86" />
|
||||
<path stroke="#fff" stroke-linecap="round" stroke-linejoin="round" stroke-width="10"
|
||||
d="M57 111s-2-4.5-2-10m22 22s-4 7-11 4m9-22s-2-4.5-2-10" />
|
||||
<path stroke="#fff" stroke-linecap="round" stroke-linejoin="round" stroke-width="12"
|
||||
d="M54 147a32 32 0 0 1-11.999-61.665A39 39 0 0 1 81 46m59 101a30 30 0 0 0 29.933-28" />
|
||||
<circle cx="132" cy="75" r="4" stroke="#fff" stroke-linecap="round" stroke-linejoin="round"
|
||||
stroke-width="8" />
|
||||
<path stroke="#fff" stroke-linecap="round" stroke-linejoin="round" stroke-width="10"
|
||||
d="M112.5 41.217C100.843 47.961 93 60.564 93 75c0 6.375 1.53 12.393 4.242 17.707m69.513-35.419A38.84 38.84 0 0 1 171 75c0 14.433-7.84 27.034-19.493 33.779m-.793-43.317A20.9 20.9 0 0 1 153 75c0 7.77-4.221 14.556-10.495 18.188m-21.003-36.38C115.224 60.44 111 67.226 111 75a20.9 20.9 0 0 0 2.284 9.533" />
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.0 KiB |
BIN
assets/icons/icon-tray.png
Normal file
|
After Width: | Height: | Size: 63 KiB |
BIN
assets/icons/icon.ico
Normal file
|
After Width: | Height: | Size: 108 KiB |
BIN
assets/images/media-offline.jpg
Normal file
|
After Width: | Height: | Size: 461 KiB |
10
assets/images/oidc/afdian.svg
Normal file
@@ -0,0 +1,10 @@
|
||||
<svg
|
||||
viewBox="0 0 160 160"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
>
|
||||
<path
|
||||
fill-rule="evenodd"
|
||||
d="M134.614 98.3714C133.294 97.5334 131.909 97.1697 130.563 97.02C133.724 89.3002 135.736 79.1949 128.887 69.1574C118.406 53.7998 103.38 45.8198 84.2346 45.4382C78.7809 45.3312 72.3517 45.5844 65.5487 45.8554C57.6493 46.1692 47.1369 46.5793 39.9921 45.9873C41.4161 45.2136 42.9326 44.4719 44.2462 43.8336C49.2728 41.384 53.2314 39.4763 51.9214 36.0925C51.2343 34.117 49.1874 33.0794 45.8233 33.0045C38.7426 32.8441 23.4421 36.9447 20.6903 43.8586C19.1418 47.7524 18.8854 55.2689 34.5668 61.9119C41.0174 64.6503 59.237 67.9879 66.2678 68.6867C68.2542 68.8793 69.7743 69.2822 70.9277 69.7101C69.3151 70.7727 67.6597 71.8888 65.9972 73.0298C63.1102 71.3824 58.3897 69.4391 54.8654 71.846C53.502 72.7695 52.7259 74.1316 52.6903 75.6827C52.6405 77.6117 53.8081 79.498 55.1217 81.017C49.9314 85.1639 45.7343 89.1825 44.2462 92.2811C42.5873 96.0893 41.9109 102.322 45.008 108.402C48.9382 116.118 57.6279 121.499 70.8423 124.394C88.1114 128.17 103.027 124.768 112.895 119.566C118.388 116.671 122.286 113.215 124.18 110.131C124.768 110.317 125.355 110.506 125.96 110.695C126.804 110.951 127.648 111.208 128.438 111.49C131.051 112.395 133.942 112.274 136.167 111.151C136.206 111.133 136.248 111.108 136.291 111.087C137.968 110.202 139.175 108.783 139.705 107.072C141.129 102.458 137.064 99.9082 134.614 98.3714ZM64.9999 90.6681C63.4307 90.6681 62.1621 91.9382 62.1621 93.5091C62.1621 95.0836 63.4307 96.3537 64.9999 96.3537C66.5691 96.3537 67.8378 95.0836 67.8378 93.5091C67.8378 91.9382 66.5691 90.6681 64.9999 90.6681ZM91.7568 99.1965C90.1876 99.1965 88.9189 100.467 88.9189 102.038C88.9189 103.612 90.1876 104.882 91.7568 104.882C93.326 104.882 94.5946 103.612 94.5946 102.038C94.5946 100.467 93.326 99.1965 91.7568 99.1965Z"
|
||||
fill="currentColor"
|
||||
/>
|
||||
</svg>
|
||||
|
After Width: | Height: | Size: 1.8 KiB |
BIN
assets/images/oidc/spotify.png
Normal file
|
After Width: | Height: | Size: 23 KiB |
1
assets/images/oidc/steam.svg
Normal file
@@ -0,0 +1 @@
|
||||
<svg width="2471" height="2500" viewBox="0 0 256 259" xmlns="http://www.w3.org/2000/svg" preserveAspectRatio="xMidYMid"><path d="M127.779 0C60.42 0 5.24 52.412 0 119.014l68.724 28.674a35.812 35.812 0 0 1 20.426-6.366c.682 0 1.356.019 2.02.056l30.566-44.71v-.626c0-26.903 21.69-48.796 48.353-48.796 26.662 0 48.352 21.893 48.352 48.796 0 26.902-21.69 48.804-48.352 48.804-.37 0-.73-.009-1.098-.018l-43.593 31.377c.028.582.046 1.163.046 1.735 0 20.204-16.283 36.636-36.294 36.636-17.566 0-32.263-12.658-35.584-29.412L4.41 164.654c15.223 54.313 64.673 94.132 123.369 94.132 70.818 0 128.221-57.938 128.221-129.393C256 57.93 198.597 0 127.779 0zM80.352 196.332l-15.749-6.568c2.787 5.867 7.621 10.775 14.033 13.47 13.857 5.83 29.836-.803 35.612-14.799a27.555 27.555 0 0 0 .046-21.035c-2.768-6.79-7.999-12.086-14.706-14.909-6.67-2.795-13.811-2.694-20.085-.304l16.275 6.79c10.222 4.3 15.056 16.145 10.794 26.46-4.253 10.314-15.998 15.195-26.22 10.895zm121.957-100.29c0-17.925-14.457-32.52-32.217-32.52-17.769 0-32.226 14.595-32.226 32.52 0 17.926 14.457 32.512 32.226 32.512 17.76 0 32.217-14.586 32.217-32.512zm-56.37-.055c0-13.488 10.84-24.42 24.2-24.42 13.368 0 24.208 10.932 24.208 24.42 0 13.488-10.84 24.421-24.209 24.421-13.359 0-24.2-10.933-24.2-24.42z" fill="#1A1918"/></svg>
|
||||
|
After Width: | Height: | Size: 1.2 KiB |
BIN
assets/images/stickers/angry.png
Normal file
|
After Width: | Height: | Size: 1.0 MiB |
BIN
assets/images/stickers/clap.png
Normal file
|
After Width: | Height: | Size: 1.0 MiB |
BIN
assets/images/stickers/confuse.png
Normal file
|
After Width: | Height: | Size: 668 KiB |
BIN
assets/images/stickers/party.png
Normal file
|
After Width: | Height: | Size: 1.1 MiB |
BIN
assets/images/stickers/pray.png
Normal file
|
After Width: | Height: | Size: 666 KiB |
BIN
assets/images/stickers/thumb_up.png
Normal file
|
After Width: | Height: | Size: 623 KiB |
@@ -5,3 +5,7 @@ targets:
|
||||
options:
|
||||
explicit_to_json: true
|
||||
field_rename: snake
|
||||
drift_dev:
|
||||
options:
|
||||
databases:
|
||||
app_database: lib/database/drift_db.dart
|
||||
|
||||
2
crowdin.yml
Normal file
@@ -0,0 +1,2 @@
|
||||
bundles:
|
||||
- 6
|
||||
@@ -1,3 +1,6 @@
|
||||
description: This file stores settings for Dart & Flutter DevTools.
|
||||
documentation: https://docs.flutter.dev/tools/devtools/extensions#configure-extension-enablement-states
|
||||
extensions:
|
||||
- drift: true
|
||||
- provider: true
|
||||
- shared_preferences: true
|
||||
287
docs/activitypub/ACTIVITYPUB_IMPLEMENTATION.md
Normal file
@@ -0,0 +1,287 @@
|
||||
# ActivityPub Implementation for Solar Network
|
||||
|
||||
## Overview
|
||||
|
||||
This document outlines the initial implementation of ActivityPub federation for the Solar Network (DysonNetwork), following the plan outlined in `ACTIVITYPUB_PLAN.md`.
|
||||
|
||||
## What Has Been Created
|
||||
|
||||
### 1. Database Models (DysonNetwork.Shared/Models)
|
||||
|
||||
All ActivityPub-related models are shared across projects and located in `DysonNetwork.Shared/Models/`:
|
||||
|
||||
#### FediverseInstance.cs
|
||||
- Tracks ActivityPub instances (servers) in the fediverse
|
||||
- Stores instance metadata, blocking status, and activity tracking
|
||||
- Links to actors and content from that instance
|
||||
|
||||
#### FediverseActor.cs
|
||||
- Represents remote actors (users/accounts) from other instances
|
||||
- Stores actor information including keys, inbox/outbox URLs
|
||||
- Links to instance and manages relationships
|
||||
- Tracks whether the actor is a bot, locked, or discoverable
|
||||
|
||||
#### FediverseContent.cs
|
||||
- Stores content (posts, notes, etc.) received from the fediverse
|
||||
- Supports multiple content types (Note, Article, Image, Video, etc.)
|
||||
- Includes attachments, mentions, tags, and emojis
|
||||
- Links to local posts for unified display
|
||||
|
||||
#### FediverseActivity.cs
|
||||
- Tracks ActivityPub activities (Create, Follow, Like, Announce, etc.)
|
||||
- Stores raw activity data and processing status
|
||||
- Links to actors, content, and local entities
|
||||
- Supports both incoming and outgoing activities
|
||||
|
||||
#### FediverseRelationship.cs
|
||||
- Manages follow relationships between local and remote actors
|
||||
- Tracks relationship state (Pending, Accepted, Rejected)
|
||||
- Supports muting and blocking
|
||||
- Links to local accounts/publishers
|
||||
|
||||
#### FediverseReaction.cs
|
||||
- Stores reactions (likes, emoji) from both local and remote actors
|
||||
- Links to content and actor
|
||||
- Supports federation of reactions
|
||||
|
||||
### 2. Database Migration
|
||||
|
||||
**File**: `DysonNetwork.Sphere/Migrations/20251228120000_AddActivityPubModels.cs`
|
||||
|
||||
This migration creates the following tables:
|
||||
- `fediverse_instances` - Instance tracking
|
||||
- `fediverse_actors` - Remote actor profiles
|
||||
- `fediverse_contents` - Federated content storage
|
||||
- `fediverse_activities` - Activity tracking and processing
|
||||
- `fediverse_relationships` - Follow relationships
|
||||
- `fediverse_reactions` - Reactions from fediverse
|
||||
|
||||
### 3. API Controllers (DysonNetwork.Sphere/ActivityPub)
|
||||
|
||||
#### WebFingerController.cs
|
||||
- **Endpoint**: `GET /.well-known/webfinger?resource=acct:<username>@<domain>`
|
||||
- **Purpose**: Allows other instances to discover actors via WebFinger protocol
|
||||
- **Response**: Returns actor's inbox/outbox URLs and profile page links
|
||||
- Maps local Publishers to ActivityPub actors
|
||||
|
||||
#### ActivityPubController.cs
|
||||
Provides three main endpoints:
|
||||
|
||||
1. **GET /activitypub/actors/{username}**
|
||||
- Returns ActivityPub actor profile in JSON-LD format
|
||||
- Includes actor's keys, inbox, outbox, followers, and following URLs
|
||||
- Maps SnPublisher to ActivityPub Person type
|
||||
|
||||
2. **GET /activitypub/actors/{username}/outbox**
|
||||
- Returns actor's outbox collection
|
||||
- Lists public posts as ActivityPub activities
|
||||
- Supports pagination
|
||||
|
||||
3. **POST /activitypub/actors/{username}/inbox**
|
||||
- Receives incoming ActivityPub activities
|
||||
- Supports Create, Follow, Like, Announce activities
|
||||
- Placeholder for activity processing logic
|
||||
|
||||
## Architecture
|
||||
|
||||
### Data Flow
|
||||
|
||||
```
|
||||
Remote Instance Solar Network (Sphere)
|
||||
│ │
|
||||
│ ───WebFinger─────> │
|
||||
│ │
|
||||
│ <───Actor JSON──── │
|
||||
│ │
|
||||
│ ───Activity─────> │ → Inbox Processing
|
||||
│ │
|
||||
│ <───Activity────── │ ← Outbox Distribution
|
||||
```
|
||||
|
||||
### Model Relationships
|
||||
|
||||
- `SnFediverseInstance` has many `SnFediverseActor`
|
||||
- `SnFediverseInstance` has many `SnFediverseContent`
|
||||
- `SnFediverseActor` has many `SnFediverseContent`
|
||||
- `SnFediverseActor` has many `SnFediverseActivity`
|
||||
- `SnFediverseActor` has many `SnFediverseRelationship` (as follower and following)
|
||||
- `SnFediverseContent` has many `SnFediverseActivity`
|
||||
- `SnFediverseContent` has many `SnFediverseReaction`
|
||||
- `SnFediverseContent` optionally links to `SnPost` (local copy)
|
||||
|
||||
### Local to Fediverse Mapping
|
||||
|
||||
| Solar Network Model | ActivityPub Type |
|
||||
|-------------------|-----------------|
|
||||
| SnPublisher | Person (Actor) |
|
||||
| SnPost | Note / Article |
|
||||
| SnPostReaction | Like / EmojiReact |
|
||||
| Follow | Follow Activity |
|
||||
| SnPublisherSubscription | Follow Relationship |
|
||||
|
||||
## Next Steps
|
||||
|
||||
### Stage 1: Core Infrastructure ✅ (COMPLETED)
|
||||
- ✅ Create database models for ActivityPub entities
|
||||
- ✅ Create database migration
|
||||
- ✅ Implement basic WebFinger endpoint
|
||||
- ✅ Implement basic Actor endpoint
|
||||
- ✅ Implement Inbox/Outbox endpoints
|
||||
|
||||
### Stage 2: Activity Processing ✅ (COMPLETED)
|
||||
- ✅ Implement HTTP Signature verification (ActivityPubSignatureService)
|
||||
- ✅ Process incoming activities:
|
||||
- Follow/Accept/Reject
|
||||
- Create (incoming posts)
|
||||
- Like/Announce
|
||||
- Delete/Update
|
||||
- Undo
|
||||
- ✅ Generate outgoing activities (ActivityPubDeliveryService)
|
||||
- ✅ Queue and retry failed deliveries (basic implementation)
|
||||
|
||||
### Stage 3: Key Management ✅ (COMPLETED)
|
||||
- ✅ Generate RSA key pairs for each Publisher (ActivityPubKeyService)
|
||||
- ✅ Store public/private keys in Publisher.Meta
|
||||
- ✅ Sign outgoing HTTP requests
|
||||
- ✅ Verify incoming HTTP signatures
|
||||
|
||||
### Stage 4: Content Federation (IN PROGRESS)
|
||||
- ✅ Convert between SnPost and ActivityPub Note/Article (basic mapping)
|
||||
- ✅ Handle content attachments and media
|
||||
- ✅ Support content warnings and sensitive content
|
||||
- ✅ Handle replies, boosts, and mentions
|
||||
- ⏳ Add local post reference for federated content
|
||||
- ⏳ Handle media attachments in federated content
|
||||
|
||||
### Stage 5: Relationship Management ✅ (COMPLETED)
|
||||
- ✅ Handle follow/unfollow logic
|
||||
- ✅ Update followers/following collections
|
||||
- ✅ Block/mute functionality (data model ready)
|
||||
- ✅ Relationship state machine (Pending, Accepted, Rejected)
|
||||
|
||||
### Stage 6: Testing & Interop (NEXT)
|
||||
- ⏳ Test with Mastodon instances
|
||||
- ⏳ Test with Pleroma/Akkoma instances
|
||||
- ⏳ Test with Lemmy instances
|
||||
- ⏳ Verify WebFinger and actor discovery
|
||||
- ⏳ Test activity delivery and processing
|
||||
|
||||
## Implementation Details
|
||||
|
||||
### Core Services
|
||||
|
||||
#### 1. ActivityPubKeyService
|
||||
- Generates RSA 2048-bit key pairs for ActivityPub
|
||||
- Signs data with private key
|
||||
- Verifies signatures with public key
|
||||
- Key stored in `SnPublisher.Meta["private_key"]` and `["public_key"]`
|
||||
|
||||
#### 2. ActivityPubSignatureService
|
||||
- Verifies incoming HTTP Signature headers
|
||||
- Signs outgoing HTTP requests
|
||||
- Manages key retrieval and storage
|
||||
- Builds signing strings according to ActivityPub spec
|
||||
|
||||
#### 3. ActivityPubActivityProcessor
|
||||
- Processes all incoming activity types
|
||||
- Follow: Creates relationship, sends Accept
|
||||
- Accept: Updates relationship to accepted state
|
||||
- Reject: Updates relationship to rejected state
|
||||
- Create: Stores federated content
|
||||
- Like: Records like reaction
|
||||
- Announce: Increments boost count
|
||||
- Undo: Reverts previous actions
|
||||
- Delete: Soft-deletes federated content
|
||||
- Update: Marks content as edited
|
||||
|
||||
#### 4. ActivityPubDeliveryService
|
||||
- Sends Follow activities to remote instances
|
||||
- Sends Accept activities in response to follows
|
||||
- Sends Create activities (posts) to followers
|
||||
- Sends Like activities to remote instances
|
||||
- Sends Undo activities
|
||||
- Fetches remote actor profiles on-demand
|
||||
|
||||
### Data Flow
|
||||
|
||||
#### Incoming Activity Flow
|
||||
```
|
||||
Remote Server → HTTP Signature Verification → Activity Type → Specific Handler
|
||||
↓
|
||||
Database Update & Response
|
||||
```
|
||||
|
||||
#### Outgoing Activity Flow
|
||||
```
|
||||
Local Action → Create Activity → Sign with Key → Send to Followers' Inboxes
|
||||
↓
|
||||
Track Status & Retry
|
||||
```
|
||||
|
||||
## Configuration
|
||||
|
||||
Add to `appsettings.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"ActivityPub": {
|
||||
"Domain": "your-domain.com",
|
||||
"EnableFederation": true
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## Database Migration
|
||||
|
||||
To apply the migration:
|
||||
|
||||
```bash
|
||||
cd DysonNetwork.Sphere
|
||||
dotnet ef database update
|
||||
```
|
||||
|
||||
## Testing
|
||||
|
||||
### WebFinger
|
||||
```bash
|
||||
curl "https://your-domain.com/.well-known/webfinger?resource=acct:username@your-domain.com"
|
||||
```
|
||||
|
||||
### Actor Profile
|
||||
```bash
|
||||
curl -H "Accept: application/activity+json" https://your-domain.com/activitypub/actors/username
|
||||
```
|
||||
|
||||
### Outbox
|
||||
```bash
|
||||
curl -H "Accept: application/activity+json" https://your-domain.com/activitypub/actors/username/outbox
|
||||
```
|
||||
|
||||
## Notes
|
||||
|
||||
- All models follow the existing Solar Network patterns (ModelBase, NodaTime, JSON columns)
|
||||
- Controllers use standard ASP.NET Core patterns with dependency injection
|
||||
- Database uses PostgreSQL with JSONB for flexible metadata storage
|
||||
- Migration follows existing naming conventions
|
||||
- Soft delete is enabled on all models
|
||||
|
||||
## References
|
||||
|
||||
- [ActivityPub W3C Recommendation](https://www.w3.org/TR/activitypub/)
|
||||
- [ActivityStreams 2.0](https://www.w3.org/TR/activitystreams-core/)
|
||||
- [WebFinger RFC 7033](https://tools.ietf.org/html/rfc7033)
|
||||
- [Mastodon Federation Documentation](https://docs.joinmastodon.org/spec/activitypub/)
|
||||
|
||||
## TODOs
|
||||
|
||||
- [ ] Implement HTTP Signature verification middleware
|
||||
- [ ] Create activity processor service
|
||||
- [ ] Implement activity queue and retry logic
|
||||
- [ ] Add key generation for Publishers
|
||||
- [ ] Implement content conversion between formats
|
||||
- [ ] Add inbox background worker
|
||||
- [ ] Add outbox delivery worker
|
||||
- [ ] Implement relationship management logic
|
||||
- [ ] Add moderation tools for federated content
|
||||
- [ ] Add federation metrics and monitoring
|
||||
- [ ] Write comprehensive tests
|
||||
197
docs/activitypub/ACTIVITYPUB_PLAN.md
Normal file
@@ -0,0 +1,197 @@
|
||||
🛠️ ActivityPub 接入 Solar Network 的分步清单
|
||||
|
||||
⸻
|
||||
|
||||
🧱 1. 准备 & 设计阶段
|
||||
|
||||
1.1 理解 ActivityPub 的核心概念
|
||||
• Actor / Object / Activity / Collection
|
||||
• Outbox / Inbox / Followers 列表
|
||||
ActivityPub 是使用 JSON-LD + ActivityStreams 2.0 来描述社交行为的规范。 
|
||||
|
||||
1.2 映射你现有的 Solar Domain 结构
|
||||
|
||||
把你现在 Solar Network 的用户、帖子、关注、点赞等:
|
||||
• 映射为 ActivityPub 的 Actor / Note / Follow / Like 等
|
||||
• 明确本地模型与 ActivityStreams 对应关系
|
||||
|
||||
比如:
|
||||
• Solar User → ActivityPub Actor
|
||||
• Post → ActivityPub Note/Object
|
||||
• Like → ActivityPub Like Activity
|
||||
这一步是关键的领域建模设计。
|
||||
|
||||
⸻
|
||||
|
||||
🚪 2. Actor 发现与必要入口
|
||||
|
||||
2.1 实现 WebFinger
|
||||
|
||||
为每个用户提供 WebFinger endpoint:
|
||||
|
||||
GET /.well-known/webfinger?resource=acct:<username>@<domain>
|
||||
|
||||
用来让远端服务器查出 actor 细节(包括 inbox/outbox URL)。
|
||||
|
||||
2.2 Actor 资源 URL
|
||||
|
||||
确保每个用户有一个全局可访问的 URL,例如:
|
||||
|
||||
https://solar.io/users/alice
|
||||
|
||||
并在其 JSON-LD 中包含:
|
||||
• inbox
|
||||
• outbox
|
||||
• followers
|
||||
• following
|
||||
这些是 ActivityPub 基础通信的入口。 
|
||||
|
||||
⸻
|
||||
|
||||
📮 3. 核心协议实现
|
||||
|
||||
3.1 Inbox / Outbox 接口
|
||||
|
||||
Inbox(接收来自其他实例的 Activity)
|
||||
Outbox(本地用户发布 Activity 的出口)
|
||||
|
||||
Outbox 需要:
|
||||
• 生成 activity JSON(Create、Follow、Like 等)
|
||||
• 存储至本地数据库
|
||||
• 推送到各 follower 的 Inbox
|
||||
|
||||
Inbox 需要:
|
||||
• 接收并 parse Activity
|
||||
• 验证签名
|
||||
• 处理活动(如接受 Follow,记录远程 Post 等)
|
||||
|
||||
注意:
|
||||
• 请求需要验证 HTTP Signatures(远端服务器签名)。 
|
||||
• 必须满足 ActivityPub 规范对字段的要求。
|
||||
|
||||
⸻
|
||||
|
||||
🔐 4. 安全与签名
|
||||
|
||||
4.1 Actor Keys
|
||||
|
||||
每个 Actor 对应一对 RSA / Ed25519 密钥:
|
||||
• 私钥用于签名发送到其它服务器的请求
|
||||
• 公钥发布在 Actor JSON 中供对方验证
|
||||
|
||||
远端服务器发送到你的 Inbox 时,需要:
|
||||
• 使用对方的公钥验证签名
|
||||
|
||||
HTTP Signatures 是服务器间通信安全的一部分,防止伪造请求。 
|
||||
|
||||
⸻
|
||||
|
||||
🌐 5. 实现联邦逻辑
|
||||
|
||||
5.1 关注逻辑
|
||||
|
||||
处理:
|
||||
• Follow Activity
|
||||
• Accept / Reject Activity
|
||||
• 更新本地 followers / following 数据
|
||||
|
||||
实现流程参考:1. 本地用户发起 Follow 2. 推送 Follow 到远端 Inbox 3. 等待远端发送 Accept 或 Reject
|
||||
|
||||
5.2 推送 content(联邦同步)
|
||||
|
||||
当本地用户发布内容时:
|
||||
• 从 Outbox 取出 Create Activity
|
||||
• 发送到所有远端 followers 的 Inbox
|
||||
注意:你可以缓存远端 followers 数据表来减少重复请求。
|
||||
|
||||
⸻
|
||||
|
||||
📡 6. 消息处理与存储
|
||||
|
||||
6.1 本地对象缓存
|
||||
|
||||
对于接收到的远端内容(Post / Note / Like 等):
|
||||
• 需要保存到 Solar 的数据库
|
||||
• 供 UI / API 生成用户时间线
|
||||
这使得 Solar 能把远端联邦内容与本地内容统一展示。
|
||||
|
||||
6.2 处理 Collections
|
||||
|
||||
ActivityPub 定义了 Collection 类型用于:
|
||||
• followers 列表
|
||||
• liked 列表
|
||||
• outbox、inbox
|
||||
|
||||
你需要实现这些集合的获取与分页逻辑。
|
||||
|
||||
⸻
|
||||
|
||||
🔁 7. 与现有 Solar Network API 协调
|
||||
|
||||
你可能已经有本地的帖子、用户 API。那么:
|
||||
• 把这套 API 与 ActivityPub 同步层绑定
|
||||
• 决定哪些内容对外发布
|
||||
• 决定哪些 Activity 类型需要响应
|
||||
|
||||
比如:
|
||||
|
||||
Solar Post Create -> 生成 ActivityPub Create Note -> 发往联邦
|
||||
|
||||
⸻
|
||||
|
||||
📦 8. 测试与兼容性
|
||||
|
||||
8.1 与现存联邦测试
|
||||
|
||||
用已存在的 ActivityPub 实例测试兼容性:
|
||||
• Mastodon
|
||||
• Pleroma
|
||||
• Lemmy 等
|
||||
|
||||
检查:
|
||||
• 对方是否能关注 Solar 用户
|
||||
• Solar 是否能接收远端内容
|
||||
|
||||
ActivityPub 规范(W3C Recommendation)有详细规范流包括:
|
||||
• Server to Server API
|
||||
你最重要的目标是与现存实例互操作。 
|
||||
|
||||
⸻
|
||||
|
||||
🧪 9. UX & 监控支持
|
||||
|
||||
9.1 用户显示远端内容
|
||||
|
||||
从 Inbox 收到内容后:
|
||||
• 如何展示在 Solar UI
|
||||
• 链接远端用户的展示名 / 头像
|
||||
|
||||
9.2 监控 & 审计
|
||||
• 失败的推送
|
||||
• 无法验证签名的请求
|
||||
• 阻止 spam / 恶意 Activity
|
||||
|
||||
⸻
|
||||
|
||||
🏁 10. 逐步推进
|
||||
|
||||
建议按阶段 rollout:
|
||||
|
||||
阶段 目标
|
||||
Stage 1 实现 Actor / WebFinger / Outbox / Inbox 基本框架
|
||||
Stage 2 支持 Follow / Accept / Reject Activity
|
||||
Stage 3 支持 Create / Like / Announce
|
||||
Stage 4 与远端实例互联测试
|
||||
Stage 5 UI & Feed 统一显示本地 + 联邦内容
|
||||
|
||||
⸻
|
||||
|
||||
📌 小结
|
||||
|
||||
核心步骤总结:1. 映射 Solar Network 数据模型到 ActivityPub 2. 实现 WebFinger + Actor JSON-LD 3. 实现 Inbox 和 Outbox endpoints 4. 管理 Actor Keys 与 HTTP Signatures 5. 处理关注/发帖/点赞等 Activity 6. 推送到远端 / 接收远端同步 7. 将远端内容存入 Solar 并展示 8. 测试与现有 Fediverse 实例互通
|
||||
|
||||
这套步骤覆盖了 ActivityPub 协议必须实现的点和实际联邦要处理的逻辑。 
|
||||
|
||||
⸻
|
||||
|
||||
如果你想,我可以进一步展开 Solar Network 对应的具体 API 设计模板(包括 Inbox / Outbox 的 REST 定义与 JSON 输出示例),甚至帮你写 可运行的 Go / .NET 样例代码。你希望从哪一部分开始深入?
|
||||
273
docs/activitypub/ACTIVITYPUB_SUMMARY.md
Normal file
@@ -0,0 +1,273 @@
|
||||
# ActivityPub Implementation Summary
|
||||
|
||||
## What Has Been Implemented
|
||||
|
||||
### 1. Database Models ✅
|
||||
All models located in `DysonNetwork.Shared/Models/`:
|
||||
|
||||
| Model | Purpose | Key Features |
|
||||
|--------|---------|--------------|
|
||||
| `SnFediverseInstance` | Track fediverse servers | Domain blocking, metadata, activity tracking |
|
||||
| `SnFediverseActor` | Remote user profiles | Keys, inbox/outbox URLs, relationships |
|
||||
| `SnFediverseContent` | Federated posts/notes | Multiple content types, attachments, mentions, tags |
|
||||
| `SnFediverseActivity` | Activity tracking | All activity types, processing status, raw data |
|
||||
| `SnFediverseRelationship` | Follow relationships | State machine, muting/blocking |
|
||||
| `SnFediverseReaction` | Federated reactions | Likes, emoji reactions |
|
||||
|
||||
### 2. Database Migrations ✅
|
||||
- `20251228120000_AddActivityPubModels.cs` - Core ActivityPub tables
|
||||
- `20251228130000_AddPublisherMetaForActivityPubKeys.cs` - Publisher metadata for keys
|
||||
|
||||
### 3. Core Services ✅
|
||||
|
||||
#### ActivityPubKeyService
|
||||
- **Location**: `DysonNetwork.Sphere/ActivityPub/ActivityPubKeyService.cs`
|
||||
- **Responsibilities**:
|
||||
- Generate RSA 2048-bit key pairs
|
||||
- Sign data with private key
|
||||
- Verify signatures with public key
|
||||
- **Key Storage**: Keys stored in `SnPublisher.Meta`
|
||||
|
||||
#### ActivityPubSignatureService
|
||||
- **Location**: `DysonNetwork.Sphere/ActivityPub/ActivityPubSignatureService.cs`
|
||||
- **Responsibilities**:
|
||||
- Verify incoming HTTP Signature headers
|
||||
- Sign outgoing HTTP requests
|
||||
- Build signing strings per ActivityPub spec
|
||||
- Manage key retrieval for actors
|
||||
- **Signature Algorithm**: RSA-SHA256
|
||||
|
||||
#### ActivityPubActivityProcessor
|
||||
- **Location**: `DysonNetwork.Sphere/ActivityPub/ActivityPubActivityProcessor.cs`
|
||||
- **Supported Activities**:
|
||||
- ✅ Follow - Creates relationship, sends Accept
|
||||
- ✅ Accept - Updates relationship to accepted
|
||||
- ✅ Reject - Updates relationship to rejected
|
||||
- ✅ Create - Stores federated content
|
||||
- ✅ Like - Records like reaction
|
||||
- ✅ Announce - Increments boost count
|
||||
- ✅ Undo - Reverts previous actions
|
||||
- ✅ Delete - Soft-deletes federated content
|
||||
- ✅ Update - Marks content as edited
|
||||
|
||||
#### ActivityPubDeliveryService
|
||||
- **Location**: `DysonNetwork.Sphere/ActivityPub/ActivityPubDeliveryService.cs`
|
||||
- **Outgoing Activities**:
|
||||
- ✅ Follow - Send to remote actors
|
||||
- ✅ Accept - Respond to follow requests
|
||||
- ✅ Create - Send new posts to followers
|
||||
- ✅ Like - Send to remote instances
|
||||
- ✅ Undo - Undo previous actions
|
||||
- **Features**:
|
||||
- HTTP signature signing
|
||||
- Remote actor fetching
|
||||
- Follower discovery
|
||||
|
||||
### 4. API Controllers ✅
|
||||
|
||||
#### WebFingerController
|
||||
- **Location**: `DysonNetwork.Sphere/ActivityPub/WebFingerController.cs`
|
||||
- **Endpoints**:
|
||||
- `GET /.well-known/webfinger?resource=acct:<username>@<domain>`
|
||||
- **Purpose**: Allow remote instances to discover local actors
|
||||
|
||||
#### ActivityPubController
|
||||
- **Location**: `DysonNetwork.Sphere/ActivityPub/ActivityPubController.cs`
|
||||
- **Endpoints**:
|
||||
- `GET /activitypub/actors/{username}` - Actor profile in JSON-LD
|
||||
- `GET /activitypub/actors/{username}/outbox` - Public posts
|
||||
- `POST /activitypub/actors/{username}/inbox` - Receive activities
|
||||
- **Features**:
|
||||
- Public key in actor profile
|
||||
- ActivityPub JSON-LD responses
|
||||
- HTTP signature verification on inbox
|
||||
- Activity processing pipeline
|
||||
|
||||
### 5. Model Updates ✅
|
||||
- Added `Meta` field to `SnPublisher` for storing ActivityPub keys
|
||||
- All models follow existing Solar Network patterns
|
||||
|
||||
## How It Works
|
||||
|
||||
### Incoming Activity Flow
|
||||
```
|
||||
1. Remote server sends POST to /inbox
|
||||
2. HTTP Signature is verified
|
||||
3. Activity type is identified
|
||||
4. Specific handler processes activity:
|
||||
- Follow: Create relationship, send Accept
|
||||
- Create: Store content
|
||||
- Like: Record reaction
|
||||
- etc.
|
||||
5. Database is updated
|
||||
6. Response sent
|
||||
```
|
||||
|
||||
### Outgoing Activity Flow
|
||||
```
|
||||
1. Local action occurs (post, like, follow)
|
||||
2. Activity is created in ActivityPub format
|
||||
3. Remote followers are discovered
|
||||
4. HTTP request is signed with publisher's private key
|
||||
5. Activity sent to each follower's inbox
|
||||
6. Status logged
|
||||
```
|
||||
|
||||
### Key Management
|
||||
```
|
||||
1. Publisher creates post/follows
|
||||
2. Check if keys exist in Publisher.Meta
|
||||
3. If not, generate RSA 2048-bit key pair
|
||||
4. Store keys in Publisher.Meta
|
||||
5. Use keys for signing
|
||||
```
|
||||
|
||||
## Configuration
|
||||
|
||||
Add to `appsettings.json`:
|
||||
```json
|
||||
{
|
||||
"ActivityPub": {
|
||||
"Domain": "your-domain.com",
|
||||
"EnableFederation": true
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
## API Endpoints
|
||||
|
||||
### WebFinger
|
||||
```bash
|
||||
GET /.well-known/webfinger?resource=acct:username@domain.com
|
||||
Accept: application/jrd+json
|
||||
```
|
||||
|
||||
### Actor Profile
|
||||
```bash
|
||||
GET /activitypub/actors/username
|
||||
Accept: application/activity+json
|
||||
```
|
||||
|
||||
### Outbox
|
||||
```bash
|
||||
GET /activitypub/actors/username/outbox
|
||||
Accept: application/activity+json
|
||||
```
|
||||
|
||||
### Inbox
|
||||
```bash
|
||||
POST /activitypub/actors/username/inbox
|
||||
Content-Type: application/activity+json
|
||||
Signature: keyId="...",algorithm="...",headers="...",signature="..."
|
||||
```
|
||||
|
||||
## Database Schema
|
||||
|
||||
### Fediverse Tables
|
||||
- `fediverse_instances` - Server metadata and blocking
|
||||
- `fediverse_actors` - Remote actor profiles
|
||||
- `fediverse_contents` - Federated posts/notes
|
||||
- `fediverse_activities` - Activity tracking
|
||||
- `fediverse_relationships` - Follow relationships
|
||||
- `fediverse_reactions` - Federated reactions
|
||||
|
||||
### Publisher Enhancement
|
||||
- Added `publishers.meta` JSONB column for key storage
|
||||
|
||||
## Next Steps
|
||||
|
||||
### Immediate (Ready for Testing)
|
||||
- Apply database migrations
|
||||
- Test WebFinger with a Mastodon instance
|
||||
- Test follow/unfollow with another instance
|
||||
- Test receiving posts from federated timeline
|
||||
|
||||
### Short Term
|
||||
- Add HTTP Signature verification middleware
|
||||
- Implement activity queue with retry logic
|
||||
- Add background worker for processing queued activities
|
||||
- Add metrics and monitoring
|
||||
- Implement local content display in timelines
|
||||
|
||||
### Long Term
|
||||
- Add Media support for federated content
|
||||
- Implement content filtering
|
||||
- Add moderation tools for federated content
|
||||
- Support more activity types
|
||||
- Implement instance block list management
|
||||
|
||||
## Compatibility
|
||||
|
||||
The implementation follows:
|
||||
- ✅ [ActivityPub W3C Recommendation](https://www.w3.org/TR/activitypub/)
|
||||
- ✅ [ActivityStreams 2.0](https://www.w3.org/TR/activitystreams-core/)
|
||||
- ✅ [WebFinger RFC 7033](https://tools.ietf.org/html/rfc7033)
|
||||
- ✅ [HTTP Signatures](https://datatracker.ietf.org/doc/html/draft-cavage-http-signatures)
|
||||
|
||||
## Testing
|
||||
|
||||
### Local Testing
|
||||
```bash
|
||||
# 1. Apply migrations
|
||||
cd DysonNetwork.Sphere
|
||||
dotnet ef database update
|
||||
|
||||
# 2. Test WebFinger
|
||||
curl "http://localhost:5000/.well-known/webfinger?resource=acct:username@localhost"
|
||||
|
||||
# 3. Test Actor
|
||||
curl -H "Accept: application/activity+json" http://localhost:5000/activitypub/actors/username
|
||||
```
|
||||
|
||||
### Federation Testing
|
||||
1. Set up a Mastodon instance (or use a public one)
|
||||
2. Follow a Mastodon user from Solar Network
|
||||
3. Create a post on Solar Network
|
||||
4. Verify it appears on Mastodon timeline
|
||||
|
||||
## Architecture Decisions
|
||||
|
||||
1. **Key Storage**: Using `SnPublisher.Meta` JSONB field for flexibility
|
||||
2. **Content Storage**: Federated content stored separately from local posts
|
||||
3. **Relationship State**: Implemented with explicit states (Pending, Accepted, Rejected)
|
||||
4. **Signature Algorithm**: RSA-SHA256 for compatibility
|
||||
5. **Activity Processing**: Synchronous for now, can be made async with queue
|
||||
6. **Content Types**: Support for Note, Article initially (can expand)
|
||||
|
||||
## Notes
|
||||
|
||||
- All ActivityPub communication uses HTTP Signatures
|
||||
- Private keys never leave the server
|
||||
- Public keys are published in actor profiles
|
||||
- Soft delete is enabled on all federated models
|
||||
- Failed activity deliveries are logged but not retried (future enhancement)
|
||||
- Content is federated only when visibility is Public
|
||||
|
||||
## Files Created/Modified
|
||||
|
||||
### New Files
|
||||
- `DysonNetwork.Shared/Models/FediverseInstance.cs`
|
||||
- `DysonNetwork.Shared/Models/FediverseActor.cs`
|
||||
- `DysonNetwork.Shared/Models/FediverseContent.cs`
|
||||
- `DysonNetwork.Shared/Models/FediverseActivity.cs`
|
||||
- `DysonNetwork.Shared/Models/FediverseRelationship.cs`
|
||||
- `DysonNetwork.Shared/Models/FediverseReaction.cs`
|
||||
- `DysonNetwork.Sphere/ActivityPub/WebFingerController.cs`
|
||||
- `DysonNetwork.Sphere/ActivityPub/ActivityPubController.cs`
|
||||
- `DysonNetwork.Sphere/ActivityPub/ActivityPubKeyService.cs`
|
||||
- `DysonNetwork.Sphere/ActivityPub/ActivityPubSignatureService.cs`
|
||||
- `DysonNetwork.Sphere/ActivityPub/ActivityPubActivityProcessor.cs`
|
||||
- `DysonNetwork.Sphere/ActivityPub/ActivityPubDeliveryService.cs`
|
||||
- `DysonNetwork.Sphere/Migrations/20251228120000_AddActivityPubModels.cs`
|
||||
- `DysonNetwork.Sphere/Migrations/20251228130000_AddPublisherMetaForActivityPubKeys.cs`
|
||||
|
||||
### Modified Files
|
||||
- `DysonNetwork.Shared/Models/Publisher.cs` - Added Meta field
|
||||
- `DysonNetwork.Sphere/AppDatabase.cs` - Added DbSets for ActivityPub
|
||||
- `DysonNetwork.Sphere/Startup/ServiceCollectionExtensions.cs` - Registered ActivityPub services
|
||||
|
||||
## References
|
||||
|
||||
- [ActivityPub Implementation Guide](./ACTIVITYPUB_IMPLEMENTATION.md)
|
||||
- [ActivityPub Plan](./ACTIVITYPUB_PLAN.md)
|
||||
- [Solar Network Architecture](./README.md)
|
||||
820
docs/activitypub/ACTIVITYPUB_TESTING_GUIDE.md
Normal file
@@ -0,0 +1,820 @@
|
||||
# ActivityPub Testing Guide for Solar Network
|
||||
|
||||
This guide will help you test the ActivityPub implementation in Solar Network, starting with a self-hosted instance and then moving to a real instance.
|
||||
|
||||
## Prerequisites
|
||||
|
||||
- ✅ Solar Network codebase with ActivityPub implementation
|
||||
- ✅ Docker installed (for running Mastodon/Fediverse instances)
|
||||
- ✅ PostgreSQL database running
|
||||
- ✅ `.NET 10` SDK
|
||||
|
||||
## Part 1: Set Up a Self-Hosted Test Instance
|
||||
|
||||
### Option A: Using Mastodon (Recommended for Compatibility)
|
||||
|
||||
#### 1. Create a Docker Compose File
|
||||
|
||||
Create `docker-compose.mastodon-test.yml`:
|
||||
|
||||
```yaml
|
||||
version: '3'
|
||||
|
||||
services:
|
||||
db:
|
||||
restart: always
|
||||
image: postgres:14-alpine
|
||||
environment:
|
||||
POSTGRES_USER: mastodon
|
||||
POSTGRES_PASSWORD: mastodon_password
|
||||
POSTGRES_DB: mastodon
|
||||
networks:
|
||||
- mastodon_network
|
||||
healthcheck:
|
||||
test: ["CMD", "pg_isready", "-U", "mastodon"]
|
||||
interval: 5s
|
||||
retries: 5
|
||||
|
||||
redis:
|
||||
restart: always
|
||||
image: redis:7-alpine
|
||||
networks:
|
||||
- mastodon_network
|
||||
healthcheck:
|
||||
test: ["CMD", "redis-cli", "ping"]
|
||||
interval: 5s
|
||||
retries: 5
|
||||
|
||||
es:
|
||||
restart: always
|
||||
image: docker.elastic.co/elasticsearch:8.10.2
|
||||
environment:
|
||||
- "discovery.type=single-node"
|
||||
- "ES_JAVA_OPTS=-Xms512m -Xmx512m"
|
||||
- "xpack.security.enabled=false"
|
||||
networks:
|
||||
- mastodon_network
|
||||
healthcheck:
|
||||
test: ["CMD-SHELL", "curl -silent http://localhost:9200/_cluster/health || exit 1"]
|
||||
interval: 10s
|
||||
retries: 10
|
||||
|
||||
web:
|
||||
restart: always
|
||||
image: tootsuite/mastodon:latest
|
||||
env_file: .env.mastodon
|
||||
command: bash -c "rm -f /mastodon/tmp/pids/server.pid; bundle exec rails s -p 3000"
|
||||
ports:
|
||||
- "3001:3000"
|
||||
depends_on:
|
||||
- db
|
||||
- redis
|
||||
- es
|
||||
networks:
|
||||
- mastodon_network
|
||||
volumes:
|
||||
- ./mastodon-data/public:/mastodon/public/system
|
||||
|
||||
streaming:
|
||||
restart: always
|
||||
image: tootsuite/mastodon:latest
|
||||
env_file: .env.mastodon
|
||||
command: node ./streaming
|
||||
ports:
|
||||
- "4000:4000"
|
||||
depends_on:
|
||||
- db
|
||||
- redis
|
||||
networks:
|
||||
- mastodon_network
|
||||
|
||||
sidekiq:
|
||||
restart: always
|
||||
image: tootsuite/mastodon:latest
|
||||
env_file: .env.mastodon
|
||||
command: bundle exec sidekiq
|
||||
depends_on:
|
||||
- db
|
||||
- redis
|
||||
networks:
|
||||
- mastodon_network
|
||||
|
||||
networks:
|
||||
mastodon_network:
|
||||
driver: bridge
|
||||
```
|
||||
|
||||
#### 2. Create Environment File
|
||||
|
||||
Create `.env.mastodon`:
|
||||
|
||||
```bash
|
||||
# Federation
|
||||
LOCAL_DOMAIN=mastodon.local
|
||||
LOCAL_HTTPS=false
|
||||
|
||||
# Database
|
||||
DB_HOST=db
|
||||
DB_PORT=5432
|
||||
DB_USER=mastodon
|
||||
DB_NAME=mastodon
|
||||
DB_PASS=mastodon_password
|
||||
|
||||
# Redis
|
||||
REDIS_HOST=redis
|
||||
REDIS_PORT=6379
|
||||
|
||||
# Elasticsearch
|
||||
ES_ENABLED=true
|
||||
ES_HOST=es
|
||||
ES_PORT=9200
|
||||
|
||||
# Secrets (generate these!)
|
||||
SECRET_KEY_BASE=change_me_to_a_random_string_at_least_32_chars
|
||||
OTP_SECRET=change_me_to_another_random_string
|
||||
|
||||
# Defaults
|
||||
SINGLE_USER_MODE=false
|
||||
DEFAULT_LOCALE=en
|
||||
```
|
||||
|
||||
**Generate secrets:**
|
||||
```bash
|
||||
# Run these to generate random secrets
|
||||
openssl rand -base64 32
|
||||
```
|
||||
|
||||
#### 3. Start Mastodon
|
||||
|
||||
```bash
|
||||
docker-compose -f docker-compose.mastodon-test.yml up -d
|
||||
|
||||
# Check logs
|
||||
docker-compose -f docker-compose.mastodon-test.yml logs -f web
|
||||
```
|
||||
|
||||
Wait for the web service to be healthy (may take 2-5 minutes).
|
||||
|
||||
#### 4. Create a Mastodon Account
|
||||
|
||||
```bash
|
||||
# Run this command to create an admin account
|
||||
docker-compose -f docker-compose.mastodon-test.yml exec web \
|
||||
bin/tootctl accounts create \
|
||||
testuser \
|
||||
testuser@mastodon.local \
|
||||
--email=test@example.com \
|
||||
--confirmed \
|
||||
--role=admin \
|
||||
--approve
|
||||
```
|
||||
|
||||
Set password: `TestPassword123!`
|
||||
|
||||
#### 5. Update Your /etc/hosts
|
||||
|
||||
```bash
|
||||
sudo nano /etc/hosts
|
||||
```
|
||||
|
||||
Add:
|
||||
```
|
||||
127.0.0.1 mastodon.local
|
||||
127.0.0.1 solar.local
|
||||
```
|
||||
|
||||
### Option B: Using GoToSocial (Lightweight Alternative)
|
||||
|
||||
Create `docker-compose.gotosocial.yml`:
|
||||
|
||||
```yaml
|
||||
version: '3'
|
||||
|
||||
services:
|
||||
gotosocial:
|
||||
image: superseriousbusiness/gotosocial:latest
|
||||
environment:
|
||||
- GTS_HOST=gotosocial.local
|
||||
- GTS_ACCOUNT_DOMAIN=gotosocial.local
|
||||
- GTS_PROTOCOL=http
|
||||
- GTS_DB_TYPE=sqlite
|
||||
- GTS_DB_ADDRESS=/gotosocial/data/sqlite.db
|
||||
- GTS_STORAGE_LOCAL_BASE_PATH=/gotosocial/data/storage
|
||||
ports:
|
||||
- "3002:8080"
|
||||
volumes:
|
||||
- ./gotosocial-data:/gotosocial/data
|
||||
|
||||
networks:
|
||||
default:
|
||||
```
|
||||
|
||||
Start it:
|
||||
```bash
|
||||
docker-compose -f docker-compose.gotosocial.yml up -d
|
||||
```
|
||||
|
||||
Create account:
|
||||
```bash
|
||||
docker-compose -f docker-compose.gotosocial.yml exec gotosocial \
|
||||
/gotosocial/gotosocial admin account create \
|
||||
--username testuser \
|
||||
--email test@example.com \
|
||||
--password TestPassword123!
|
||||
```
|
||||
|
||||
## Part 2: Configure Solar Network for Federation
|
||||
|
||||
### 1. Update appsettings.json
|
||||
|
||||
Edit `DysonNetwork.Sphere/appsettings.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"ActivityPub": {
|
||||
"Domain": "solar.local",
|
||||
"EnableFederation": true
|
||||
},
|
||||
"Kestrel": {
|
||||
"Endpoints": {
|
||||
"Http": {
|
||||
"Url": "http://solar.local:5000"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### 2. Update /etc/hosts
|
||||
|
||||
Add both instances:
|
||||
```
|
||||
127.0.0.1 mastodon.local
|
||||
127.0.0.1 solar.local
|
||||
127.0.0.1 gotosocial.local
|
||||
```
|
||||
|
||||
### 3. Apply Database Migrations
|
||||
|
||||
```bash
|
||||
cd DysonNetwork.Sphere
|
||||
dotnet ef database update
|
||||
```
|
||||
|
||||
### 4. Start Solar Network
|
||||
|
||||
```bash
|
||||
dotnet run --project DysonNetwork.Sphere
|
||||
```
|
||||
|
||||
Solar Network should now be running on `http://solar.local:5000`
|
||||
|
||||
## Part 3: Create Test Users
|
||||
|
||||
### In Solar Network
|
||||
|
||||
1. Open http://solar.local:5000 (or your web interface)
|
||||
2. Create a new account/publisher named `solaruser`
|
||||
3. Note down the publisher ID for later
|
||||
|
||||
**Or via API** (if you have an existing account):
|
||||
|
||||
```bash
|
||||
# First, create a publisher in Solar Network
|
||||
curl -X POST http://solar.local:5000/api/publishers \
|
||||
-H "Content-Type: application/json" \
|
||||
-H "Authorization: Bearer YOUR_TOKEN" \
|
||||
-d '{
|
||||
"name": "solaruser",
|
||||
"nick": "Solar User",
|
||||
"bio": "Testing ActivityPub federation!",
|
||||
"type": 0
|
||||
}'
|
||||
```
|
||||
|
||||
### In Mastodon
|
||||
|
||||
Open http://mastodon.local:3001 and log in with:
|
||||
- Username: `testuser`
|
||||
- Password: `TestPassword123!`
|
||||
|
||||
## Part 4: Test Federation Scenarios
|
||||
|
||||
### Test 1: WebFinger Discovery
|
||||
|
||||
**Goal**: Verify Solar Network is discoverable
|
||||
|
||||
```bash
|
||||
# Query Solar Network's WebFinger endpoint
|
||||
curl -v "http://solar.local:5000/.well-known/webfinger?resource=acct:solaruser@solar.local"
|
||||
|
||||
# Expected response (200 OK):
|
||||
{
|
||||
"subject": "acct:solaruser@solar.local",
|
||||
"links": [
|
||||
{
|
||||
"rel": "self",
|
||||
"type": "application/activity+json",
|
||||
"href": "https://solar.local:5000/activitypub/actors/solaruser"
|
||||
},
|
||||
{
|
||||
"rel": "http://webfinger.net/rel/profile-page",
|
||||
"type": "text/html",
|
||||
"href": "https://solar.local:5000/users/solaruser"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
### Test 2: Fetch Actor Profile
|
||||
|
||||
**Goal**: Get ActivityPub actor JSON
|
||||
|
||||
```bash
|
||||
# Fetch Solar Network actor from Mastodon
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/solaruser
|
||||
|
||||
# Expected response includes:
|
||||
{
|
||||
"@context": ["https://www.w3.org/ns/activitystreams"],
|
||||
"id": "https://solar.local:5000/activitypub/actors/solaruser",
|
||||
"type": "Person",
|
||||
"preferredUsername": "solaruser",
|
||||
"inbox": "https://solar.local:5000/activitypub/actors/solaruser/inbox",
|
||||
"outbox": "https://solar.local:5000/activitypub/actors/solaruser/outbox",
|
||||
"followers": "https://solar.local:5000/activitypub/actors/solaruser/followers",
|
||||
"publicKey": {
|
||||
"id": "https://solar.local:5000/activitypub/actors/solaruser#main-key",
|
||||
"owner": "https://solar.local:5000/activitypub/actors/solaruser",
|
||||
"publicKeyPem": "-----BEGIN PUBLIC KEY-----\n..."
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Test 3: Follow from Mastodon to Solar Network
|
||||
|
||||
**Goal**: Mastodon user follows Solar Network user
|
||||
|
||||
1. **In Mastodon**:
|
||||
- Go to http://mastodon.local:3001
|
||||
- In search bar, type: `@solaruser@solar.local`
|
||||
- Click the follow button
|
||||
|
||||
2. **Verify in Solar Network**:
|
||||
```bash
|
||||
# Check database for relationship
|
||||
psql -d dyson_network -c \
|
||||
"SELECT * FROM fediverse_relationships WHERE is_local_actor = true;"
|
||||
```
|
||||
|
||||
3. **Check Solar Network logs**:
|
||||
Should see:
|
||||
```
|
||||
Processing activity type: Follow from actor: ...
|
||||
Processed follow from ... to ...
|
||||
```
|
||||
|
||||
4. **Verify Mastodon receives Accept**:
|
||||
- Check Mastodon logs for Accept activity
|
||||
- Verify follow appears as accepted in Mastodon
|
||||
|
||||
### Test 4: Follow from Solar Network to Mastodon
|
||||
|
||||
**Goal**: Solar Network user follows Mastodon user
|
||||
|
||||
You'll need to call the ActivityPub delivery service:
|
||||
|
||||
```bash
|
||||
# Via API (you'll need to implement this endpoint):
|
||||
curl -X POST http://solar.local:5000/api/activitypub/follow \
|
||||
-H "Content-Type: application/json" \
|
||||
-H "Authorization: Bearer YOUR_TOKEN" \
|
||||
-d '{
|
||||
"targetActorUri": "http://mastodon.local:3001/users/testuser"
|
||||
}'
|
||||
```
|
||||
|
||||
**Or test directly with curl** (simulating a Follow activity):
|
||||
|
||||
```bash
|
||||
# Create a Follow activity
|
||||
curl -X POST http://solar.local:5000/activitypub/actors/solaruser/inbox \
|
||||
-H "Content-Type: application/activity+json" \
|
||||
-d '{
|
||||
"@context": "https://www.w3.org/ns/activitystreams",
|
||||
"id": "http://mastodon.local:3001/test-follow-activity",
|
||||
"type": "Follow",
|
||||
"actor": "http://mastodon.local:3001/users/testuser",
|
||||
"object": "https://solar.local:5000/activitypub/actors/solaruser"
|
||||
}'
|
||||
```
|
||||
|
||||
### Test 5: Create a Post in Solar Network
|
||||
|
||||
**Goal**: Post federates to Mastodon
|
||||
|
||||
1. **Create a post via Solar Network API**:
|
||||
```bash
|
||||
curl -X POST http://solar.local:5000/api/posts \
|
||||
-H "Content-Type: application/json" \
|
||||
-H "Authorization: Bearer YOUR_TOKEN" \
|
||||
-d '{
|
||||
"content": "Hello fediverse! Testing ActivityPub from Solar Network! 🚀",
|
||||
"visibility": 0,
|
||||
"publisherId": "PUBLISHER_ID"
|
||||
}'
|
||||
```
|
||||
|
||||
2. **Wait a few seconds**
|
||||
|
||||
3. **Check in Mastodon**:
|
||||
- Go to http://mastodon.local:3001
|
||||
- The post should appear in the federated timeline
|
||||
- It should show `@solaruser@solar.local` as the author
|
||||
|
||||
4. **Verify Solar Network logs**:
|
||||
```
|
||||
Successfully sent activity to http://mastodon.local:3001/inbox
|
||||
```
|
||||
|
||||
### Test 6: Like from Mastodon
|
||||
|
||||
**Goal**: Mastodon user likes a Solar Network post
|
||||
|
||||
1. **In Mastodon**:
|
||||
- Find the Solar Network post
|
||||
- Click the favorite/like button
|
||||
|
||||
2. **Verify in Solar Network**:
|
||||
```bash
|
||||
psql -d dyson_network -c \
|
||||
"SELECT * FROM fediverse_reactions;"
|
||||
```
|
||||
|
||||
3. **Check Solar Network logs**:
|
||||
```
|
||||
Processing activity type: Like from actor: ...
|
||||
Processed like from ...
|
||||
```
|
||||
|
||||
### Test 7: Reply from Mastodon
|
||||
|
||||
**Goal**: Reply federates to Solar Network
|
||||
|
||||
1. **In Mastodon**:
|
||||
- Reply to the Solar Network post
|
||||
- Write: "@solaruser Nice to meet you!"
|
||||
|
||||
2. **Verify in Solar Network**:
|
||||
```bash
|
||||
psql -d dyson_network -c \
|
||||
"SELECT * FROM fediverse_contents WHERE in_reply_to IS NOT NULL;"
|
||||
```
|
||||
|
||||
## Part 5: Debugging and Troubleshooting
|
||||
|
||||
### Enable Detailed Logging
|
||||
|
||||
Edit `appsettings.json`:
|
||||
|
||||
```json
|
||||
{
|
||||
"Logging": {
|
||||
"LogLevel": {
|
||||
"Default": "Debug",
|
||||
"DysonNetwork.Sphere.ActivityPub": "Trace"
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### Check Database State
|
||||
|
||||
```bash
|
||||
# Check actors
|
||||
psql -d dyson_network -c \
|
||||
"SELECT uri, username, display_name FROM fediverse_actors;"
|
||||
|
||||
# Check contents
|
||||
psql -d dyson_network -c \
|
||||
"SELECT uri, type, content FROM fediverse_contents;"
|
||||
|
||||
# Check relationships
|
||||
psql -d dyson_network -c \
|
||||
"SELECT * FROM fediverse_relationships;"
|
||||
|
||||
# Check activities
|
||||
psql -d dyson_network -c \
|
||||
"SELECT type, status, error_message FROM fediverse_activities;"
|
||||
|
||||
# Check failed activities
|
||||
psql -d dyson_network -c \
|
||||
"SELECT * FROM fediverse_activities WHERE status = 3;" # 3 = Failed
|
||||
```
|
||||
|
||||
### Common Issues
|
||||
|
||||
#### Issue: "Failed to verify signature"
|
||||
|
||||
**Cause**: HTTP Signature verification failed
|
||||
|
||||
**Solutions**:
|
||||
1. Check the signature header format
|
||||
2. Verify public key matches actor's keyId
|
||||
3. Ensure Date header is within 5 minutes
|
||||
4. Check host header matches request URL
|
||||
|
||||
#### Issue: "Target actor or inbox not found"
|
||||
|
||||
**Cause**: Remote actor not fetched yet
|
||||
|
||||
**Solutions**:
|
||||
1. Manually fetch the actor first
|
||||
2. Check actor URL is correct
|
||||
3. Verify remote instance is accessible
|
||||
|
||||
#### Issue: "Content already exists"
|
||||
|
||||
**Cause**: Duplicate activity received
|
||||
|
||||
**Solutions**:
|
||||
1. This is normal - deduplication is working
|
||||
2. Check if content appears correctly
|
||||
|
||||
#### Issue: CORS errors when testing from browser
|
||||
|
||||
**Cause**: Browser blocking cross-origin requests
|
||||
|
||||
**Solutions**:
|
||||
1. Use curl for API testing
|
||||
2. Or disable CORS in development
|
||||
3. Test directly from Mastodon interface
|
||||
|
||||
### View HTTP Signatures
|
||||
|
||||
For debugging, you can inspect the signature:
|
||||
|
||||
```bash
|
||||
# From Mastodon to Solar Network
|
||||
curl -v -X POST http://solar.local:5000/activitypub/actors/solaruser/inbox \
|
||||
-H "Content-Type: application/activity+json" \
|
||||
-d '{"type":"Follow",...}'
|
||||
```
|
||||
|
||||
Look for the `Signature` header in the output.
|
||||
|
||||
### Test HTTP Signature Verification Manually
|
||||
|
||||
Create a test script `test-signature.js`:
|
||||
|
||||
```javascript
|
||||
const crypto = require('crypto');
|
||||
|
||||
// Test signature verification
|
||||
const publicKey = `-----BEGIN PUBLIC KEY-----
|
||||
...
|
||||
-----END PUBLIC KEY-----`;
|
||||
|
||||
const signingString = `(request-target): post /activitypub/actors/solaruser/inbox
|
||||
host: solar.local:5000
|
||||
date: ${new Date().toUTCString()}
|
||||
content-length: ...`;
|
||||
|
||||
const signature = '...';
|
||||
|
||||
const verify = crypto.createVerify('SHA256');
|
||||
verify.update(signingString);
|
||||
const isValid = verify.verify(publicKey, signature, 'base64');
|
||||
|
||||
console.log('Signature valid:', isValid);
|
||||
```
|
||||
|
||||
## Part 6: Test with a Real Instance
|
||||
|
||||
### Preparing for Public Federation
|
||||
|
||||
1. **Get a real domain** (e.g., via ngrok or a VPS)
|
||||
|
||||
```bash
|
||||
# Using ngrok for testing
|
||||
ngrok http 5000
|
||||
|
||||
# This gives you: https://random-id.ngrok-free.app
|
||||
```
|
||||
|
||||
2. **Update Solar Network config**:
|
||||
|
||||
```json
|
||||
{
|
||||
"ActivityPub": {
|
||||
"Domain": "your-domain.com",
|
||||
"EnableFederation": true
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
3. **Update DNS** (if using real domain):
|
||||
- Add A record pointing to your server
|
||||
- Configure HTTPS (required for production federation)
|
||||
|
||||
4. **Test WebFinger with your domain**:
|
||||
|
||||
```bash
|
||||
curl "https://your-domain.com/.well-known/webfinger?resource=acct:username@your-domain.com"
|
||||
```
|
||||
|
||||
### Test with Mastodon.social
|
||||
|
||||
1. **Create a Mastodon.social account**
|
||||
- Go to https://mastodon.social
|
||||
- Sign up for a test account
|
||||
|
||||
2. **Search for your Solar Network user**:
|
||||
- In Mastodon.social search: `@username@your-domain.com`
|
||||
- Click follow
|
||||
|
||||
3. **Create a post in Solar Network**
|
||||
- Should appear in Mastodon.social
|
||||
|
||||
4. **Reply from Mastodon.social**
|
||||
- Should appear in Solar Network
|
||||
|
||||
### Test with Other Instances
|
||||
|
||||
- **Pleroma**: Similar to Mastodon, good for testing
|
||||
- **Lemmy**: For testing community features (later)
|
||||
- **Pixelfed**: For testing media posts
|
||||
- **PeerTube**: For testing video content (later)
|
||||
|
||||
## Part 7: Verification Checklist
|
||||
|
||||
### Self-Hosted Instance Tests
|
||||
|
||||
- [ ] WebFinger returns correct actor links
|
||||
- [ ] Actor profile has all required fields
|
||||
- [ ] Follow from Mastodon to Solar Network works
|
||||
- [ ] Follow from Solar Network to Mastodon works
|
||||
- [ ] Accept activity sent back to Mastodon
|
||||
- [ ] Posts from Solar Network appear in Mastodon timeline
|
||||
- [ ] Posts from Mastodon appear in Solar Network database
|
||||
- [ ] Likes from Mastodon appear in Solar Network
|
||||
- [ ] Replies from Mastodon appear in Solar Network
|
||||
- [ ] Keys are properly generated and stored
|
||||
- [ ] HTTP signatures are correctly verified
|
||||
- [ ] Outbox returns public posts
|
||||
|
||||
### Real Instance Tests
|
||||
|
||||
- [ ] Domain is publicly accessible
|
||||
- [ ] HTTPS is working (or HTTP for local testing)
|
||||
- [ ] WebFinger works with your domain
|
||||
- [ ] Actor is discoverable from other instances
|
||||
- [ ] Posts federate to public instances
|
||||
- [ ] Users can follow across instances
|
||||
- [ ] Timelines show federated content
|
||||
|
||||
## Part 8: Monitoring During Tests
|
||||
|
||||
### Check Solar Network Logs
|
||||
|
||||
```bash
|
||||
# Follow logs in real-time
|
||||
dotnet run --project DysonNetwork.Sphere | grep -i activitypub
|
||||
```
|
||||
|
||||
### Check Mastodon Logs
|
||||
|
||||
```bash
|
||||
docker-compose -f docker-compose.mastodon-test.yml logs -f web | grep -i federation
|
||||
```
|
||||
|
||||
### Monitor Database Activity
|
||||
|
||||
```bash
|
||||
# Watch activity table
|
||||
watch -n 2 'psql -d dyson_network -c "SELECT type, status, created_at FROM fediverse_activities ORDER BY created_at DESC LIMIT 10;"'
|
||||
```
|
||||
|
||||
### Check Network Traffic
|
||||
|
||||
```bash
|
||||
# Monitor HTTP requests
|
||||
tcpdump -i lo port 5000 or port 3001 -A
|
||||
```
|
||||
|
||||
## Part 9: Advanced Testing
|
||||
|
||||
### Test HTTP Signature Fallbacks
|
||||
|
||||
Test with various signature headers:
|
||||
|
||||
```bash
|
||||
# With Date header
|
||||
curl -H "Date: $(date -u +%a,\ %d\ %b\ %Y\ %T\ GMT)" ...
|
||||
|
||||
# With Digest header
|
||||
curl -H "Digest: SHA-256=$(echo -n '{}' | openssl dgst -sha256 -binary | base64)" ...
|
||||
|
||||
# Multiple signed headers
|
||||
curl -H "Signature: keyId=\"...\",algorithm=\"rsa-sha256\",headers=\"(request-target) host date digest\",signature=\"...\"" ...
|
||||
```
|
||||
|
||||
### Test Rate Limiting
|
||||
|
||||
Send multiple requests quickly:
|
||||
|
||||
```bash
|
||||
for i in {1..10}; do
|
||||
curl -X POST http://solar.local:5000/activitypub/actors/solaruser/inbox \
|
||||
-H "Content-Type: application/activity+json" \
|
||||
-d '{"type":"Create",...}'
|
||||
done
|
||||
```
|
||||
|
||||
### Test Large Posts
|
||||
|
||||
Send post with attachments:
|
||||
|
||||
```bash
|
||||
curl -X POST http://solar.local:5000/api/posts \
|
||||
-H "Content-Type: application/json" \
|
||||
-d '{
|
||||
"content": "A post with an image",
|
||||
"attachments": [{"id": "file-id"}],
|
||||
"visibility": 0
|
||||
}'
|
||||
```
|
||||
|
||||
## Part 10: Cleanup
|
||||
|
||||
### Stop Test Instances
|
||||
|
||||
```bash
|
||||
# Stop Mastodon
|
||||
docker-compose -f docker-compose.mastodon-test.yml down
|
||||
|
||||
# Stop GoToSocial
|
||||
docker-compose -f docker-compose.gotosocial.yml down
|
||||
|
||||
# Remove data volumes
|
||||
docker-compose -f docker-compose.mastodon-test.yml down -v
|
||||
```
|
||||
|
||||
### Reset Solar Network Database
|
||||
|
||||
```bash
|
||||
# Warning: This deletes all data!
|
||||
cd DysonNetwork.Sphere
|
||||
dotnet ef database drop
|
||||
dotnet ef database update
|
||||
```
|
||||
|
||||
### Remove /etc/hosts Entries
|
||||
|
||||
```bash
|
||||
sudo nano /etc/hosts
|
||||
|
||||
# Remove these lines:
|
||||
# 127.0.0.1 mastodon.local
|
||||
# 127.0.0.1 solar.local
|
||||
# 127.0.0.1 gotosocial.local
|
||||
```
|
||||
|
||||
## Next Steps After Testing
|
||||
|
||||
1. **Fix any issues found during testing**
|
||||
2. **Add retry logic for failed deliveries**
|
||||
3. **Implement activity queue for async processing**
|
||||
4. **Add monitoring and metrics**
|
||||
5. **Test with more instances (Pleroma, Pixelfed, etc.)**
|
||||
6. **Add support for more activity types**
|
||||
7. **Improve error handling and logging**
|
||||
8. **Add admin interface for managing federation**
|
||||
|
||||
## Useful Tools
|
||||
|
||||
### ActivityPub Testing Tools
|
||||
- [ActivityPub Playground](https://swicth.github.io/activity-pub-playground/)
|
||||
- [FediTest](https://feditest.com/)
|
||||
- [FediVerse.net](https://fedi.net/)
|
||||
|
||||
### HTTP Testing
|
||||
- [curl](https://curl.se/)
|
||||
- [httpie](https://httpie.io/)
|
||||
- [Postman](https://www.postman.com/)
|
||||
|
||||
### JSON Inspection
|
||||
- [jq](https://stedolan.github.io/jq/)
|
||||
- [jsonpath.com](https://jsonpath.com/)
|
||||
|
||||
### Network Debugging
|
||||
- [Wireshark](https://www.wireshark.org/)
|
||||
- [tcpdump](https://www.tcpdump.org/)
|
||||
|
||||
## References
|
||||
|
||||
- [ActivityPub W3C Spec](https://www.w3.org/TR/activitypub/)
|
||||
- [HTTP Signatures Draft](https://datatracker.ietf.org/doc/html/draft-cavage-http-signatures)
|
||||
- [WebFinger RFC 7033](https://tools.ietf.org/html/rfc7033)
|
||||
- [Mastodon Federation Documentation](https://docs.joinmastodon.org/admin/federation/)
|
||||
506
docs/activitypub/ACTIVITYPUB_TESTING_HELPER_API.md
Normal file
@@ -0,0 +1,506 @@
|
||||
# ActivityPub Testing Helper API
|
||||
|
||||
This document describes helper endpoints for testing ActivityPub federation.
|
||||
|
||||
## Purpose
|
||||
|
||||
These endpoints allow you to manually trigger ActivityPub activities for testing purposes without implementing the full UI federation integration yet.
|
||||
|
||||
## Helper Endpoints
|
||||
|
||||
### 1. Send Follow Activity
|
||||
|
||||
**Endpoint**: `POST /api/activitypub/test/follow`
|
||||
|
||||
**Description**: Sends a Follow activity to a remote actor
|
||||
|
||||
**Request Body**:
|
||||
```json
|
||||
{
|
||||
"targetActorUri": "http://mastodon.local:3001/users/testuser"
|
||||
}
|
||||
```
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"success": true,
|
||||
"activityId": "http://solar.local:5000/activitypub/activities/...",
|
||||
"targetActor": "http://mastodon.local:3001/users/testuser"
|
||||
}
|
||||
```
|
||||
|
||||
### 2. Send Like Activity
|
||||
|
||||
**Endpoint**: `POST /api/activitypub/test/like`
|
||||
|
||||
**Description**: Sends a Like activity for a post (can be local or remote)
|
||||
|
||||
**Request Body**:
|
||||
```json
|
||||
{
|
||||
"postId": "POST_ID",
|
||||
"targetActorUri": "http://mastodon.local:3001/users/testuser"
|
||||
}
|
||||
```
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"success": true,
|
||||
"activityId": "http://solar.local:5000/activitypub/activities/..."
|
||||
}
|
||||
```
|
||||
|
||||
### 3. Send Announce (Boost) Activity
|
||||
|
||||
**Endpoint**: `POST /api/activitypub/test/announce`
|
||||
|
||||
**Description**: Boosts a post to followers
|
||||
|
||||
**Request Body**:
|
||||
```json
|
||||
{
|
||||
"postId": "POST_ID"
|
||||
}
|
||||
```
|
||||
|
||||
### 4. Send Undo Activity
|
||||
|
||||
**Endpoint**: `POST /api/activitypub/test/undo`
|
||||
|
||||
**Description**: Undoes a previous activity
|
||||
|
||||
**Request Body**:
|
||||
```json
|
||||
{
|
||||
"activityType": "Like", // or "Follow", "Announce"
|
||||
"objectUri": "http://solar.local:5000/activitypub/objects/POST_ID"
|
||||
}
|
||||
```
|
||||
|
||||
### 5. Get Federation Status
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/test/status`
|
||||
|
||||
**Description**: Returns current federation statistics
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"actors": {
|
||||
"total": 5,
|
||||
"local": 1,
|
||||
"remote": 4
|
||||
},
|
||||
"contents": {
|
||||
"total": 25,
|
||||
"byType": {
|
||||
"Note": 20,
|
||||
"Article": 5
|
||||
}
|
||||
},
|
||||
"relationships": {
|
||||
"total": 8,
|
||||
"accepted": 6,
|
||||
"pending": 1,
|
||||
"rejected": 1
|
||||
},
|
||||
"activities": {
|
||||
"total": 45,
|
||||
"byStatus": {
|
||||
"Completed": 40,
|
||||
"Pending": 3,
|
||||
"Failed": 2
|
||||
},
|
||||
"byType": {
|
||||
"Create": 20,
|
||||
"Follow": 8,
|
||||
"Accept": 6,
|
||||
"Like": 5,
|
||||
"Announce": 3,
|
||||
"Undo": 2,
|
||||
"Delete": 1
|
||||
}
|
||||
}
|
||||
}
|
||||
```
|
||||
|
||||
### 6. Get Recent Activities
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/test/activities`
|
||||
|
||||
**Query Parameters**:
|
||||
- `limit`: Number of activities to return (default: 20)
|
||||
- `type`: Filter by activity type (optional)
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"activities": [
|
||||
{
|
||||
"id": "ACTIVITY_ID",
|
||||
"type": "Follow",
|
||||
"status": "Completed",
|
||||
"actorUri": "http://mastodon.local:3001/users/testuser",
|
||||
"objectUri": "http://solar.local:5000/activitypub/actors/solaruser",
|
||||
"createdAt": "2024-01-15T10:30:00Z",
|
||||
"errorMessage": null
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
### 7. Get Actor Keys
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/test/actors/{username}/keys`
|
||||
|
||||
**Description**: Returns the public/private key pair for a publisher
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"username": "solaruser",
|
||||
"hasKeys": true,
|
||||
"actorUri": "http://solar.local:5000/activitypub/actors/solaruser",
|
||||
"publicKeyId": "http://solar.local:5000/activitypub/actors/solaruser#main-key",
|
||||
"publicKey": "-----BEGIN PUBLIC KEY-----\n...",
|
||||
"privateKeyStored": true
|
||||
}
|
||||
```
|
||||
|
||||
### 8. Test HTTP Signature
|
||||
|
||||
**Endpoint**: `POST /api/activitypub/test/sign`
|
||||
|
||||
**Description**: Test if a signature string is valid for a given public key
|
||||
|
||||
**Request Body**:
|
||||
```json
|
||||
{
|
||||
"publicKey": "-----BEGIN PUBLIC KEY-----\n...",
|
||||
"signingString": "(request-target): post /inbox\nhost: example.com\ndate: ...",
|
||||
"signature": "..."
|
||||
}
|
||||
```
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"valid": true,
|
||||
"message": "Signature is valid"
|
||||
}
|
||||
```
|
||||
|
||||
## Controller Implementation
|
||||
|
||||
Create `DysonNetwork.Sphere/ActivityPub/ActivityPubTestController.cs`:
|
||||
|
||||
```csharp
|
||||
using Microsoft.AspNetCore.Authorization;
|
||||
using Microsoft.AspNetCore.Mvc;
|
||||
|
||||
namespace DysonNetwork.Sphere.ActivityPub;
|
||||
|
||||
[ApiController]
|
||||
[Route("api/activitypub/test")]
|
||||
[Authorize] // Require auth for testing
|
||||
public class ActivityPubTestController(
|
||||
AppDatabase db,
|
||||
ActivityPubDeliveryService deliveryService,
|
||||
ActivityPubKeyService keyService,
|
||||
ActivityPubSignatureService signatureService,
|
||||
IConfiguration configuration,
|
||||
ILogger<ActivityPubTestController> logger
|
||||
) : ControllerBase
|
||||
{
|
||||
[HttpPost("follow")]
|
||||
public async Task<ActionResult> TestFollow([FromBody] TestFollowRequest request)
|
||||
{
|
||||
var currentUser = GetCurrentUser();
|
||||
var publisher = await GetPublisherForUser(currentUser.Id);
|
||||
|
||||
if (publisher == null)
|
||||
return BadRequest("Publisher not found");
|
||||
|
||||
var success = await deliveryService.SendFollowActivityAsync(
|
||||
publisher.Id,
|
||||
request.TargetActorUri
|
||||
);
|
||||
|
||||
return Ok(new
|
||||
{
|
||||
success,
|
||||
targetActorUri = request.TargetActorUri,
|
||||
publisherId = publisher.Id
|
||||
});
|
||||
}
|
||||
|
||||
[HttpPost("like")]
|
||||
public async Task<ActionResult> TestLike([FromBody] TestLikeRequest request)
|
||||
{
|
||||
var currentUser = GetCurrentUser();
|
||||
var publisher = await GetPublisherForUser(currentUser.Id);
|
||||
|
||||
var success = await deliveryService.SendLikeActivityAsync(
|
||||
request.PostId,
|
||||
currentUser.Id,
|
||||
request.TargetActorUri
|
||||
);
|
||||
|
||||
return Ok(new { success, postId = request.PostId });
|
||||
}
|
||||
|
||||
[HttpPost("announce")]
|
||||
public async Task<ActionResult> TestAnnounce([FromBody] TestAnnounceRequest request)
|
||||
{
|
||||
var post = await db.Posts.FindAsync(request.PostId);
|
||||
if (post == null)
|
||||
return NotFound();
|
||||
|
||||
var success = await deliveryService.SendCreateActivityAsync(post);
|
||||
|
||||
return Ok(new { success, postId = request.PostId });
|
||||
}
|
||||
|
||||
[HttpPost("undo")]
|
||||
public async Task<ActionResult> TestUndo([FromBody] TestUndoRequest request)
|
||||
{
|
||||
var currentUser = GetCurrentUser();
|
||||
var publisher = await GetPublisherForUser(currentUser.Id);
|
||||
|
||||
if (publisher == null)
|
||||
return BadRequest("Publisher not found");
|
||||
|
||||
var success = await deliveryService.SendUndoActivityAsync(
|
||||
request.ActivityType,
|
||||
request.ObjectUri,
|
||||
publisher.Id
|
||||
);
|
||||
|
||||
return Ok(new { success, activityType = request.ActivityType });
|
||||
}
|
||||
|
||||
[HttpGet("status")]
|
||||
public async Task<ActionResult> GetStatus()
|
||||
{
|
||||
var totalActors = await db.FediverseActors.CountAsync();
|
||||
var localActors = await db.FediverseActors
|
||||
.CountAsync(a => a.Uri.Contains("solar.local"));
|
||||
|
||||
var totalContents = await db.FediverseContents.CountAsync();
|
||||
|
||||
var relationships = await db.FediverseRelationships
|
||||
.GroupBy(r => r.State)
|
||||
.Select(g => new { State = g.Key, Count = g.Count() })
|
||||
.ToListAsync();
|
||||
|
||||
var activitiesByStatus = await db.FediverseActivities
|
||||
.GroupBy(a => a.Status)
|
||||
.Select(g => new { Status = g.Key, Count = g.Count() })
|
||||
.ToListAsync();
|
||||
|
||||
var activitiesByType = await db.FediverseActivities
|
||||
.GroupBy(a => a.Type)
|
||||
.Select(g => new { Type = g.Key, Count = g.Count() })
|
||||
.ToListAsync();
|
||||
|
||||
return Ok(new
|
||||
{
|
||||
actors = new
|
||||
{
|
||||
total = totalActors,
|
||||
local = localActors,
|
||||
remote = totalActors - localActors
|
||||
},
|
||||
contents = new
|
||||
{
|
||||
total = totalContents
|
||||
},
|
||||
relationships = relationships.ToDictionary(r => r.State.ToString(), r => r.Count),
|
||||
activities = new
|
||||
{
|
||||
byStatus = activitiesByStatus.ToDictionary(a => a.Status.ToString(), a => a.Count),
|
||||
byType = activitiesByType.ToDictionary(a => a.Type.ToString(), a => a.Count)
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
[HttpGet("activities")]
|
||||
public async Task<ActionResult> GetActivities([FromQuery] int limit = 20, [FromQuery] string? type = null)
|
||||
{
|
||||
var query = db.FediverseActivities
|
||||
.OrderByDescending(a => a.CreatedAt);
|
||||
|
||||
if (!string.IsNullOrEmpty(type))
|
||||
{
|
||||
query = query.Where(a => a.Type.ToString() == type);
|
||||
}
|
||||
|
||||
var activities = await query
|
||||
.Take(limit)
|
||||
.Select(a => new
|
||||
{
|
||||
a.Id,
|
||||
a.Type,
|
||||
a.Status,
|
||||
ActorUri = a.Actor.Uri,
|
||||
ObjectUri = a.ObjectUri,
|
||||
a.CreatedAt,
|
||||
a.ErrorMessage
|
||||
})
|
||||
.ToListAsync();
|
||||
|
||||
return Ok(new { activities });
|
||||
}
|
||||
|
||||
[HttpGet("actors/{username}/keys")]
|
||||
public async Task<ActionResult> GetActorKeys(string username)
|
||||
{
|
||||
var publisher = await db.Publishers
|
||||
.FirstOrDefaultAsync(p => p.Name == username);
|
||||
|
||||
if (publisher == null)
|
||||
return NotFound();
|
||||
|
||||
var actorUrl = $"http://solar.local:5000/activitypub/actors/{username}";
|
||||
|
||||
var (privateKey, publicKey) = keyService.GenerateKeyPair();
|
||||
|
||||
return Ok(new
|
||||
{
|
||||
username,
|
||||
hasKeys = publisher.Meta != null,
|
||||
actorUri,
|
||||
publicKeyId = $"{actorUrl}#main-key",
|
||||
publicKey = publicKey,
|
||||
privateKeyStored = publisher.Meta != null
|
||||
});
|
||||
}
|
||||
|
||||
[HttpPost("sign")]
|
||||
public ActionResult TestSignature([FromBody] TestSignatureRequest request)
|
||||
{
|
||||
var isValid = keyService.Verify(
|
||||
request.PublicKey,
|
||||
request.SigningString,
|
||||
request.Signature
|
||||
);
|
||||
|
||||
return Ok(new
|
||||
{
|
||||
valid = isValid,
|
||||
message = isValid ? "Signature is valid" : "Signature is invalid"
|
||||
});
|
||||
}
|
||||
|
||||
private async Task<SnPublisher?> GetPublisherForUser(Guid accountId)
|
||||
{
|
||||
return await db.Publishers
|
||||
.Include(p => p.Members)
|
||||
.Where(p => p.Members.Any(m => m.AccountId == accountId))
|
||||
.FirstOrDefaultAsync();
|
||||
}
|
||||
|
||||
private Guid GetCurrentUser()
|
||||
{
|
||||
// Implement based on your auth system
|
||||
return Guid.Empty;
|
||||
}
|
||||
}
|
||||
|
||||
public class TestFollowRequest
|
||||
{
|
||||
public string TargetActorUri { get; set; } = string.Empty;
|
||||
}
|
||||
|
||||
public class TestLikeRequest
|
||||
{
|
||||
public Guid PostId { get; set; }
|
||||
public string TargetActorUri { get; set; } = string.Empty;
|
||||
}
|
||||
|
||||
public class TestAnnounceRequest
|
||||
{
|
||||
public Guid PostId { get; set; }
|
||||
}
|
||||
|
||||
public class TestUndoRequest
|
||||
{
|
||||
public string ActivityType { get; set; } = string.Empty;
|
||||
public string ObjectUri { get; set; } = string.Empty;
|
||||
}
|
||||
|
||||
public class TestSignatureRequest
|
||||
{
|
||||
public string PublicKey { get; set; } = string.Empty;
|
||||
public string SigningString { get; set; } = string.Empty;
|
||||
public string Signature { get; set; } = string.Empty;
|
||||
}
|
||||
```
|
||||
|
||||
## Testing with Helper Endpoints
|
||||
|
||||
### 1. Test Follow
|
||||
```bash
|
||||
curl -X POST http://solar.local:5000/api/activitypub/test/follow \
|
||||
-H "Content-Type: application/json" \
|
||||
-H "Authorization: Bearer YOUR_TOKEN" \
|
||||
-d '{
|
||||
"targetActorUri": "http://mastodon.local:3001/users/testuser"
|
||||
}'
|
||||
```
|
||||
|
||||
### 2. Test Like
|
||||
```bash
|
||||
curl -X POST http://solar.local:5000/api/activitypub/test/like \
|
||||
-H "Content-Type: application/json" \
|
||||
-H "Authorization: Bearer YOUR_TOKEN" \
|
||||
-d '{
|
||||
"postId": "YOUR_POST_ID",
|
||||
"targetActorUri": "http://mastodon.local:5000/activitypub/actors/mastodonuser"
|
||||
}'
|
||||
```
|
||||
|
||||
### 3. Check Status
|
||||
```bash
|
||||
curl http://solar.local:5000/api/activitypub/test/status \
|
||||
-H "Authorization: Bearer YOUR_TOKEN"
|
||||
```
|
||||
|
||||
### 4. Get Recent Activities
|
||||
```bash
|
||||
curl "http://solar.local:5000/api/activitypub/test/activities?limit=10" \
|
||||
-H "Authorization: Bearer YOUR_TOKEN"
|
||||
```
|
||||
|
||||
## Integration with Main Flow
|
||||
|
||||
These helper endpoints can be used to:
|
||||
|
||||
1. **Quickly test federation** without full UI integration
|
||||
2. **Debug specific activity types** in isolation
|
||||
3. **Verify HTTP signatures** are correct
|
||||
4. **Test error handling** for various scenarios
|
||||
5. **Monitor federation status** during development
|
||||
|
||||
## Security Notes
|
||||
|
||||
- All test endpoints require authentication
|
||||
- Use only in development/staging environments
|
||||
- Remove or disable in production
|
||||
- Rate limiting recommended if exposing to public
|
||||
|
||||
## Cleanup
|
||||
|
||||
After testing, you can:
|
||||
|
||||
1. Remove the test controller (optional)
|
||||
2. Disable test endpoints
|
||||
3. Clear test activities from database
|
||||
4. Reset test relationships
|
||||
|
||||
```sql
|
||||
-- Clear test data
|
||||
DELETE FROM fediverse_activities WHERE created_at < NOW() - INTERVAL '1 day';
|
||||
```
|
||||
448
docs/activitypub/ACTIVITYPUB_TESTING_INDEX.md
Normal file
@@ -0,0 +1,448 @@
|
||||
# ActivityPub Testing - Complete Guide
|
||||
|
||||
This is the complete guide for testing ActivityPub federation in Solar Network.
|
||||
|
||||
## 📁 File Overview
|
||||
|
||||
| File | Purpose | When to Use |
|
||||
|------|---------|--------------|
|
||||
| `setup-activitypub-test.sh` | One-command setup of test environment | First time setup |
|
||||
| `test-activitypub.sh` | Quick validation of basic functionality | After setup, before detailed tests |
|
||||
| `ACTIVITYPUB_TESTING_QUICKSTART.md` | Quick start reference | Getting started quickly |
|
||||
| `ACTIVITYPUB_TESTING_GUIDE.md` | Comprehensive testing scenarios | Full testing workflow |
|
||||
| `ACTIVITYPUB_TESTING_QUICKREF.md` | Command and query reference | Daily testing |
|
||||
| `ACTIVITYPUB_TESTING_HELPER_API.md` | Helper API for testing | Programmatic testing |
|
||||
| `ACTIVITYPUB_TEST_RESULTS_TEMPLATE.md` | Track test results | During testing |
|
||||
| `ACTIVITYPUB_IMPLEMENTATION.md` | Implementation details | Understanding the code |
|
||||
| `ACTIVITYPUB_SUMMARY.md` | Feature summary | Reviewing what's implemented |
|
||||
|
||||
## 🚀 Quick Start (5 Minutes)
|
||||
|
||||
### 1. Setup Test Environment
|
||||
|
||||
```bash
|
||||
./setup-activitypub-test.sh
|
||||
```
|
||||
|
||||
This will:
|
||||
- ✅ Configure `/etc/hosts`
|
||||
- ✅ Start Mastodon via Docker
|
||||
- ✅ Create test Mastodon account
|
||||
- ✅ Apply database migrations
|
||||
|
||||
### 2. Validate Setup
|
||||
|
||||
```bash
|
||||
./test-activitypub.sh
|
||||
```
|
||||
|
||||
This checks:
|
||||
- ✅ WebFinger endpoint
|
||||
- ✅ Actor profile
|
||||
- ✅ Public keys
|
||||
- ✅ Database tables
|
||||
|
||||
### 3. Start Solar Network
|
||||
|
||||
```bash
|
||||
cd DysonNetwork.Sphere
|
||||
dotnet run
|
||||
```
|
||||
|
||||
### 4. Test Federation
|
||||
|
||||
1. Open http://mastodon.local:3001
|
||||
2. Search for `@solaruser@solar.local`
|
||||
3. Click Follow
|
||||
4. Create a post in Solar Network
|
||||
5. Verify it appears in Mastodon
|
||||
|
||||
## 📖 Recommended Reading Order
|
||||
|
||||
### For First-Time Testing
|
||||
|
||||
1. **Start Here**: `ACTIVITYPUB_TESTING_QUICKSTART.md`
|
||||
- Overview of the setup
|
||||
- Quick command reference
|
||||
- Common commands
|
||||
|
||||
2. **Then**: `ACTIVITYPUB_TESTING_GUIDE.md`
|
||||
- Detailed test scenarios
|
||||
- Step-by-step instructions
|
||||
- Troubleshooting
|
||||
|
||||
3. **Reference**: `ACTIVITYPUB_TESTING_QUICKREF.md`
|
||||
- Command snippets
|
||||
- Database queries
|
||||
- Response codes
|
||||
|
||||
### During Testing
|
||||
|
||||
1. **Track Progress**: `ACTIVITYPUB_TEST_RESULTS_TEMPLATE.md`
|
||||
- Checklists for each test
|
||||
- Results tracking
|
||||
- Issue logging
|
||||
|
||||
2. **Helper API**: `ACTIVITYPUB_TESTING_HELPER_API.md`
|
||||
- Manual testing endpoints
|
||||
- Debugging tools
|
||||
- Status monitoring
|
||||
|
||||
### For Understanding
|
||||
|
||||
1. **Implementation**: `ACTIVITYPUB_IMPLEMENTATION.md`
|
||||
- Architecture details
|
||||
- Service descriptions
|
||||
- Data flow diagrams
|
||||
|
||||
2. **Features**: `ACTIVITYPUB_SUMMARY.md`
|
||||
- What's implemented
|
||||
- Model relationships
|
||||
- API endpoints
|
||||
|
||||
## 🔍 Test Scenarios Summary
|
||||
|
||||
### Basic Functionality (All instances must pass)
|
||||
|
||||
- [ ] WebFinger discovery works
|
||||
- [ ] Actor profile is valid JSON-LD
|
||||
- [ ] Public key is present
|
||||
- [ ] Outbox returns public posts
|
||||
- [ ] Inbox accepts activities
|
||||
|
||||
### Federation - Follow
|
||||
|
||||
- [ ] Remote user can follow local user
|
||||
- [ ] Local user can follow remote user
|
||||
- [ ] Accept activity is sent/received
|
||||
- [ ] Relationship state is correct
|
||||
- [ ] Unfollow works correctly
|
||||
|
||||
### Federation - Content
|
||||
|
||||
- [ ] Local posts federate to remote instances
|
||||
- [ ] Remote posts appear in local database
|
||||
- [ ] Post content is preserved
|
||||
- [ ] Timestamps are correct
|
||||
- [ ] Attachments are handled
|
||||
- [ ] Content warnings are respected
|
||||
|
||||
### Federation - Interactions
|
||||
|
||||
- [ ] Likes federate correctly
|
||||
- [ ] Likes appear in both instances
|
||||
- [ ] Replies federate correctly
|
||||
- [ ] Reply threading works
|
||||
- [ ] Boosts/Announces work
|
||||
- [ ] Undo activities work
|
||||
|
||||
### Security
|
||||
|
||||
- [ ] HTTP signatures are verified
|
||||
- [ ] Invalid signatures are rejected
|
||||
- [ ] Keys are properly stored
|
||||
- [ ] Private keys never exposed
|
||||
|
||||
## 🐛 Common Issues & Solutions
|
||||
|
||||
### Issue: "Failed to verify signature"
|
||||
|
||||
**Causes**:
|
||||
1. Signature header format is wrong
|
||||
2. Public key doesn't match keyId
|
||||
3. Date header is too old (>5 minutes)
|
||||
4. Request body doesn't match digest
|
||||
|
||||
**Solutions**:
|
||||
1. Check signature format: `keyId="...",algorithm="...",headers="...",signature="..."`
|
||||
2. Verify keyId in actor profile
|
||||
3. Ensure Date header is recent
|
||||
4. Check body is exactly what was signed
|
||||
|
||||
### Issue: "Target actor or inbox not found"
|
||||
|
||||
**Causes**:
|
||||
1. Actor hasn't been fetched yet
|
||||
2. Actor URL is incorrect
|
||||
3. Remote instance is inaccessible
|
||||
|
||||
**Solutions**:
|
||||
1. Manually fetch actor first
|
||||
2. Verify actor URL is correct
|
||||
3. Test accessibility with curl
|
||||
|
||||
### Issue: Activities not arriving
|
||||
|
||||
**Causes**:
|
||||
1. Network connectivity issue
|
||||
2. Remote instance is down
|
||||
3. Activity wasn't queued properly
|
||||
|
||||
**Solutions**:
|
||||
1. Check network connectivity
|
||||
2. Verify remote instance is running
|
||||
3. Check fediverse_activities table for status
|
||||
|
||||
## 📊 Monitoring During Tests
|
||||
|
||||
### Check Logs
|
||||
|
||||
```bash
|
||||
# Solar Network ActivityPub logs
|
||||
dotnet run --project DysonNetwork.Sphere 2>&1 | grep -i activitypub
|
||||
|
||||
# Mastodon federation logs
|
||||
docker compose -f docker-compose.mastodon-test.yml logs -f web | grep -i federation
|
||||
```
|
||||
|
||||
### Monitor Database
|
||||
|
||||
```bash
|
||||
# Watch activity table
|
||||
watch -n 2 'psql -d dyson_network -c \
|
||||
"SELECT type, status, created_at FROM fediverse_activities ORDER BY created_at DESC LIMIT 5;"'
|
||||
```
|
||||
|
||||
### Test Network
|
||||
|
||||
```bash
|
||||
# Test connectivity between instances
|
||||
curl -v http://mastodon.local:3001
|
||||
curl -v http://solar.local:5000
|
||||
|
||||
# Test with traceroute (if available)
|
||||
traceroute mastodon.local
|
||||
traceroute solar.local
|
||||
```
|
||||
|
||||
## 🎯 Success Criteria
|
||||
|
||||
### Minimal Viable Federation
|
||||
|
||||
To consider ActivityPub implementation "working", all of these must pass:
|
||||
|
||||
- ✅ WebFinger returns actor links
|
||||
- ✅ Actor profile has all required fields
|
||||
- ✅ Follow relationships work bidirectionally
|
||||
- ✅ Public posts federate to followers
|
||||
- ✅ Incoming posts are stored correctly
|
||||
- ✅ HTTP signatures are verified
|
||||
- ✅ Basic interaction types work (Like, Reply)
|
||||
|
||||
### Full Production Ready
|
||||
|
||||
For production, also need:
|
||||
|
||||
- ✅ Activity queue with retry logic
|
||||
- ✅ Rate limiting on outgoing deliveries
|
||||
- ✅ Monitoring and alerting
|
||||
- ✅ Admin interface for federation management
|
||||
- ✅ Content filtering and moderation
|
||||
- ✅ Instance blocking capabilities
|
||||
- ✅ Performance optimization for high volume
|
||||
|
||||
## 🔐 Security Checklist
|
||||
|
||||
During testing, verify:
|
||||
|
||||
- [ ] Private keys are never logged
|
||||
- [ ] Private keys are never returned in API responses
|
||||
- [ ] Only public keys are in actor profiles
|
||||
- [ ] All incoming activities are signature-verified
|
||||
- [ ] Invalid signatures are rejected with 401
|
||||
- [ ] TLS is used in production
|
||||
- [ ] Host header is verified against request URL
|
||||
|
||||
## 📈 Performance Metrics
|
||||
|
||||
Track these during testing:
|
||||
|
||||
| Metric | Target | Actual |
|
||||
|--------|--------|--------|
|
||||
| WebFinger response time | <500ms | ___ ms |
|
||||
| Actor fetch time | <1s | ___ ms |
|
||||
| Signature verification time | <100ms | ___ ms |
|
||||
| Activity processing time | <500ms | ___ ms |
|
||||
| Outgoing delivery success rate | >95% | ___% |
|
||||
| Outgoing delivery time | <5s | ___ ms |
|
||||
|
||||
## 🧪 Testing Checklist
|
||||
|
||||
### Self-Hosted Instance Tests
|
||||
|
||||
**Setup**:
|
||||
- [ ] Setup script completed
|
||||
- [ ] Mast containers running
|
||||
- [ ] Solar Network running
|
||||
- [ ] /etc/hosts configured
|
||||
- [ ] Database migrations applied
|
||||
|
||||
**Basic Federation**:
|
||||
- [ ] WebFinger works
|
||||
- [ ] Actor profile valid
|
||||
- [ ] Public key present
|
||||
- [ ] Outbox accessible
|
||||
|
||||
**Follow Flow**:
|
||||
- [ ] Mastodon → Solar follow works
|
||||
- [ ] Solar → Mastodon follow works
|
||||
- [ ] Accept activity sent
|
||||
- [ ] Relationship state correct
|
||||
|
||||
**Content Flow**:
|
||||
- [ ] Solar posts appear in Mastodon
|
||||
- [ ] Mastodon posts appear in Solar
|
||||
- [ ] Content preserved correctly
|
||||
- [ ] Timestamps correct
|
||||
|
||||
**Interactions**:
|
||||
- [ ] Likes work both ways
|
||||
- [ ] Replies work both ways
|
||||
- [ ] Boosts work both ways
|
||||
- [ ] Undo works
|
||||
|
||||
**Security**:
|
||||
- [ ] HTTP signatures verified
|
||||
- [ ] Invalid signatures rejected
|
||||
- [ ] Keys properly managed
|
||||
|
||||
### Real Instance Tests
|
||||
|
||||
**Discovery**:
|
||||
- [ ] Domain publicly accessible
|
||||
- [ ] WebFinger works from public internet
|
||||
- [ ] Actor discoverable from public instances
|
||||
|
||||
**Federation**:
|
||||
- [ ] Posts federate to public instances
|
||||
- [ ] Follows work with public instances
|
||||
- [ ] Interactions work with public instances
|
||||
|
||||
## 📝 Testing Notes
|
||||
|
||||
### What Worked Well
|
||||
1. _____________________
|
||||
2. _____________________
|
||||
3. _____________________
|
||||
|
||||
### What Needs Improvement
|
||||
1. _____________________
|
||||
2. _____________________
|
||||
3. _____________________
|
||||
|
||||
### Bugs Found
|
||||
| # | Description | Severity | Status |
|
||||
|---|-------------|----------|--------|
|
||||
| 1 | _____________________ | Low/Medium/High | ☐ Open/☐ Fixed |
|
||||
| 2 | _____________________ | Low/Medium/High | ☐ Open/☐ Fixed |
|
||||
| 3 | _____________________ | Low/Medium/High | ☐ Open/☐ Fixed |
|
||||
|
||||
## 🎓 Learning Resources
|
||||
|
||||
### ActivityPub Specification
|
||||
- [W3C ActivityPub Recommendation](https://www.w3.org/TR/activitypub/)
|
||||
- [ActivityStreams 2.0](https://www.w3.org/TR/activitystreams-core/)
|
||||
- [HTTP Signatures Draft](https://datatracker.ietf.org/doc/html/draft-cavage-http-signatures)
|
||||
|
||||
### Implementation Guides
|
||||
- [Mastodon Federation Guide](https://docs.joinmastodon.org/admin/federation/)
|
||||
- [ActivityPub Testing Best Practices](https://blog.joinmastodon.org/2018/06/27/how-to-implement-a-basic-activitypub-server/)
|
||||
- [Federation Testing Checklist](https://docs.joinmastodon.org/spec/activitypub/)
|
||||
|
||||
### Tools
|
||||
- [ActivityPub Playground](https://swicth.github.io/activity-pub-playground/)
|
||||
- [FediTest](https://feditest.com/)
|
||||
- [JSONPath Online Evaluator](https://jsonpath.com/)
|
||||
|
||||
## 🔄 Next Steps After Testing
|
||||
|
||||
### Phase 1: Fix Issues
|
||||
- Address all bugs found during testing
|
||||
- Improve error messages
|
||||
- Add better logging
|
||||
|
||||
### Phase 2: Enhance Features
|
||||
- Implement activity queue
|
||||
- Add retry logic
|
||||
- Add rate limiting
|
||||
- Implement instance blocking
|
||||
|
||||
### Phase 3: Production Readiness
|
||||
- Add monitoring and metrics
|
||||
- Add admin interface
|
||||
- Add content filtering
|
||||
- Implement moderation tools
|
||||
|
||||
### Phase 4: Additional Features
|
||||
- Support more activity types
|
||||
- Support media attachments
|
||||
- Support polls
|
||||
- Support custom emojis
|
||||
|
||||
## 📞 Getting Help
|
||||
|
||||
If you encounter issues:
|
||||
|
||||
1. **Check logs**: See the logs section above
|
||||
2. **Review troubleshooting**: See `ACTIVITYPUB_TESTING_GUIDE.md` Part 5
|
||||
3. **Check database queries**: Use queries from `ACTIVITYPUB_TESTING_QUICKREF.md`
|
||||
4. **Validate signatures**: Use helper API in `ACTIVITYPUB_TESTING_HELPER_API.md`
|
||||
|
||||
## ✨ Quick Test Commands
|
||||
|
||||
### All-in-One Test Sequence
|
||||
|
||||
```bash
|
||||
# 1. Setup
|
||||
./setup-activitypub-test.sh
|
||||
|
||||
# 2. Validate
|
||||
./test-activitypub.sh
|
||||
|
||||
# 3. Test WebFinger
|
||||
curl "http://solar.local:5000/.well-known/webfinger?resource=acct:solaruser@solar.local"
|
||||
|
||||
# 4. Test Actor
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/solaruser
|
||||
|
||||
# 5. Test Follow (from Mastodon UI)
|
||||
# Open http://mastodon.local:3001 and follow @solaruser@solar.local
|
||||
|
||||
# 6. Check database
|
||||
psql -d dyson_network -c "SELECT * FROM fediverse_relationships;"
|
||||
|
||||
# 7. Test Post (create in Solar Network UI)
|
||||
# Should appear in http://mastodon.local:3001
|
||||
|
||||
# 8. Verify content
|
||||
psql -d dyson_network -c "SELECT * FROM fediverse_contents;"
|
||||
|
||||
# 9. Test Like (like from Mastodon UI)
|
||||
# Should appear in fediverse_reactions table
|
||||
|
||||
# 10. Check activities
|
||||
psql -d dyson_network -c "SELECT type, status FROM fediverse_activities;"
|
||||
```
|
||||
|
||||
## 🎉 Conclusion
|
||||
|
||||
You now have everything needed to test ActivityPub federation for Solar Network:
|
||||
|
||||
- ✅ Self-hosted test environment (Mastodon)
|
||||
- ✅ Setup automation (setup script)
|
||||
- ✅ Quick validation (test script)
|
||||
- ✅ Comprehensive testing guide
|
||||
- ✅ Helper API for programmatic testing
|
||||
- ✅ Quick reference for daily use
|
||||
- ✅ Results template for tracking progress
|
||||
|
||||
**Recommended workflow**:
|
||||
1. Run `setup-activitypub-test.sh`
|
||||
2. Run `test-activitypub.sh` for validation
|
||||
3. Follow scenarios in `ACTIVITYPUB_TESTING_GUIDE.md`
|
||||
4. Use `ACTIVITYPUB_TESTING_HELPER_API.md` for specific tests
|
||||
5. Track results in `ACTIVITYPUB_TEST_RESULTS_TEMPLATE.md`
|
||||
6. Reference `ACTIVITYPUB_TESTING_QUICKREF.md` for commands
|
||||
|
||||
Good luck with your federation testing! 🚀
|
||||
356
docs/activitypub/ACTIVITYPUB_TESTING_QUICKREF.md
Normal file
@@ -0,0 +1,356 @@
|
||||
# ActivityPub Testing Quick Reference
|
||||
|
||||
## Quick Test Commands
|
||||
|
||||
### 1. Test WebFinger
|
||||
```bash
|
||||
curl "http://solar.local:5000/.well-known/webfinger?resource=acct:username@solar.local"
|
||||
```
|
||||
|
||||
### 2. Fetch Actor Profile
|
||||
```bash
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/username
|
||||
```
|
||||
|
||||
### 3. Get Outbox
|
||||
```bash
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/username/outbox
|
||||
```
|
||||
|
||||
### 4. Send Test Follow (from remote)
|
||||
```bash
|
||||
curl -X POST http://solar.local:5000/activitypub/actors/username/inbox \
|
||||
-H "Content-Type: application/activity+json" \
|
||||
-d '{
|
||||
"@context": "https://www.w3.org/ns/activitystreams",
|
||||
"id": "https://mastodon.local:3001/follow-123",
|
||||
"type": "Follow",
|
||||
"actor": "https://mastodon.local:3001/users/remoteuser",
|
||||
"object": "https://solar.local:5000/activitypub/actors/username"
|
||||
}'
|
||||
```
|
||||
|
||||
### 5. Send Test Create (post)
|
||||
```bash
|
||||
curl -X POST http://solar.local:5000/activitypub/actors/username/inbox \
|
||||
-H "Content-Type: application/activity+json" \
|
||||
-d '{
|
||||
"@context": "https://www.w3.org/ns/activitystreams",
|
||||
"id": "https://mastodon.local:3001/post-123",
|
||||
"type": "Create",
|
||||
"actor": "https://mastodon.local:3001/users/remoteuser",
|
||||
"object": {
|
||||
"id": "https://mastodon.local:3001/objects/post-123",
|
||||
"type": "Note",
|
||||
"content": "Hello from Mastodon! @username@solar.local",
|
||||
"attributedTo": "https://mastodon.local:3001/users/remoteuser",
|
||||
"to": ["https://www.w3.org/ns/activitystreams#Public"]
|
||||
}
|
||||
}'
|
||||
```
|
||||
|
||||
### 6. Send Test Like
|
||||
```bash
|
||||
curl -X POST http://solar.local:5000/activitypub/actors/username/inbox \
|
||||
-H "Content-Type: application/activity+json" \
|
||||
-d '{
|
||||
"@context": "https://www.w3.org/ns/activitystreams",
|
||||
"id": "https://mastodon.local:3001/like-123",
|
||||
"type": "Like",
|
||||
"actor": "https://mastodon.local:3001/users/remoteuser",
|
||||
"object": "https://solar.local:5000/activitypub/objects/post-id"
|
||||
}'
|
||||
```
|
||||
|
||||
## Database Queries
|
||||
|
||||
### Check Actors
|
||||
```sql
|
||||
SELECT id, uri, username, display_name, instance_id
|
||||
FROM fediverse_actors;
|
||||
```
|
||||
|
||||
### Check Contents
|
||||
```sql
|
||||
SELECT id, uri, type, content, actor_id, created_at
|
||||
FROM fediverse_contents
|
||||
ORDER BY created_at DESC
|
||||
LIMIT 20;
|
||||
```
|
||||
|
||||
### Check Relationships
|
||||
```sql
|
||||
SELECT r.id, a1.uri as actor, a2.uri as target, r.state, r.is_following
|
||||
FROM fediverse_relationships r
|
||||
JOIN fediverse_actors a1 ON r.actor_id = a1.id
|
||||
JOIN fediverse_actors a2 ON r.target_actor_id = a2.id;
|
||||
```
|
||||
|
||||
### Check Activities
|
||||
```sql
|
||||
SELECT type, status, error_message, created_at
|
||||
FROM fediverse_activities
|
||||
ORDER BY created_at DESC
|
||||
LIMIT 20;
|
||||
```
|
||||
|
||||
### Check Reactions
|
||||
```sql
|
||||
SELECT r.type, c.uri as content_uri, a.uri as actor_uri
|
||||
FROM fediverse_reactions r
|
||||
JOIN fediverse_contents c ON r.content_id = c.id
|
||||
JOIN fediverse_actors a ON r.actor_id = a.id;
|
||||
```
|
||||
|
||||
## Check Keys in Publisher
|
||||
```sql
|
||||
SELECT id, name, meta
|
||||
FROM publishers
|
||||
WHERE meta IS NOT NULL;
|
||||
```
|
||||
|
||||
## Docker Commands
|
||||
|
||||
### Start Mastodon
|
||||
```bash
|
||||
docker-compose -f docker-compose.mastodon-test.yml up -d
|
||||
```
|
||||
|
||||
### View Mastodon Logs
|
||||
```bash
|
||||
docker-compose -f docker-compose.mastodon-test.yml logs -f web
|
||||
```
|
||||
|
||||
### Stop Mastodon
|
||||
```bash
|
||||
docker-compose -f docker-compose.mastodon-test.yml down
|
||||
```
|
||||
|
||||
### Start GoToSocial
|
||||
```bash
|
||||
docker-compose -f docker-compose.gotosocial.yml up -d
|
||||
```
|
||||
|
||||
## Solar Network Commands
|
||||
|
||||
### Run Migrations
|
||||
```bash
|
||||
cd DysonNetwork.Sphere
|
||||
dotnet ef database update
|
||||
```
|
||||
|
||||
### Run with Debug Logging
|
||||
```bash
|
||||
dotnet run --project DysonNetwork.Sphere -- --logging:LogLevel:DysonNetwork.Sphere.ActivityPub=Trace
|
||||
```
|
||||
|
||||
## Common Response Codes
|
||||
|
||||
| Code | Meaning |
|
||||
|------|---------|
|
||||
| 200 | Success |
|
||||
| 202 | Accepted (activity queued) |
|
||||
| 401 | Unauthorized (invalid signature) |
|
||||
| 404 | Not found (user/post doesn't exist) |
|
||||
| 400 | Bad request (invalid activity) |
|
||||
|
||||
## Activity Status Codes
|
||||
|
||||
| Status | Code | Meaning |
|
||||
|--------|------|---------|
|
||||
| Pending | 0 | Activity waiting to be processed |
|
||||
| Processing | 1 | Activity being processed |
|
||||
| Completed | 2 | Activity successfully processed |
|
||||
| Failed | 3 | Activity processing failed |
|
||||
|
||||
## Relationship States
|
||||
|
||||
| State | Code | Meaning |
|
||||
|--------|------|---------|
|
||||
| Pending | 0 | Follow request sent, waiting for Accept |
|
||||
| Accepted | 1 | Follow accepted, relationship active |
|
||||
| Rejected | 2 | Follow rejected |
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### "Failed to verify signature"
|
||||
|
||||
**Check**: Signature header format
|
||||
```bash
|
||||
# Should be:
|
||||
Signature: keyId="...",algorithm="rsa-sha256",headers="...",signature="..."
|
||||
```
|
||||
|
||||
**Check**: Public key in actor profile
|
||||
```bash
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/username | jq '.publicKey'
|
||||
```
|
||||
|
||||
### "Actor not found"
|
||||
|
||||
**Check**: Actor exists in database
|
||||
```bash
|
||||
psql -d dyson_network -c \
|
||||
"SELECT * FROM fediverse_actors WHERE uri = '...';"
|
||||
```
|
||||
|
||||
**Check**: Actor URL is accessible
|
||||
```bash
|
||||
curl -v http://remote-instance.com/users/username
|
||||
```
|
||||
|
||||
### "Content already exists"
|
||||
|
||||
This is normal behavior - the system is deduplicating.
|
||||
|
||||
### "Target publisher not found"
|
||||
|
||||
**Check**: Publisher exists
|
||||
```bash
|
||||
psql -d dyson_network -c \
|
||||
"SELECT * FROM publishers WHERE name = '...';"
|
||||
```
|
||||
|
||||
## Quick Test Sequence
|
||||
|
||||
### Full Federation Test
|
||||
|
||||
```bash
|
||||
# 1. Start both instances
|
||||
docker-compose -f docker-compose.mastodon-test.yml up -d
|
||||
dotnet run --project DysonNetwork.Sphere
|
||||
|
||||
# 2. Test WebFinger
|
||||
curl "http://solar.local:5000/.well-known/webfinger?resource=acct:solaruser@solar.local"
|
||||
|
||||
# 3. Get Actor
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/solaruser
|
||||
|
||||
# 4. Send Follow from Mastodon
|
||||
# (Do this in Mastodon UI or use curl above)
|
||||
|
||||
# 5. Check database
|
||||
psql -d dyson_network -c "SELECT * FROM fediverse_relationships;"
|
||||
|
||||
# 6. Send Create (post) from Mastodon
|
||||
# (Use curl command above)
|
||||
|
||||
# 7. Check content
|
||||
psql -d dyson_network -c "SELECT * FROM fediverse_contents;"
|
||||
|
||||
# 8. Send Like from Mastodon
|
||||
# (Use curl command above)
|
||||
|
||||
# 9. Check reactions
|
||||
psql -d dyson_network -c "SELECT * FROM fediverse_reactions;"
|
||||
|
||||
# 10. Check activities
|
||||
psql -d dyson_network -c "SELECT type, status FROM fediverse_activities;"
|
||||
```
|
||||
|
||||
## Test URLs
|
||||
|
||||
| Instance | Web | API | ActivityPub |
|
||||
|----------|-----|-----|-----------|
|
||||
| Solar Network | http://solar.local:5000 | http://solar.local:5000/api | http://solar.local:5000/activitypub |
|
||||
| Mastodon | http://mastodon.local:3001 | http://mastodon.local:3001/api/v1 | http://mastodon.local:3001/inbox |
|
||||
|
||||
## Environment Variables
|
||||
|
||||
### Solar Network
|
||||
```bash
|
||||
export SOLAR_DOMAIN="solar.local"
|
||||
export SOLAR_URL="http://solar.local:5000"
|
||||
```
|
||||
|
||||
### Mastodon
|
||||
```bash
|
||||
export MASTODON_DOMAIN="mastodon.local"
|
||||
export MASTODON_URL="http://mastodon.local:3001"
|
||||
```
|
||||
|
||||
## Useful jq Commands
|
||||
|
||||
### Extract Actor ID
|
||||
```bash
|
||||
curl ... | jq '.id'
|
||||
```
|
||||
|
||||
### Extract Inbox URL
|
||||
```bash
|
||||
curl ... | jq '.inbox'
|
||||
```
|
||||
|
||||
### Extract Public Key
|
||||
```bash
|
||||
curl ... | jq '.publicKey.publicKeyPem'
|
||||
```
|
||||
|
||||
### Pretty Print Activity
|
||||
```bash
|
||||
curl ... | jq '.'
|
||||
```
|
||||
|
||||
### Extract Activity Type
|
||||
```bash
|
||||
curl ... | jq '.type'
|
||||
```
|
||||
|
||||
## Network Setup
|
||||
|
||||
### /etc/hosts
|
||||
```
|
||||
127.0.0.1 solar.local
|
||||
127.0.0.1 mastodon.local
|
||||
127.0.0.1 gotosocial.local
|
||||
```
|
||||
|
||||
### Ports Used
|
||||
- Solar Network: 5000
|
||||
- Mastodon: 3001 (web), 4000 (streaming)
|
||||
- GoToSocial: 3002
|
||||
- PostgreSQL: 5432
|
||||
- Redis: 6379
|
||||
- Elasticsearch: 9200
|
||||
|
||||
## File Locations
|
||||
|
||||
### Docker Compose Files
|
||||
- `docker-compose.mastodon-test.yml`
|
||||
- `docker-compose.gotosocial.yml`
|
||||
|
||||
### Environment Files
|
||||
- `.env.mastodon`
|
||||
|
||||
### Data Volumes
|
||||
- `./mastodon-data/`
|
||||
- `./gotosocial-data/`
|
||||
|
||||
## Clean Up Commands
|
||||
|
||||
```bash
|
||||
# Reset database
|
||||
psql -d dyson_network <<EOF
|
||||
TRUNCATE fediverse_activities CASCADE;
|
||||
TRUNCATE fediverse_relationships CASCADE;
|
||||
TRUNCATE fediverse_reactions CASCADE;
|
||||
TRUNCATE fediverse_contents CASCADE;
|
||||
TRUNCATE fediverse_actors CASCADE;
|
||||
TRUNCATE fediverse_instances CASCADE;
|
||||
UPDATE publishers SET meta = NULL WHERE meta IS NOT NULL;
|
||||
EOF
|
||||
|
||||
# Reset everything
|
||||
docker-compose -f docker-compose.mastodon-test.yml down -v
|
||||
docker-compose -f docker-compose.gotosocial.yml down -v
|
||||
psql -d dyson_network <<EOF
|
||||
DROP SCHEMA public CASCADE;
|
||||
CREATE SCHEMA public;
|
||||
EOF
|
||||
dotnet ef database drop
|
||||
dotnet ef database update
|
||||
```
|
||||
289
docs/activitypub/ACTIVITYPUB_TESTING_QUICKSTART.md
Normal file
@@ -0,0 +1,289 @@
|
||||
# ActivityPub Testing - Quick Start
|
||||
|
||||
This directory contains everything you need to test ActivityPub federation for Solar Network.
|
||||
|
||||
## Quick Start
|
||||
|
||||
### 1. Run the Setup Script
|
||||
|
||||
```bash
|
||||
./setup-activitypub-test.sh
|
||||
```
|
||||
|
||||
This will:
|
||||
- ✅ Check prerequisites (Docker, PostgreSQL)
|
||||
- ✅ Update `/etc/hosts` with test domains
|
||||
- ✅ Generate Mastodon environment file
|
||||
- ✅ Create Docker Compose file
|
||||
- ✅ Start Mastodon containers
|
||||
- ✅ Create test Mastodon account
|
||||
- ✅ Apply Solar Network migrations
|
||||
|
||||
### 2. Start Solar Network
|
||||
|
||||
```bash
|
||||
cd DysonNetwork.Sphere
|
||||
dotnet run
|
||||
```
|
||||
|
||||
### 3. Test Federation
|
||||
|
||||
Follow the scenarios in [ACTIVITYPUB_TESTING_GUIDE.md](ACTIVITYPUB_TESTING_GUIDE.md)
|
||||
|
||||
## Test Instances
|
||||
|
||||
| Service | URL | Notes |
|
||||
|---------|-----|-------|
|
||||
| Solar Network | http://solar.local:5000 | Your implementation |
|
||||
| Mastodon | http://mastodon.local:3001 | Test instance |
|
||||
| Mastodon Streaming | http://mastodon.local:4000 | WebSocket |
|
||||
|
||||
## Test Accounts
|
||||
|
||||
### Solar Network
|
||||
- Create via UI or API
|
||||
- Username: `solaruser` (or your choice)
|
||||
|
||||
### Mastodon
|
||||
- Username: `testuser@mastodon.local`
|
||||
- Password: `TestPassword123!`
|
||||
- Role: Admin
|
||||
|
||||
## Quick Test Commands
|
||||
|
||||
### Test WebFinger
|
||||
```bash
|
||||
curl "http://solar.local:5000/.well-known/webfinger?resource=acct:solaruser@solar.local"
|
||||
```
|
||||
|
||||
### Test Actor
|
||||
```bash
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/solaruser
|
||||
```
|
||||
|
||||
### Test Outbox
|
||||
```bash
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/solaruser/outbox
|
||||
```
|
||||
|
||||
### Test Follow (from Mastodon)
|
||||
1. Open http://mastodon.local:3001
|
||||
2. Log in as `testuser@mastodon.local`
|
||||
3. Search for `@solaruser@solar.local`
|
||||
4. Click Follow
|
||||
|
||||
### Test Follow (from Solar Network to Mastodon)
|
||||
```bash
|
||||
# Send Follow activity to Solar Network
|
||||
curl -X POST http://solar.local:5000/activitypub/actors/solaruser/inbox \
|
||||
-H "Content-Type: application/activity+json" \
|
||||
-d '{
|
||||
"@context": "https://www.w3.org/ns/activitystreams",
|
||||
"id": "http://solar.local:5000/follow-1",
|
||||
"type": "Follow",
|
||||
"actor": "https://solar.local:5000/activitypub/actors/solaruser",
|
||||
"object": "http://mastodon.local:3001/users/testuser"
|
||||
}'
|
||||
```
|
||||
|
||||
## Documentation Files
|
||||
|
||||
| File | Purpose |
|
||||
|------|---------|
|
||||
| `ACTIVITYPUB_TESTING_GUIDE.md` | Comprehensive testing guide |
|
||||
| `ACTIVITYPUB_TESTING_QUICKREF.md` | Quick command reference |
|
||||
| `ACTIVITYPUB_IMPLEMENTATION.md` | Implementation details |
|
||||
| `ACTIVITYPUB_SUMMARY.md` | Feature summary |
|
||||
| `ACTIVITYPUB_PLAN.md` | Original implementation plan |
|
||||
|
||||
## Database Checks
|
||||
|
||||
### Connect to Database
|
||||
```bash
|
||||
psql -d dyson_network
|
||||
```
|
||||
|
||||
### View Actors
|
||||
```sql
|
||||
SELECT uri, username, display_name, created_at
|
||||
FROM fediverse_actors;
|
||||
```
|
||||
|
||||
### View Contents
|
||||
```sql
|
||||
SELECT uri, type, content, actor_id, created_at
|
||||
FROM fediverse_contents
|
||||
ORDER BY created_at DESC
|
||||
LIMIT 10;
|
||||
```
|
||||
|
||||
### View Relationships
|
||||
```sql
|
||||
SELECT state, is_following, is_followed_by, created_at
|
||||
FROM fediverse_relationships;
|
||||
```
|
||||
|
||||
### View Activities
|
||||
```sql
|
||||
SELECT type, status, error_message, created_at
|
||||
FROM fediverse_activities
|
||||
ORDER BY created_at DESC
|
||||
LIMIT 10;
|
||||
```
|
||||
|
||||
## Logs
|
||||
|
||||
### Solar Network Logs
|
||||
```bash
|
||||
# Live logs
|
||||
dotnet run --project DysonNetwork.Sphere
|
||||
|
||||
# Follow ActivityPub activity
|
||||
dotnet run --project DysonNetwork.Sphere 2>&1 | grep -i activitypub
|
||||
|
||||
# Debug logging
|
||||
dotnet run --project DysonNetwork.Sphere --logging:LogLevel:DysonNetwork.Sphere.ActivityPub=Trace
|
||||
```
|
||||
|
||||
### Mastodon Logs
|
||||
```bash
|
||||
# All services
|
||||
docker compose -f docker-compose.mastodon-test.yml logs -f
|
||||
|
||||
# Web service only
|
||||
docker compose -f docker-compose.mastodon-test.yml logs -f web
|
||||
|
||||
# Filter for federation
|
||||
docker compose -f docker-compose.mastodon-test.yml logs -f web | grep -i federation
|
||||
```
|
||||
|
||||
## Stopping Everything
|
||||
|
||||
```bash
|
||||
# Stop Mastodon
|
||||
docker compose -f docker-compose.mastodon-test.yml down
|
||||
|
||||
# Stop with volume cleanup
|
||||
docker compose -f docker-compose.mastodon-test.yml down -v
|
||||
|
||||
# Restore /etc/hosts
|
||||
sudo mv /etc/hosts.backup /etc/hosts
|
||||
|
||||
# Remove test databases (optional)
|
||||
psql -d dyson_network <<EOF
|
||||
TRUNCATE fediverse_activities CASCADE;
|
||||
TRUNCATE fediverse_relationships CASCADE;
|
||||
TRUNCATE fediverse_reactions CASCADE;
|
||||
TRUNCATE fediverse_contents CASCADE;
|
||||
TRUNCATE fediverse_actors CASCADE;
|
||||
TRUNCATE fediverse_instances CASCADE;
|
||||
UPDATE publishers SET meta = NULL WHERE meta IS NOT NULL;
|
||||
EOF
|
||||
```
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### Mastodon won't start
|
||||
|
||||
```bash
|
||||
# Check logs
|
||||
docker compose -f docker-compose.mastodon-test.yml logs -f web
|
||||
|
||||
# Restart
|
||||
docker compose -f docker-compose.mastodon-test.yml restart
|
||||
|
||||
# Recreate
|
||||
docker compose -f docker-compose.mastodon-test.yml down
|
||||
docker compose -f docker-compose.mastodon-test.yml up -d
|
||||
```
|
||||
|
||||
### Can't connect to Solar Network
|
||||
|
||||
```bash
|
||||
# Check if running
|
||||
curl http://solar.local:5000
|
||||
|
||||
# Check logs
|
||||
dotnet run --project DysonNetwork.Sphere 2>&1 | grep -i error
|
||||
|
||||
# Restart
|
||||
# Ctrl+C in terminal and run again
|
||||
```
|
||||
|
||||
### Activities not arriving
|
||||
|
||||
```bash
|
||||
# Check database
|
||||
psql -d dyson_network -c "SELECT * FROM fediverse_activities WHERE status = 3;"
|
||||
|
||||
# Check signature verification logs
|
||||
dotnet run --project DysonNetwork.Sphere 2>&1 | grep -i "signature"
|
||||
|
||||
# Verify actor keys
|
||||
curl -H "Accept: application/activity+json" \
|
||||
http://solar.local:5000/activitypub/actors/solaruser | jq '.publicKey'
|
||||
```
|
||||
|
||||
## Testing Checklist
|
||||
|
||||
- [ ] Setup script completed successfully
|
||||
- [ ] Mastodon is running and accessible
|
||||
- [ ] Solar Network is running and accessible
|
||||
- [ ] WebFinger returns correct data
|
||||
- [ ] Actor profile includes public key
|
||||
- [ ] Follow from Mastodon to Solar Network works
|
||||
- [ ] Follow from Solar Network to Mastodon works
|
||||
- [ ] Posts from Solar Network appear in Mastodon
|
||||
- [ ] Posts from Mastodon appear in Solar Network database
|
||||
- [ ] Likes federate correctly
|
||||
- [ ] Replies federate correctly
|
||||
- [ ] HTTP signatures are verified
|
||||
- [ ] No errors in logs
|
||||
- [ ] Database contains expected data
|
||||
|
||||
## Next Steps
|
||||
|
||||
1. **Test with a real instance**:
|
||||
- Get a public domain or use ngrok
|
||||
- Update `ActivityPub:Domain` in appsettings.json
|
||||
- Test with mastodon.social or other public instances
|
||||
|
||||
2. **Add more features**:
|
||||
- Activity queue for async processing
|
||||
- Retry logic for failed deliveries
|
||||
- Metrics and monitoring
|
||||
- Admin interface for federation management
|
||||
|
||||
3. **Test with more instances**:
|
||||
- Pleroma
|
||||
- Pixelfed
|
||||
- Lemmy
|
||||
- PeerTube
|
||||
|
||||
## Getting Help
|
||||
|
||||
If something doesn't work:
|
||||
|
||||
1. Check the logs (see Logs section above)
|
||||
2. Review the troubleshooting section in [ACTIVITYPUB_TESTING_GUIDE.md](ACTIVITYPUB_TESTING_GUIDE.md)
|
||||
3. Verify all prerequisites are installed
|
||||
4. Check network connectivity between instances
|
||||
5. Review the [ACTIVITYPUB_IMPLEMENTATION.md](ACTIVITYPUB_IMPLEMENTATION.md) for architecture details
|
||||
|
||||
## Useful URLs
|
||||
|
||||
### Test Instances
|
||||
- Mastodon: http://mastodon.local:3001
|
||||
- Solar Network: http://solar.local:5000
|
||||
|
||||
### Documentation
|
||||
- ActivityPub W3C Spec: https://www.w3.org/TR/activitypub/
|
||||
- Mastodon Federation Docs: https://docs.joinmastodon.org/admin/federation/
|
||||
- ActivityPub Playground: https://swicth.github.io/activity-pub-playground/
|
||||
|
||||
### Tools
|
||||
- jq: JSON processor (https://stedolan.github.io/jq/)
|
||||
- httpie: HTTP client (https://httpie.io/)
|
||||
- Docker Compose: (https://docs.docker.com/compose/)
|
||||
275
docs/activitypub/ACTIVITYPUB_TESTING_README.md
Normal file
@@ -0,0 +1,275 @@
|
||||
# ActivityPub Testing Guide
|
||||
|
||||
Complete guide for testing ActivityPub federation in Solar Network.
|
||||
|
||||
## 📚 Documentation Files
|
||||
|
||||
| File | Description | Size |
|
||||
|------|-------------|-------|
|
||||
| `ACTIVITYPUB_TESTING_INDEX.md` | **START HERE** - Master guide with overview | 12K |
|
||||
| `ACTIVITYPUB_TESTING_QUICKSTART.md` | Quick reference for common tasks | 7K |
|
||||
| `ACTIVITYPUB_TESTING_GUIDE.md` | Comprehensive testing scenarios (10 parts) | 19K |
|
||||
| `ACTIVITYPUB_TESTING_QUICKREF.md` | Command and query reference | 8K |
|
||||
| `ACTIVITYPUB_TESTING_HELPER_API.md` | Helper API for programmatic testing | 12K |
|
||||
| `ACTIVITYPUB_TESTING_RESULTS_TEMPLATE.md` | Template to track test results | 10K |
|
||||
|
||||
## 🚀 Quick Start
|
||||
|
||||
### Option A: One-Command Setup (Recommended)
|
||||
|
||||
```bash
|
||||
# 1. Run setup script
|
||||
./setup-activitypub-test.sh
|
||||
|
||||
# 2. Run validation
|
||||
./test-activitypub.sh
|
||||
|
||||
# 3. Start Solar Network
|
||||
cd DysonNetwork.Sphere
|
||||
dotnet run
|
||||
```
|
||||
|
||||
### Option B: Manual Setup
|
||||
|
||||
1. **Read**: `ACTIVITYPUB_TESTING_QUICKSTART.md`
|
||||
2. **Configure**: Copy `.env.testing.example` to `.env` and adjust
|
||||
3. **Follow**: Step-by-step in `ACTIVITYPUB_TESTING_GUIDE.md`
|
||||
|
||||
## 🎯 What You Can Test
|
||||
|
||||
### With Self-Hosted Instance
|
||||
- ✅ WebFinger discovery
|
||||
- ✅ Actor profile retrieval
|
||||
- ✅ Follow relationships (bidirectional)
|
||||
- ✅ Post federation (Solar → Mastodon)
|
||||
- ✅ Content reception (Mastodon → Solar)
|
||||
- ✅ Like interactions
|
||||
- ✅ Reply threading
|
||||
- ✅ HTTP signature verification
|
||||
- ✅ Content deletion
|
||||
|
||||
### With Real Instance
|
||||
- ✅ Public domain setup (via ngrok or VPS)
|
||||
- ✅ Federation with public instances (mastodon.social, etc.)
|
||||
- ✅ Real-world compatibility testing
|
||||
- ✅ Performance under real load
|
||||
|
||||
## 📋 Testing Workflow
|
||||
|
||||
### Day 1: Basic Functionality
|
||||
- Setup test environment
|
||||
- Test WebFinger and Actor endpoints
|
||||
- Verify HTTP signatures
|
||||
- Test basic follow/unfollow
|
||||
|
||||
### Day 2: Content Federation
|
||||
- Test post creation and delivery
|
||||
- Test content reception
|
||||
- Test media attachments
|
||||
- Test content warnings
|
||||
|
||||
### Day 3: Interactions
|
||||
- Test likes (both directions)
|
||||
- Test replies and threading
|
||||
- Test boosts/announces
|
||||
- Test undo activities
|
||||
|
||||
### Day 4: Real Instance
|
||||
- Set up public domain
|
||||
- Test with mastodon.social
|
||||
- Test with other instances
|
||||
- Verify cross-instance compatibility
|
||||
|
||||
### Day 5: Edge Cases
|
||||
- Test error handling
|
||||
- Test failed deliveries
|
||||
- Test invalid signatures
|
||||
- Test malformed activities
|
||||
|
||||
## 🛠️ Setup Scripts
|
||||
|
||||
| Script | Purpose |
|
||||
|--------|---------|
|
||||
| `setup-activitypub-test.sh` | One-command setup of Mastodon + Solar Network |
|
||||
| `test-activitypub.sh` | Quick validation of core functionality |
|
||||
|
||||
Both scripts are executable (`chmod +x`).
|
||||
|
||||
## 🔧 Configuration
|
||||
|
||||
### Required Tools
|
||||
- ✅ Docker (for Mastodon)
|
||||
- ✅ .NET 10 SDK (for Solar Network)
|
||||
- ✅ PostgreSQL client (psql)
|
||||
- ✅ curl (for API testing)
|
||||
|
||||
### Quick Setup
|
||||
```bash
|
||||
# 1. Install dependencies (Ubuntu/Debian)
|
||||
sudo apt-get install docker.io docker-compose postgresql-client curl jq
|
||||
|
||||
# 2. Run setup
|
||||
./setup-activitypub-test.sh
|
||||
|
||||
# 3. Validate
|
||||
./test-activitypub.sh
|
||||
```
|
||||
|
||||
## 📊 Progress Tracking
|
||||
|
||||
Use the template to track your testing progress:
|
||||
|
||||
```bash
|
||||
# Copy the template
|
||||
cp ACTIVITYPUB_TESTING_RESULTS_TEMPLATE.md my-test-results.md
|
||||
|
||||
# Edit as you test
|
||||
nano my-test-results.md
|
||||
```
|
||||
|
||||
## 🐛 Troubleshooting
|
||||
|
||||
### Quick Fixes
|
||||
|
||||
**Mastodon won't start**:
|
||||
```bash
|
||||
# Check logs
|
||||
docker compose -f docker-compose.mastodon-test.yml logs -f
|
||||
|
||||
# Restart containers
|
||||
docker compose -f docker-compose.mastodon-test.yml restart
|
||||
```
|
||||
|
||||
**Can't reach Solar Network**:
|
||||
```bash
|
||||
# Check if running
|
||||
curl http://solar.local:5000
|
||||
|
||||
# Check /etc/hosts
|
||||
cat /etc/hosts | grep solar.local
|
||||
```
|
||||
|
||||
**Activities not arriving**:
|
||||
```bash
|
||||
# Check database
|
||||
psql -d dyson_network -c "SELECT * FROM fediverse_activities;"
|
||||
|
||||
# Check logs
|
||||
dotnet run --project DysonNetwork.Sphere | grep -i activitypub
|
||||
```
|
||||
|
||||
For detailed troubleshooting, see `ACTIVITYPUB_TESTING_GUIDE.md` Part 5.
|
||||
|
||||
## 📖 Learning Path
|
||||
|
||||
### For Developers
|
||||
1. Read `ACTIVITYPUB_IMPLEMENTATION.md` to understand the architecture
|
||||
2. Read `ACTIVITYPUB_SUMMARY.md` to see what's implemented
|
||||
3. Follow test scenarios in `ACTIVITYPUB_TESTING_GUIDE.md`
|
||||
4. Use helper API in `ACTIVITYPUB_TESTING_HELPER_API.md` for testing
|
||||
|
||||
### For Testers
|
||||
1. Start with `ACTIVITYPUB_TESTING_QUICKSTART.md`
|
||||
2. Use command reference in `ACTIVITYPUB_TESTING_QUICKREF.md`
|
||||
3. Track results with `ACTIVITYPUB_TESTING_RESULTS_TEMPLATE.md`
|
||||
4. Report issues with details from logs
|
||||
|
||||
## 🎓 Success Criteria
|
||||
|
||||
### Minimum Viable
|
||||
- WebFinger works
|
||||
- Actor profile valid
|
||||
- Follow relationships work
|
||||
- Posts federate correctly
|
||||
- HTTP signatures verified
|
||||
|
||||
### Production Ready
|
||||
- Activity queue with retry
|
||||
- Rate limiting
|
||||
- Monitoring/alerting
|
||||
- Admin interface
|
||||
- Instance blocking
|
||||
- Content moderation
|
||||
|
||||
## 🚨 Common Pitfalls
|
||||
|
||||
### Don't Forget
|
||||
- ✅ Update `/etc/hosts` with both instances
|
||||
- ✅ Run migrations before testing
|
||||
- ✅ Check both instances are accessible
|
||||
- ✅ Verify PostgreSQL is running
|
||||
- ✅ Check logs when something fails
|
||||
|
||||
### Watch Out For
|
||||
- ❌ Using `localhost` instead of `solar.local`
|
||||
- ❌ Forgetting to restart after config changes
|
||||
- ❌ Not waiting for Mastodon to start (2-5 minutes)
|
||||
- ❌ Ignoring CORS errors in browser testing
|
||||
- ❌ Testing with deleted/invisible posts
|
||||
|
||||
## 📚 Additional Resources
|
||||
|
||||
### Official Specs
|
||||
- [ActivityPub W3C](https://www.w3.org/TR/activitypub/)
|
||||
- [ActivityStreams](https://www.w3.org/TR/activitystreams-core/)
|
||||
- [HTTP Signatures](https://datatracker.ietf.org/doc/html/draft-cavage-http-signatures)
|
||||
|
||||
### Community Guides
|
||||
- [Mastodon Federation](https://docs.joinmastodon.org/admin/federation/)
|
||||
- [Federation Testing](https://docs.joinmastodon.org/spec/activitypub/)
|
||||
|
||||
### Tools
|
||||
- [ActivityPub Playground](https://swicth.github.io/activity-pub-playground/)
|
||||
- [FediTest](https://feditest.com/)
|
||||
|
||||
## 🆘 Support
|
||||
|
||||
If you encounter issues:
|
||||
|
||||
1. Check logs (both Solar Network and Mastodon)
|
||||
2. Review troubleshooting section in the guide
|
||||
3. Validate against success criteria
|
||||
4. Check database state with queries
|
||||
5. Review implementation docs
|
||||
|
||||
## ✨ Next Steps
|
||||
|
||||
After testing with self-hosted instance:
|
||||
|
||||
1. Get a public domain or use ngrok
|
||||
2. Update `ActivityPub:Domain` in appsettings.json
|
||||
3. Test with public Mastodon instances
|
||||
4. Add more ActivityPub features (queue, retry, etc.)
|
||||
5. Implement admin interface
|
||||
6. Add monitoring and metrics
|
||||
|
||||
## 📞 File Reference
|
||||
|
||||
All files are in the root of the DysonNetwork project:
|
||||
|
||||
```
|
||||
DysonNetwork/
|
||||
├── ACTIVITYPUB_TESTING_INDEX.md # Start here!
|
||||
├── ACTIVITYPUB_TESTING_QUICKSTART.md # Quick reference
|
||||
├── ACTIVITYPUB_TESTING_GUIDE.md # Full guide
|
||||
├── ACTIVITYPUB_TESTING_QUICKREF.md # Commands
|
||||
├── ACTIVITYPUB_TESTING_HELPER_API.md # Test API
|
||||
├── ACTIVITYPUB_TESTING_RESULTS_TEMPLATE.md
|
||||
├── setup-activitypub-test.sh # Setup script
|
||||
├── test-activitypub.sh # Test script
|
||||
└── .env.testing.example # Config template
|
||||
```
|
||||
|
||||
**Documentation files** (for reference):
|
||||
```
|
||||
DysonNetwork/
|
||||
├── ACTIVITYPUB_IMPLEMENTATION.md # How it's implemented
|
||||
├── ACTIVITYPUB_SUMMARY.md # Feature summary
|
||||
└── ACTIVITYPUB_PLAN.md # Original plan
|
||||
```
|
||||
|
||||
---
|
||||
|
||||
**Start here**: `ACTIVITYPUB_TESTING_INDEX.md`
|
||||
|
||||
**Good luck with your testing!** 🚀
|
||||
282
docs/activitypub/ACTIVITYPUB_TEST_RESULTS_TEMPLATE.md
Normal file
@@ -0,0 +1,282 @@
|
||||
# ActivityPub Testing Results Template
|
||||
|
||||
Use this template to track your testing progress.
|
||||
|
||||
## Test Environment
|
||||
|
||||
**Date**: ________________
|
||||
|
||||
**Test Configuration**:
|
||||
- Solar Network URL: `http://solar.local:5000`
|
||||
- Mastodon URL: `http://mastodon.local:3001`
|
||||
- Database: `dyson_network`
|
||||
|
||||
**Solar Network User**:
|
||||
- Username: `_______________`
|
||||
- Publisher ID: `_______________`
|
||||
|
||||
**Mastodon User**:
|
||||
- Username: `testuser@mastodon.local`
|
||||
- Password: `TestPassword123!`
|
||||
|
||||
---
|
||||
|
||||
## Test Results
|
||||
|
||||
### ✅ Part 1: Infrastructure Setup
|
||||
|
||||
| Test | Status | Notes |
|
||||
|------|--------|-------|
|
||||
| Setup script ran successfully | ☐ ☑ | |
|
||||
| /etc/hosts updated | ☐ ☑ | |
|
||||
| Docker containers started | ☐ ☑ | |
|
||||
| Mastodon web accessible | ☐ ☑ | |
|
||||
| Mastodon admin account created | ☐ ☑ | |
|
||||
| Database migrations applied | ☐ ☑ | |
|
||||
| Solar Network started | ☐ ☑ | |
|
||||
|
||||
### ✅ Part 2: WebFinger & Actor Discovery
|
||||
|
||||
| Test | Status | Expected | Actual |
|
||||
|------|--------|---------|--------|
|
||||
| WebFinger for Solar Network user | ☐ ☑ | Returns subject + links | _______________ |
|
||||
| Actor profile JSON is valid | ☐ ☑ | Has id, type, inbox, outbox | _______________ |
|
||||
| Public key present in actor | ☐ ☑ | publicKey.publicKeyPem exists | _______________ |
|
||||
| Outbox returns public posts | ☐ ☑ | OrderedCollection with items | _______________ |
|
||||
| Outbox totalItems count | ☐ ☑ | Matches public posts | _______________ |
|
||||
|
||||
### ✅ Part 3: Follow Relationships
|
||||
|
||||
| Test | Status | Expected Result | Actual Result |
|
||||
|------|--------|----------------|---------------|
|
||||
| Mastodon follows Solar Network user | ☐ ☑ | Relationship created in DB | _______________ |
|
||||
| Accept sent to Mastodon | ☐ ☑ | Mastodon receives Accept | _______________ |
|
||||
| Solar Network follows Mastodon user | ☐ ☑ | Relationship created | _______________ |
|
||||
| Follow appears in Mastodon UI | ☐ ☑ | Mastodon shows "Following" | _______________ |
|
||||
| Follow appears in Solar Network DB | ☐ ☑ | is_following = true | _______________ |
|
||||
| Follow state is Accepted | ☐ ☑ | state = 1 (Accepted) | _______________ |
|
||||
| Unfollow works correctly | ☐ ☑ | Relationship deleted/updated | _______________ |
|
||||
|
||||
### ✅ Part 4: Content Federation (Create)
|
||||
|
||||
| Test | Status | Expected Result | Actual Result |
|
||||
|------|--------|----------------|---------------|
|
||||
| Post created in Solar Network | ☐ ☑ | Post in sn_posts table | _______________ |
|
||||
| Activity sent to Mastodon | ☐ ☑ | Logged as successful | _______________ |
|
||||
| Post appears in Mastodon timeline | ☐ ☑ | Visible in federated timeline | _______________ |
|
||||
| Post content matches | ☐ ☑ | Same text/HTML | _______________ |
|
||||
| Post author is correct | ☐ ☑ | Shows Solar Network user | _______________ |
|
||||
| Post timestamp is correct | ☐ ☑ | Same published time | _______________ |
|
||||
| Multiple posts federate | ☐ ☑ | All posts appear | _______________ |
|
||||
|
||||
### ✅ Part 5: Content Reception (Incoming Create)
|
||||
|
||||
| Test | Status | Expected Result | Actual Result |
|
||||
|------|--------|----------------|---------------|
|
||||
| Create activity received | ☐ ☑ | Activity logged in DB | _______________ |
|
||||
| Content stored in fediverse_contents | ☐ ☑ | Record with correct type | _______________ |
|
||||
| Content not duplicated | ☐ ☑ | Only one entry per URI | _______________ |
|
||||
| Actor created/retrieved | ☐ ☑ | Actor in fediverse_actors | _______________ |
|
||||
| Instance created/retrieved | ☐ ☑ | Instance in fediverse_instances | _______________ |
|
||||
| Content HTML preserved | ☐ ☑ | contentHtml field populated | _______________ |
|
||||
|
||||
### ✅ Part 6: Reaction Federation (Like)
|
||||
|
||||
| Test | Status | Expected Result | Actual Result |
|
||||
|------|--------|----------------|---------------|
|
||||
| Like from Mastodon to Solar post | ☐ ☑ | Like activity received | _______________ |
|
||||
| Reaction stored in fediverse_reactions | ☐ ☑ | Record with type = 0 (Like) | _______________ |
|
||||
| Like count incremented | ☐ ☑ | like_count increased | _______________ |
|
||||
| Like appears in UI | ☐ ☑ | Visible on Solar Network | _______________ |
|
||||
| Like appears in Mastodon | ☐ ☑ | Visible on Mastodon | _______________ |
|
||||
| Unlike works correctly | ☐ ☑ | Like removed | _______________ |
|
||||
|
||||
### ✅ Part 7: Reply Federation
|
||||
|
||||
| Test | Status | Expected Result | Actual Result |
|
||||
|------|--------|----------------|---------------|
|
||||
| Reply from Mastodon to Solar post | ☐ ☑ | Create activity with inReplyTo | _______________ |
|
||||
| Reply stored with parent reference | ☐ ☑ | in_reply_to field set | _______________ |
|
||||
| Reply appears in Solar Network | ☐ ☑ | Visible as comment | _______________ |
|
||||
| Reply shows parent context | ☐ ☑ | Links to original post | _______________ |
|
||||
|
||||
### ✅ Part 8: Content Deletion
|
||||
|
||||
| Test | Status | Expected Result | Actual Result |
|
||||
|------|--------|----------------|---------------|
|
||||
| Delete from Mastodon | ☐ ☑ | Delete activity received | _______________ |
|
||||
| Content soft-deleted | ☐ ☑ | deleted_at timestamp set | _______________ |
|
||||
| Content no longer visible | ☐ ☑ | Hidden from timelines | _______________ |
|
||||
|
||||
### ✅ Part 9: HTTP Signature Verification
|
||||
|
||||
| Test | Status | Expected Result | Actual Result |
|
||||
|------|--------|----------------|---------------|
|
||||
| Valid signature accepted | ☐ ☑ | Activity processed | _______________ |
|
||||
| Invalid signature rejected | ☐ ☑ | 401 Unauthorized | _______________ |
|
||||
| Missing signature rejected | ☐ ☑ | 401 Unauthorized | _______________ |
|
||||
| Signature format correct | ☐ ☑ | keyId, algorithm, headers, signature | _______________ |
|
||||
| Signing string correct | ☐ ☑ | Matches HTTP-Signatures draft | _______________ |
|
||||
|
||||
### ✅ Part 10: Error Handling
|
||||
|
||||
| Test | Status | Expected Result | Actual Result |
|
||||
|------|--------|----------------|---------------|
|
||||
| Invalid activity type rejected | ☐ ☑ | 400 Bad Request | _______________ |
|
||||
| Malformed JSON rejected | ☐ ☑ | 400 Bad Request | _______________ |
|
||||
| Non-existent actor rejected | ☐ ☑ | 404 Not Found | _______________ |
|
||||
| Errors logged correctly | ☐ ☑ | error_message populated | _______________ |
|
||||
| Activity status = Failed | ☐ ☑ | status = 3 | _______________ |
|
||||
|
||||
---
|
||||
|
||||
## Database State After Tests
|
||||
|
||||
### Actors Table
|
||||
```sql
|
||||
SELECT COUNT(*) as total_actors,
|
||||
SUM(CASE WHEN is_local_actor THEN 1 ELSE 0 END) as local,
|
||||
SUM(CASE WHEN NOT is_local_actor THEN 1 ELSE 0 END) as remote
|
||||
FROM fediverse_relationships;
|
||||
```
|
||||
- Total Actors: _______________
|
||||
- Local Actors: _______________
|
||||
- Remote Actors: _______________
|
||||
|
||||
### Contents Table
|
||||
```sql
|
||||
SELECT COUNT(*) as total_contents,
|
||||
AVG(LENGTH(content)) as avg_content_length
|
||||
FROM fediverse_contents WHERE deleted_at IS NULL;
|
||||
```
|
||||
- Total Contents: _______________
|
||||
- Avg Content Length: _______________
|
||||
|
||||
### Activities Table
|
||||
```sql
|
||||
SELECT type, status, COUNT(*)
|
||||
FROM fediverse_activities
|
||||
GROUP BY type, status
|
||||
ORDER BY type, status;
|
||||
```
|
||||
- Activities by Type/Status:
|
||||
- Create: Pending ___, Completed ____, Failed ___
|
||||
- Follow: Pending ___, Completed ____, Failed ___
|
||||
- Like: Pending ___, Completed ____, Failed ___
|
||||
- Accept: Pending ___, Completed ____, Failed ___
|
||||
|
||||
### Relationships Table
|
||||
```sql
|
||||
SELECT state, COUNT(*) as count
|
||||
FROM fediverse_relationships
|
||||
GROUP BY state;
|
||||
```
|
||||
- Pending: _______________
|
||||
- Accepted: _______________
|
||||
- Rejected: _______________
|
||||
|
||||
---
|
||||
|
||||
## Logs Analysis
|
||||
|
||||
### Solar Network Errors Found:
|
||||
1. _______________
|
||||
2. _______________
|
||||
3. _______________
|
||||
|
||||
### Mastodon Errors Found:
|
||||
1. _______________
|
||||
2. _______________
|
||||
3. _______________
|
||||
|
||||
### Warnings Found:
|
||||
1. _______________
|
||||
2. _______________
|
||||
3. _______________
|
||||
|
||||
---
|
||||
|
||||
## Issues & Bugs Found
|
||||
|
||||
| # | Severity | Description | Status |
|
||||
|---|----------|-------------|--------|
|
||||
| 1 | ☐ Low/Medium/High/Critical | _____________________ | ☐ Open/☐ Fixed |
|
||||
| 2 | ☐ Low/Medium/High/Critical | _____________________ | ☐ Open/☐ Fixed |
|
||||
| 3 | ☐ Low/Medium/High/Critical | _____________________ | ☐ Open/☐ Fixed |
|
||||
| 4 | ☐ Low/Medium/High/Critical | _____________________ | ☐ Open/☐ Fixed |
|
||||
|
||||
---
|
||||
|
||||
## Performance Notes
|
||||
|
||||
| Metric | Value | Notes |
|
||||
|--------|-------|-------|
|
||||
| Average activity processing time | __________ ms | |
|
||||
| Average HTTP signature verification time | __________ ms | |
|
||||
| Outgoing delivery success rate | __________% | |
|
||||
| Average WebFinger response time | __________ ms | |
|
||||
| Database query performance | __________ | |
|
||||
|
||||
---
|
||||
|
||||
## Compatibility Notes
|
||||
|
||||
| Instance | Version | Works | Notes |
|
||||
|----------|---------|--------|-------|
|
||||
| Mastodon (self-hosted) | latest | ☐ ☑ | |
|
||||
| Mastodon.social | ~4.0 | ☐ ☑ | |
|
||||
| Pleroma | ~2.5 | ☐ ☑ | |
|
||||
| GoToSocial | ~0.15 | ☐ ☑ | |
|
||||
|
||||
---
|
||||
|
||||
## Recommendations
|
||||
|
||||
### What Worked Well:
|
||||
1. _____________________
|
||||
2. _____________________
|
||||
3. _____________________
|
||||
|
||||
### What Needs Improvement:
|
||||
1. _____________________
|
||||
2. _____________________
|
||||
3. _____________________
|
||||
|
||||
### Features to Add:
|
||||
1. _____________________
|
||||
2. _____________________
|
||||
3. _____________________
|
||||
|
||||
---
|
||||
|
||||
## Next Testing Phase
|
||||
|
||||
- [ ] Test with public Mastodon instance
|
||||
- [ ] Test with Pleroma instance
|
||||
- [ ] Test media attachment federation
|
||||
- [ ] Test with high-volume posts
|
||||
- [ ] Test concurrent activity processing
|
||||
- [ ] Test with different visibility levels
|
||||
- [ ] Test with long posts (>500 chars)
|
||||
- [ ] Test with special characters/emojis
|
||||
|
||||
---
|
||||
|
||||
## Sign-off
|
||||
|
||||
**Tested By**: _____________________
|
||||
|
||||
**Test Date**: _____________________
|
||||
|
||||
**Overall Result**: ☐ Pass / ☐ Fail
|
||||
|
||||
**Ready for Production**: ☐ Yes / ☐ No
|
||||
|
||||
**Notes**: ___________________________________________________________________________
|
||||
|
||||
__________________________________________________________________________
|
||||
|
||||
__________________________________________________________________________
|
||||
|
||||
__________________________________________________________________________
|
||||
|
||||
425
docs/activitypub/FOLLOWING_USERS_GUIDE.md
Normal file
@@ -0,0 +1,425 @@
|
||||
# Follow Feature - User Guide
|
||||
|
||||
## Quick Start: How to Follow Fediverse Users
|
||||
|
||||
### Method 1: Via Search (Recommended)
|
||||
|
||||
1. Go to the search bar in Solar Network
|
||||
2. Type the user's full address: `@username@domain.com`
|
||||
- Example: `@alice@mastodon.social`
|
||||
- Example: `@bob@pleroma.site`
|
||||
3. Click on their profile in search results
|
||||
4. Click the "Follow" button
|
||||
5. Wait for acceptance (usually immediate)
|
||||
6. ✅ Done! Their posts will now appear in your timeline
|
||||
|
||||
### Method 2: Via Profile URL
|
||||
|
||||
1. If you know their profile URL, visit it directly:
|
||||
- Example: `https://mastodon.social/@alice`
|
||||
2. Look for the "Follow" button on their profile
|
||||
3. Click it to follow
|
||||
4. ✅ You're now following them!
|
||||
|
||||
## What Happens When You Follow Someone
|
||||
|
||||
### The Technical Flow
|
||||
```
|
||||
You click "Follow"
|
||||
↓
|
||||
Solar Network creates Follow Activity
|
||||
↓
|
||||
Follow Activity is signed with your private key
|
||||
↓
|
||||
Solar Network sends Follow to their instance's inbox
|
||||
↓
|
||||
Their instance verifies your signature
|
||||
↓
|
||||
Their instance processes the Follow
|
||||
↓
|
||||
Their instance sends Accept Activity back
|
||||
↓
|
||||
Solar Network receives and processes Accept
|
||||
↓
|
||||
Relationship is stored in database
|
||||
↓
|
||||
Their public posts federate to Solar Network
|
||||
```
|
||||
|
||||
### What You'll See
|
||||
|
||||
- ✅ **"Following..."** (while waiting for acceptance)
|
||||
- ✅ **"Following" ✓** (when accepted)
|
||||
- ✅ **Their posts** in your home timeline
|
||||
- ✅ **Their likes, replies, boosts** on your posts
|
||||
|
||||
## Different Types of Accounts
|
||||
|
||||
### Regular Users
|
||||
- Full ActivityPub support
|
||||
- Follows work both ways
|
||||
- Content federates normally
|
||||
- Example: `@alice@mastodon.social`
|
||||
|
||||
### Locked Accounts
|
||||
- User must manually approve followers
|
||||
- You'll see "Pending" after clicking follow
|
||||
- User receives notification to approve/deny
|
||||
- Example: `@private@pleroma.site`
|
||||
|
||||
### Bot/Service Accounts
|
||||
- Automated content accounts
|
||||
- Often auto-accept follows
|
||||
- Example: `@newsbot@botsin.space`
|
||||
|
||||
### Organizational Accounts
|
||||
- Group or team accounts
|
||||
- Example: `@team@company.social`
|
||||
|
||||
## Managing Your Follows
|
||||
|
||||
### View Who You're Following
|
||||
|
||||
**Go to**: Following page or `GET /api/activitypub/following`
|
||||
|
||||
You'll see:
|
||||
- Username
|
||||
- Display name
|
||||
- Profile picture
|
||||
- When you followed them
|
||||
- Their instance (e.g., "Mastodon")
|
||||
|
||||
### Unfollowing Someone
|
||||
|
||||
**Method 1: Via UI**
|
||||
1. Go to their profile
|
||||
2. Click "Following" button (shows as active)
|
||||
3. Click to unfollow
|
||||
|
||||
**Method 2: Via API**
|
||||
```bash
|
||||
curl -X POST http://solar.local:5000/api/activitypub/unfollow \
|
||||
-H "Authorization: Bearer YOUR_TOKEN" \
|
||||
-H "Content-Type: application/json" \
|
||||
-d '{
|
||||
"targetActorUri": "https://mastodon.social/users/alice"
|
||||
}'
|
||||
```
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"success": true,
|
||||
"message": "Unfollowed successfully"
|
||||
}
|
||||
```
|
||||
|
||||
### View Your Followers
|
||||
|
||||
**Go to**: Followers page or `GET /api/activitypub/followers`
|
||||
|
||||
You'll see:
|
||||
- Users following you
|
||||
- Their instance
|
||||
- When they started following
|
||||
- Whether they're local or from another instance
|
||||
|
||||
## Searching Fediverse Users
|
||||
|
||||
### How Search Works
|
||||
|
||||
1. **Type in search bar**: `@username@domain.com`
|
||||
2. **Solar Network queries their instance**:
|
||||
- Fetches their actor profile
|
||||
- Checks if they're discoverable
|
||||
3. **Shows results**:
|
||||
- Profile picture
|
||||
- Display name
|
||||
- Bio
|
||||
- Instance name
|
||||
|
||||
### Supported Search Formats
|
||||
|
||||
| Format | Example | Works? |
|
||||
|--------|---------|--------|
|
||||
| Full handle | `@alice@mastodon.social` | ✅ Yes |
|
||||
| Username only | `alice` | ⚠️ May search local users first |
|
||||
| Full URL | `https://mastodon.social/@alice` | ✅ Yes |
|
||||
|
||||
## Privacy Considerations
|
||||
|
||||
### Public Posts
|
||||
- **What**: Posts visible to everyone
|
||||
- **Federation**: ✅ Federates to all followers
|
||||
- **Timeline**: Visible in public federated timelines
|
||||
- **Example**: General updates, thoughts, content you want to share
|
||||
|
||||
### Private Posts
|
||||
- **What**: Posts only visible to followers
|
||||
- **Federation**: ✅ Federates to followers (including remote)
|
||||
- **Timeline**: Only visible to your followers
|
||||
- **Example**: Personal updates, questions
|
||||
|
||||
### Unlisted Posts
|
||||
- **What**: Posts not in public timelines
|
||||
- **Federation**: ✅ Federates but marked unlisted
|
||||
- **Timeline**: Only followers see it
|
||||
- **Example**: Limited audience content
|
||||
|
||||
### Followers-Only Posts
|
||||
- **What**: Posts only to followers, no federated boost
|
||||
- **Federation**: ⚠️ May not federate fully
|
||||
- **Timeline**: Only your followers
|
||||
- **Example**: Very sensitive content
|
||||
|
||||
## Following Etiquette
|
||||
|
||||
### Best Practices
|
||||
|
||||
1. **Check before following**:
|
||||
- Read their bio and recent posts
|
||||
- Make sure they're who you think they are
|
||||
- Check if their content aligns with your interests
|
||||
|
||||
2. **Start with interactions**:
|
||||
- Like a few posts first
|
||||
- Reply thoughtfully
|
||||
- Share interesting content
|
||||
- Then follow if you want to see more
|
||||
|
||||
3. **Respect instance culture**:
|
||||
- Each instance has its own norms
|
||||
- Read their community guidelines
|
||||
- Be mindful of local rules
|
||||
|
||||
4. **Don't spam**:
|
||||
- Don't mass-follow users
|
||||
- Don't send unwanted DMs
|
||||
- Don't repeatedly like old posts
|
||||
|
||||
5. **Use appropriate post visibility**:
|
||||
- Public for general content
|
||||
- Unlisted for updates to followers
|
||||
- Private for sensitive topics
|
||||
|
||||
### Red Flags to Watch
|
||||
|
||||
1. **Suspicious accounts**:
|
||||
- Newly created with generic content
|
||||
- Only posting promotional links
|
||||
- Unusual following patterns
|
||||
|
||||
2. **Instances with poor moderation**:
|
||||
- Lots of spam in public timelines
|
||||
- Harassment goes unaddressed
|
||||
- You may want to block the instance
|
||||
|
||||
3. **Content warnings not respected**:
|
||||
- Users posting unmarked sensitive content
|
||||
- You can report/block these users
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### "Follow button doesn't work"
|
||||
|
||||
**Possible causes**:
|
||||
1. User doesn't exist
|
||||
2. Instance is down
|
||||
3. Network connectivity issue
|
||||
|
||||
**What to do**:
|
||||
1. Verify the username/domain is correct
|
||||
2. Try searching for them again
|
||||
3. Check your internet connection
|
||||
4. Try again in a few minutes
|
||||
|
||||
### "User doesn't appear in Following list"
|
||||
|
||||
**Possible causes**:
|
||||
1. Follow was rejected (locked account)
|
||||
2. Follow is still pending
|
||||
3. Error in federation
|
||||
|
||||
**What to do**:
|
||||
1. Check if their account is locked
|
||||
2. Wait a few minutes for acceptance
|
||||
3. Check your ActivityPub logs
|
||||
4. Try following again
|
||||
|
||||
### "Can't find a user via search"
|
||||
|
||||
**Possible causes**:
|
||||
1. Username/domain is wrong
|
||||
2. User's instance is blocking your instance
|
||||
3. User's profile is not discoverable
|
||||
|
||||
**What to do**:
|
||||
1. Double-check the spelling
|
||||
2. Try their full URL: `https://instance.com/@username`
|
||||
3. Check if they're from a blocked instance
|
||||
4. Contact them directly for their handle
|
||||
|
||||
## API Reference
|
||||
|
||||
### Follow a Remote User
|
||||
|
||||
**Endpoint**: `POST /api/activitypub/follow`
|
||||
|
||||
**Request**:
|
||||
```json
|
||||
{
|
||||
"targetActorUri": "https://mastodon.social/users/alice"
|
||||
}
|
||||
```
|
||||
|
||||
**Success Response**:
|
||||
```json
|
||||
{
|
||||
"success": true,
|
||||
"message": "Follow request sent. Waiting for acceptance.",
|
||||
"targetActorUri": "https://mastodon.social/users/alice"
|
||||
}
|
||||
```
|
||||
|
||||
### Get Your Following
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/following?limit=50`
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"users": [
|
||||
{
|
||||
"actorUri": "https://mastodon.social/users/alice",
|
||||
"username": "alice",
|
||||
"displayName": "Alice Smith",
|
||||
"bio": "I love tech!",
|
||||
"avatarUrl": "https://...",
|
||||
"followedAt": "2024-01-15T10:30:00Z",
|
||||
"isLocal": false,
|
||||
"instanceDomain": "mastodon.social"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
### Get Your Followers
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/followers?limit=50`
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"users": [
|
||||
{
|
||||
"actorUri": "https://pleroma.site/users/bob",
|
||||
"username": "bob",
|
||||
"displayName": "Bob Jones",
|
||||
"bio": "Federated user following me",
|
||||
"avatarUrl": "https://...",
|
||||
"followedAt": "2024-01-10T14:20:00Z",
|
||||
"isLocal": false,
|
||||
"instanceDomain": "pleroma.site"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
### Search Users
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/search?query=@alice@domain.com&limit=20`
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"users": [
|
||||
{
|
||||
"actorUri": "https://mastodon.social/users/alice",
|
||||
"username": "alice",
|
||||
"displayName": "Alice Smith",
|
||||
"bio": "Tech enthusiast",
|
||||
"avatarUrl": "https://...",
|
||||
"isLocal": false,
|
||||
"instanceDomain": "mastodon.social"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
## Real Examples
|
||||
|
||||
### Example 1: Following a Mastodon User
|
||||
|
||||
**What you do**:
|
||||
1. Search for `@alice@mastodon.social`
|
||||
2. Click on Alice's profile
|
||||
3. Click "Follow" button
|
||||
4. Wait 1-2 seconds
|
||||
5. ✅ Alice appears in your "Following" list
|
||||
6. ✅ Alice's public posts appear in your timeline
|
||||
|
||||
**What happens technically**:
|
||||
- Solar Network sends Follow to Alice's Mastodon instance
|
||||
- Alice's Mastodon auto-accepts (unless locked)
|
||||
- Mastodon sends Accept back to Solar Network
|
||||
- Relationship stored in both databases
|
||||
- Alice's future posts federate to Solar Network
|
||||
|
||||
### Example 2: Following a Locked Account
|
||||
|
||||
**What you do**:
|
||||
1. Search for `@private@pleroma.site`
|
||||
2. Click "Follow" button
|
||||
3. ✅ See "Following..." (pending)
|
||||
4. Wait for user to approve
|
||||
|
||||
**What happens technically**:
|
||||
- Solar Network sends Follow to private@pleroma.site
|
||||
- Private user receives notification
|
||||
- Private user manually approves the request
|
||||
- Private user's instance sends Accept
|
||||
- ✅ Now following!
|
||||
|
||||
### Example 3: Following a Bot Account
|
||||
|
||||
**What you do**:
|
||||
1. Search for `@news@botsin.space`
|
||||
2. Click "Follow" button
|
||||
3. ✅ Immediately following (bots auto-accept)
|
||||
|
||||
**What happens technically**:
|
||||
- Follow is auto-accepted
|
||||
- News posts appear in your timeline
|
||||
- Regular updates from the bot
|
||||
|
||||
## Key Differences from Traditional Social Media
|
||||
|
||||
| Aspect | Traditional Social | ActivityPub |
|
||||
|---------|------------------|-------------|
|
||||
| Central server | ❌ No | ✅ Yes (per instance) |
|
||||
| Multiple platforms | ❌ No | ✅ Yes (Mastodon, Pleroma, etc.) |
|
||||
| Data ownership | ❌ On their servers | ✅ On your server |
|
||||
| Blocking | ❌ One platform | ✅ Per instance |
|
||||
| Migration | ❌ Difficult | ✅ Use your own domain |
|
||||
| Federation | ❌ No | ✅ Built-in |
|
||||
|
||||
## Getting Help
|
||||
|
||||
If you have issues following users:
|
||||
|
||||
1. **Check the main guide**: See `HOW_TO_FOLLOW_FEDIVERSE_USERS.md`
|
||||
2. **Check your logs**: Look for ActivityPub errors
|
||||
3. **Test the API**: Use curl to test follow endpoints directly
|
||||
4. **Verify the user**: Make sure the user exists on their instance
|
||||
|
||||
## Summary
|
||||
|
||||
Following fediverse users in Solar Network:
|
||||
|
||||
1. **Simple**: Just search and click "Follow"
|
||||
2. **Works both ways**: You can follow them, they can follow you
|
||||
3. **Works across instances**: Mastodon, Pleroma, Lemmy, etc.
|
||||
4. **Federated content**: Their posts appear in your timeline
|
||||
5. **Full interactions**: Like, reply, boost their posts
|
||||
|
||||
It works just like following on any other social platform, but with the added benefit of being able to follow users on completely different services! 🌍
|
||||
406
docs/activitypub/FOLLOW_FEDIVERSE_USER.md
Normal file
@@ -0,0 +1,406 @@
|
||||
# How to Follow (Subscribe to) Fediverse Users in Solar Network
|
||||
|
||||
## Overview
|
||||
|
||||
In ActivityPub terminology, "subscribing" to a user is called **"following"**. This guide explains how users in Solar Network can follow users from other federated services (Mastodon, Pleroma, etc.).
|
||||
|
||||
## User Guide: How to Follow Fediverse Users
|
||||
|
||||
### Method 1: Via Search (Recommended)
|
||||
|
||||
1. **Search for the user**:
|
||||
- Type their full address in the search bar: `@username@domain.com`
|
||||
- Example: `@alice@mastodon.social`
|
||||
- Example: `@bob@pleroma.site`
|
||||
|
||||
2. **View their profile**:
|
||||
- Click on the search result
|
||||
- You'll see their profile, bio, and recent posts
|
||||
|
||||
3. **Click "Follow" button**:
|
||||
- Solar Network sends a Follow activity to their instance
|
||||
- The remote instance will send back an Accept
|
||||
- The user now appears in your "Following" list
|
||||
|
||||
### Method 2: Via Profile URL
|
||||
|
||||
1. **Visit their profile directly**:
|
||||
- If you know their profile URL, visit it directly
|
||||
- Example: `https://mastodon.social/@alice`
|
||||
|
||||
2. **Look for "Follow" button**:
|
||||
- Click it to follow
|
||||
|
||||
3. **Confirm the follow**:
|
||||
- Solar Network will send the follow request
|
||||
- Wait for acceptance (usually immediate)
|
||||
|
||||
## What Happens Behind the Scenes
|
||||
|
||||
### The Follow Flow
|
||||
|
||||
```
|
||||
User clicks "Follow"
|
||||
↓
|
||||
Solar Network creates Follow Activity
|
||||
↓
|
||||
Solar Network signs with publisher's private key
|
||||
↓
|
||||
Solar Network sends to remote user's inbox
|
||||
↓
|
||||
Remote instance verifies signature
|
||||
↓
|
||||
Remote instance processes the Follow
|
||||
↓
|
||||
Remote instance sends Accept Activity back
|
||||
↓
|
||||
Solar Network receives and processes Accept
|
||||
↓
|
||||
Relationship is established!
|
||||
```
|
||||
|
||||
### Timeline Integration
|
||||
|
||||
Once you're following a user:
|
||||
- ✅ Their public posts appear in your "Home" timeline
|
||||
- ✅ Their posts are federated to your followers
|
||||
- ✅ Their likes, replies, and boosts are visible
|
||||
- ✅ You can interact with their content
|
||||
|
||||
## Following Different Types of Accounts
|
||||
|
||||
### Individual Users
|
||||
- **What**: Regular users like you
|
||||
- **Example**: `@alice@mastodon.social`
|
||||
- **Works**: ✅ Full support
|
||||
|
||||
### Organizational/Bot Accounts
|
||||
- **What**: Groups, bots, or organizations
|
||||
- **Example**: `@official@newsbot.site`
|
||||
- **Works**: ✅ Full support
|
||||
|
||||
### Locked Accounts
|
||||
- **What**: Users who manually approve followers
|
||||
- **Example**: `@private@pleroma.site`
|
||||
- **Works**: ✅ Follow request sent, waits for approval
|
||||
|
||||
## Managing Your Follows
|
||||
|
||||
### View Who You're Following
|
||||
|
||||
**API Endpoint**: `GET /api/activitypub/following`
|
||||
|
||||
**Response Example**:
|
||||
```json
|
||||
{
|
||||
"users": [
|
||||
{
|
||||
"actorUri": "https://mastodon.social/users/alice",
|
||||
"username": "alice",
|
||||
"displayName": "Alice Smith",
|
||||
"bio": "I love tech and coffee! ☕",
|
||||
"avatarUrl": "https://cdn.mastodon.social/avatars/...",
|
||||
"followedAt": "2024-01-15T10:30:00Z",
|
||||
"isLocal": false,
|
||||
"instanceDomain": "mastodon.social"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
### Unfollowing Someone
|
||||
|
||||
**API Endpoint**: `POST /api/activitypub/unfollow`
|
||||
|
||||
**Request Body**:
|
||||
```json
|
||||
{
|
||||
"targetActorUri": "https://mastodon.social/users/alice"
|
||||
}
|
||||
```
|
||||
|
||||
**Response**:
|
||||
```json
|
||||
{
|
||||
"success": true,
|
||||
"message": "Unfollowed successfully"
|
||||
}
|
||||
```
|
||||
|
||||
## Searching Fediverse Users
|
||||
|
||||
**API Endpoint**: `GET /api/activitypub/search?query=@username@domain.com`
|
||||
|
||||
**Response Example**:
|
||||
```json
|
||||
{
|
||||
"users": [
|
||||
{
|
||||
"actorUri": "https://mastodon.social/users/alice",
|
||||
"username": "alice",
|
||||
"displayName": "Alice Smith",
|
||||
"bio": "Software developer | Mastodon user",
|
||||
"avatarUrl": "https://cdn.mastodon.social/avatars/...",
|
||||
"isLocal": false,
|
||||
"instanceDomain": "mastodon.social"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
## Follow States
|
||||
|
||||
| State | Meaning | What User Sees |
|
||||
|--------|---------|----------------|
|
||||
| Pending | Follow request sent, waiting for response | "Following..." (loading) |
|
||||
| Accepted | Remote user accepted | "Following" ✓ |
|
||||
| Rejected | Remote user declined | "Follow" button available again |
|
||||
| Failed | Error occurred | "Error following" message |
|
||||
|
||||
## Privacy & Visibility
|
||||
|
||||
### Public Posts
|
||||
- ✅ Federate to your followers automatically
|
||||
- ✅ Appear in remote instances' timelines
|
||||
- ✅ Can be boosted/liked by remote users
|
||||
|
||||
### Private Posts
|
||||
- ❌ Do not federate
|
||||
- ❌ Only visible to your local followers
|
||||
- ❌ Not sent to remote instances
|
||||
|
||||
### Unlisted Posts
|
||||
- ⚠️ Federate but not in public timelines
|
||||
- ⚠️ Only visible to followers
|
||||
|
||||
## Best Practices for Users
|
||||
|
||||
### When Following Someone
|
||||
|
||||
1. **Check their profile first**:
|
||||
- Make sure they're who you think they are
|
||||
- Read their bio to understand their content
|
||||
|
||||
2. **Start with a few interactions**:
|
||||
- Like a few posts
|
||||
- Reply to something interesting
|
||||
- Don't overwhelm their timeline
|
||||
|
||||
3. **Respect their instance's rules**:
|
||||
- Each instance has its own guidelines
|
||||
- Read community rules before interacting
|
||||
|
||||
4. **Report spam/harassment**:
|
||||
- Use instance blocking features
|
||||
- Report to instance admins
|
||||
|
||||
### Following Across Instances
|
||||
|
||||
1. **Use their full address**:
|
||||
- `@username@instance.com`
|
||||
- This helps identify which instance they're on
|
||||
|
||||
2. **Be aware of instance culture**:
|
||||
- Each instance has its own norms
|
||||
- Some are more technical, others more casual
|
||||
|
||||
3. **Check if they're from your instance**:
|
||||
- Local users show `isLocal: true`
|
||||
- Usually faster interaction
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### "Follow button doesn't work"
|
||||
|
||||
**Possible Causes**:
|
||||
1. User doesn't exist
|
||||
2. Instance is down
|
||||
3. Network issue
|
||||
|
||||
**Solutions**:
|
||||
1. Verify the user's address is correct
|
||||
2. Check if the instance is accessible
|
||||
3. Check your internet connection
|
||||
4. Try again in a few minutes
|
||||
|
||||
### "User doesn't appear in Following list"
|
||||
|
||||
**Possible Causes**:
|
||||
1. Follow was rejected
|
||||
2. Still waiting for acceptance (locked accounts)
|
||||
3. Error in federation
|
||||
|
||||
**Solutions**:
|
||||
1. Check the follow status via API
|
||||
2. Try following again
|
||||
3. Check if their account is locked
|
||||
4. Contact support if issue persists
|
||||
|
||||
### "Can't find a user"
|
||||
|
||||
**Possible Causes**:
|
||||
1. Wrong username or domain
|
||||
2. User doesn't exist
|
||||
3. Instance blocking your instance
|
||||
|
||||
**Solutions**:
|
||||
1. Double-check the address
|
||||
2. Try searching from a different instance
|
||||
3. Contact the user directly for their handle
|
||||
|
||||
## API Reference
|
||||
|
||||
### Follow a Remote User
|
||||
|
||||
**Endpoint**: `POST /api/activitypub/follow`
|
||||
|
||||
**Request**:
|
||||
```json
|
||||
{
|
||||
"targetActorUri": "https://mastodon.social/users/alice"
|
||||
}
|
||||
```
|
||||
|
||||
**Response**: `200 OK`
|
||||
```json
|
||||
{
|
||||
"success": true,
|
||||
"message": "Follow request sent. Waiting for acceptance.",
|
||||
"targetActorUri": "https://mastodon.social/users/alice"
|
||||
}
|
||||
```
|
||||
|
||||
### Get Following List
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/following?limit=50`
|
||||
|
||||
**Response**: `200 OK`
|
||||
```json
|
||||
{
|
||||
"users": [
|
||||
{
|
||||
"actorUri": "https://mastodon.social/users/alice",
|
||||
"username": "alice",
|
||||
"displayName": "Alice Smith",
|
||||
"bio": "...",
|
||||
"avatarUrl": "...",
|
||||
"followedAt": "2024-01-15T10:30:00Z",
|
||||
"isLocal": false,
|
||||
"instanceDomain": "mastodon.social"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
### Get Followers List
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/followers?limit=50`
|
||||
|
||||
**Response**: `200 OK`
|
||||
```json
|
||||
{
|
||||
"users": [
|
||||
{
|
||||
"actorUri": "https://mastodon.social/users/alice",
|
||||
"username": "alice",
|
||||
"displayName": "Alice Smith",
|
||||
"bio": "...",
|
||||
"avatarUrl": "...",
|
||||
"isLocal": false,
|
||||
"instanceDomain": "mastodon.social"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
### Search Users
|
||||
|
||||
**Endpoint**: `GET /api/activitypub/search?query=alice&limit=20`
|
||||
|
||||
**Response**: `200 OK`
|
||||
```json
|
||||
{
|
||||
"users": [
|
||||
{
|
||||
"actorUri": "https://mastodon.social/users/alice",
|
||||
"username": "alice",
|
||||
"displayName": "Alice Smith",
|
||||
"bio": "...",
|
||||
"avatarUrl": "...",
|
||||
"isLocal": false,
|
||||
"instanceDomain": "mastodon.social"
|
||||
}
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
## What's Different About ActivityPub Following?
|
||||
|
||||
Unlike traditional social media:
|
||||
|
||||
| Feature | Traditional Social | ActivityPub |
|
||||
|---------|------------------|-------------|
|
||||
| Central server | ✅ Yes | ❌ No - federated |
|
||||
| All users on same platform | ✅ Yes | ❌ No - multiple platforms |
|
||||
| Blocked instances | ❌ No | ✅ Yes - instance blocking |
|
||||
| Following across platforms | ❌ No | ✅ Yes - works with Mastodon, Pleroma, etc. |
|
||||
| Your data stays on your server | ❌ Maybe | ✅ Yes - you control your data |
|
||||
|
||||
## User Experience Considerations
|
||||
|
||||
### Making It Easy
|
||||
|
||||
1. **Auto-discovery**:
|
||||
- When users search for `@username`, suggest `@username@domain.com`
|
||||
- Offer to search the fediverse
|
||||
|
||||
2. **Clear UI feedback**:
|
||||
- Show "Follow request sent..."
|
||||
- Show "They accepted!" notification
|
||||
- Show "Follow request rejected" message
|
||||
|
||||
3. **Helpful tooltips**:
|
||||
- Explain what ActivityPub is
|
||||
- Show which instance a user is from
|
||||
- Explain locked accounts
|
||||
|
||||
4. **Profile badges**:
|
||||
- Show instance icon/logo
|
||||
- Show if user is from same instance
|
||||
- Show if user is verified
|
||||
|
||||
## Examples
|
||||
|
||||
### Following a Mastodon User
|
||||
|
||||
**User searches**: `@alice@mastodon.social`
|
||||
|
||||
**What happens**:
|
||||
1. Solar Network fetches Alice's actor profile
|
||||
2. Solar Network stores Alice in `fediverse_actors`
|
||||
3. Solar Network sends Follow to Alice's inbox
|
||||
4. Alice's instance accepts
|
||||
5. Solar Network stores relationship in `fediverse_relationships`
|
||||
6. Alice's posts now appear in user's timeline
|
||||
|
||||
### Following a Local User
|
||||
|
||||
**User searches**: `@bob`
|
||||
|
||||
**What happens**:
|
||||
1. Solar Network finds Bob's publisher
|
||||
2. Relationship created locally (no federation needed)
|
||||
3. Bob's posts appear in user's timeline immediately
|
||||
4. Same as traditional social media following
|
||||
|
||||
## Summary
|
||||
|
||||
Following fediverse users in Solar Network:
|
||||
|
||||
1. **Search by `@username@domain.com`** - Works for any ActivityPub instance
|
||||
2. **Click "Follow"** - Sends federated follow request
|
||||
3. **Wait for acceptance** - Remote user can approve or auto-accept
|
||||
4. **See their posts in your timeline** - Content federates to you
|
||||
5. **Interact normally** - Like, reply, boost, etc.
|
||||
|
||||
All of this is handled automatically by the ActivityPub implementation!
|
||||
298
docs/activitypub/UI_IMPLEMENTATION.md
Normal file
@@ -0,0 +1,298 @@
|
||||
# ActivityPub UI Implementation
|
||||
|
||||
## Overview
|
||||
|
||||
Complete UI implementation for ActivityPub features in Solian client, including search, following, and followers screens.
|
||||
|
||||
## Created Files
|
||||
|
||||
### 1. Widgets (`lib/widgets/activitypub/`)
|
||||
|
||||
#### `activitypub.dart`
|
||||
- **Purpose**: Export file for ActivityPub widgets
|
||||
- **Exports**: `ActivityPubUserListItem`
|
||||
|
||||
#### `user_list_item.dart`
|
||||
- **Purpose**: Reusable list item widget for displaying ActivityPub users
|
||||
- **Features**:
|
||||
- Avatar with remote instance indicator (public icon)
|
||||
- Display name with instance badge (e.g., "mastodon.social")
|
||||
- Bio with truncation (max 2 lines)
|
||||
- Followed at timestamp (relative time)
|
||||
- Follow/Unfollow buttons with loading states
|
||||
- Tap callback for navigation to profile
|
||||
|
||||
### 2. Screens (`lib/screens/activitypub/`)
|
||||
|
||||
#### `activitypub.dart`
|
||||
- **Purpose**: Export file for ActivityPub screens
|
||||
- **Exports**: `ActivityPubSearchScreen`, `ActivityPubListScreen`
|
||||
|
||||
#### `search.dart`
|
||||
- **Purpose**: Search and follow ActivityPub users from other instances
|
||||
- **Features**:
|
||||
- Search bar with 500ms debounce
|
||||
- Real-time search results
|
||||
- Instant follow/unfollow actions
|
||||
- Local tracking of followed users
|
||||
- Empty states for no search and no results
|
||||
- Refresh support via pull-to-refresh
|
||||
- User feedback via snack bars
|
||||
- **User Flow**:
|
||||
1. User enters search query (e.g., `@alice@mastodon.social`)
|
||||
2. Results appear after debounce
|
||||
3. User taps "Follow" → Follow request sent
|
||||
4. Success message shown
|
||||
5. Button updates to "Unfollow"
|
||||
|
||||
#### `list.dart`
|
||||
- **Purpose**: Display following/followers lists
|
||||
- **Features**:
|
||||
- Reusable for both Following and Followers
|
||||
- Local state management
|
||||
- Per-user loading states during actions
|
||||
- Empty states with helpful hints
|
||||
- Refresh support
|
||||
- Auto-update lists when actions occur
|
||||
- **Types**:
|
||||
- `ActivityPubListType.following`: Shows users you follow
|
||||
- `ActivityPubListType.followers`: Shows users who follow you
|
||||
- **User Flow**:
|
||||
1. User opens Following/Followers screen
|
||||
2. List loads from API
|
||||
3. User can unfollow (Following tab) or follow (Followers tab)
|
||||
4. List updates automatically
|
||||
5. Success/error messages shown
|
||||
|
||||
## Design Patterns
|
||||
|
||||
### Follows Project Conventions
|
||||
|
||||
1. **Material 3 Design**: All widgets use Material 3 components
|
||||
2. **Styled Widget Package**: Used for `.padding()`, `.textColor()`, etc.
|
||||
3. **Riverpod State Management**: Hooks for local state, providers for global state
|
||||
4. **Error Handling**: `showErrorAlert()` from `alert.dart` for user feedback
|
||||
5. **Success Feedback**: `showSnackBar()` for quick notifications
|
||||
6. **Localization**: All strings use `.tr()` with placeholder args
|
||||
|
||||
### Color Scheme & Theming
|
||||
|
||||
- **Remote Badge**: Uses `Theme.colorScheme.primary` for indicator
|
||||
- **Instance Tag**: Uses `Theme.colorScheme.secondaryContainer`
|
||||
- **Text Colors**: Adaptive based on theme (dark/light)
|
||||
- **States**: Loading indicators with standard `CircularProgressIndicator`
|
||||
|
||||
### Spacing & Layout
|
||||
|
||||
- **List Item Padding**: `EdgeInsets.only(left: 16, right: 12)`
|
||||
- **Avatar Size**: 24px radius (48px diameter)
|
||||
- **Badge Size**: Small (10px font) with 6px horizontal padding
|
||||
- **Button Size**: Minimum 88px width, 36px height
|
||||
|
||||
## Translations Added
|
||||
|
||||
### New Keys in `assets/i18n/en-US.json`
|
||||
|
||||
```json
|
||||
{
|
||||
"searchFediverse": "Search Fediverse",
|
||||
"searchFediverseHint": "Search by address, e.g. {}",
|
||||
"searchFediverseEmpty": "Search for users on other ActivityPub instances",
|
||||
"searchFediverseNoResults": "No users found for this search",
|
||||
"following": "Following",
|
||||
"followers": "Followers",
|
||||
"follow": "Follow",
|
||||
"unfollow": "Unfollow",
|
||||
"followedUser": "Followed @{}",
|
||||
"unfollowedUser": "Unfollowed @{}",
|
||||
"followingEmpty": "You're not following anyone yet",
|
||||
"followersEmpty": "No followers yet",
|
||||
"followingEmptyHint": "Start by searching for users or explore other instances"
|
||||
}
|
||||
```
|
||||
|
||||
## Usage Examples
|
||||
|
||||
### Using Search Screen
|
||||
|
||||
```dart
|
||||
import 'package:go_router/go_router.dart';
|
||||
import 'package:island/screens/activitypub/activitypub.dart';
|
||||
|
||||
// In navigation or route
|
||||
Navigator.push(
|
||||
context,
|
||||
MaterialPageRoute(
|
||||
builder: (context) => const ActivityPubSearchScreen(),
|
||||
),
|
||||
);
|
||||
|
||||
// Or using go_router
|
||||
context.push('/activitypub/search');
|
||||
```
|
||||
|
||||
### Using List Screen
|
||||
|
||||
```dart
|
||||
// Following
|
||||
ActivityPubListScreen(
|
||||
type: ActivityPubListType.following,
|
||||
);
|
||||
|
||||
// Followers
|
||||
ActivityPubListScreen(
|
||||
type: ActivityPubListType.followers,
|
||||
);
|
||||
```
|
||||
|
||||
### Using User List Item Widget
|
||||
|
||||
```dart
|
||||
ActivityPubUserListItem(
|
||||
user: user,
|
||||
isFollowing: isFollowing,
|
||||
isLoading: isLoading,
|
||||
onFollow: () => handleFollow(user),
|
||||
onUnfollow: () => handleUnfollow(user),
|
||||
onTap: () => navigateToProfile(user),
|
||||
);
|
||||
```
|
||||
|
||||
## Integration Points
|
||||
|
||||
### Navigation Integration
|
||||
|
||||
To add ActivityPub screens to navigation:
|
||||
|
||||
1. **Option A**: Add to existing tab/navigation structure
|
||||
2. **Option B**: Add as standalone routes in `go_router`
|
||||
3. **Option C**: Add to profile menu overflow menu
|
||||
|
||||
### Service Integration
|
||||
|
||||
All screens use `activityPubServiceProvider`:
|
||||
|
||||
```dart
|
||||
import 'package:island/services/activitypub_service.dart';
|
||||
|
||||
final service = ref.read(activityPubServiceProvider);
|
||||
```
|
||||
|
||||
### Error Handling
|
||||
|
||||
All errors are caught and displayed using:
|
||||
|
||||
```dart
|
||||
try {
|
||||
// API call
|
||||
} catch (err) {
|
||||
showErrorAlert(err);
|
||||
}
|
||||
```
|
||||
|
||||
## Testing Checklist
|
||||
|
||||
- [ ] Search for existing Mastodon user
|
||||
- [ ] Search for Pleroma user
|
||||
- [ ] Follow a user
|
||||
- [ ] Unfollow a user
|
||||
- [ ] View following list
|
||||
- [ ] View followers list
|
||||
- [ ] Test empty states
|
||||
- [ ] Test loading states
|
||||
- [ ] Test error handling
|
||||
- [ ] Test dark mode
|
||||
- [ ] Test RTL languages (if supported)
|
||||
|
||||
## Technical Details
|
||||
|
||||
### Dependencies
|
||||
|
||||
**Already in project**:
|
||||
- ✅ `cached_network_image` - For avatar images
|
||||
- ✅ `easy_localization` - For translations
|
||||
- ✅ `hooks_riverpod` - For state management
|
||||
- ✅ `flutter_hooks` - For hooks (useState, useEffect, etc.)
|
||||
- ✅ `material_symbols_icons` - For icons
|
||||
- ✅ `relative_time` - For timestamp formatting
|
||||
- ✅ `island/services/activitypub_service.dart` - API service (created earlier)
|
||||
- ✅ `island/widgets/alert.dart` - Error/success dialogs
|
||||
- ✅ `island/models/activitypub.dart` - Data models (created earlier)
|
||||
|
||||
### Performance Considerations
|
||||
|
||||
1. **Debounced Search**: 500ms delay prevents excessive API calls
|
||||
2. **Local State Tracking**: `followingUris` Set prevents duplicate API calls
|
||||
3. **Conditional Rebuilds**: Widget only rebuilds when necessary
|
||||
4. **Image Caching**: Uses `CachedNetworkImageProvider` for avatars
|
||||
|
||||
### Accessibility
|
||||
|
||||
1. **Semantic Labels**: All ListTile widgets have proper content
|
||||
2. **Touch Targets**: Minimum 44px touch targets for buttons
|
||||
3. **Color Contrast**: Follows Material 3 color guidelines
|
||||
4. **Loading Indicators**: Visual feedback during async operations
|
||||
|
||||
## Future Enhancements
|
||||
|
||||
### Potential Additions
|
||||
|
||||
1. **Profile Integration**: Show ActivityPub profile details
|
||||
2. **Post Timeline**: Show federated posts from followed users
|
||||
3. **Instance Blocking**: Block entire ActivityPub instances
|
||||
4. **Advanced Search**: Filter by instance, user type, etc.
|
||||
5. **Batch Actions**: Follow/unfollow multiple users at once
|
||||
6. **Suggested Users**: Show recommended users to follow
|
||||
7. **Recent Activity**: Show recent interactions
|
||||
8. **Notifications**: Follow/unfollow notifications
|
||||
|
||||
### Localization
|
||||
|
||||
Need to add same keys to other language files:
|
||||
- `es-ES.json`
|
||||
- `ja-JP.json`
|
||||
- `ko-KR.json`
|
||||
- etc.
|
||||
|
||||
## Browser Testing
|
||||
|
||||
Test with real ActivityPub instances:
|
||||
- mastodon.social
|
||||
- pixelfed.social
|
||||
- lemmy.world
|
||||
- pleroma.site
|
||||
- fosstodon.org
|
||||
|
||||
## Troubleshooting
|
||||
|
||||
### Common Issues
|
||||
|
||||
1. **Search returns no results**
|
||||
- Check if user exists on remote instance
|
||||
- Verify instance is accessible
|
||||
- Try full URL instead of handle
|
||||
|
||||
2. **Follow button not working**
|
||||
- Check if user is already following
|
||||
- Verify server is online
|
||||
- Check API logs
|
||||
|
||||
3. **Avatar not loading**
|
||||
- Check remote avatar URL
|
||||
- Verify network connection
|
||||
- Check image cache
|
||||
|
||||
## Summary
|
||||
|
||||
✅ **Fully functional ActivityPub UI** with:
|
||||
- Search screen for discovering fediverse users
|
||||
- Following/Followers list screens
|
||||
- Reusable user list item component
|
||||
- Proper error handling and user feedback
|
||||
- Material 3 design
|
||||
- Responsive layout
|
||||
- Local state management
|
||||
- Debounced search
|
||||
- Empty states and loading indicators
|
||||
|
||||
**Ready for integration into main app navigation!** 🎉
|
||||
1
drift_schemas/app_database/drift_schema_v6.json
Normal file
1
drift_schemas/app_database/drift_schema_v7.json
Normal file
@@ -1 +1 @@
|
||||
{"flutter":{"platforms":{"android":{"default":{"projectId":"solian-0x001","appId":"1:961776991058:android:a8d3f7995b0b8e86f4188b","fileOutput":"android/app/google-services.json"}},"ios":{"default":{"projectId":"solian-0x001","appId":"1:961776991058:ios:727229d368cc47e1f4188b","uploadDebugSymbols":false,"fileOutput":"ios/Runner/GoogleService-Info.plist"}},"macos":{"default":{"projectId":"solian-0x001","appId":"1:961776991058:ios:727229d368cc47e1f4188b","uploadDebugSymbols":false,"fileOutput":"macos/Runner/GoogleService-Info.plist"}},"dart":{"lib/firebase_options.dart":{"projectId":"solian-0x001","configurations":{"android":"1:961776991058:android:a8d3f7995b0b8e86f4188b","ios":"1:961776991058:ios:727229d368cc47e1f4188b","macos":"1:961776991058:ios:727229d368cc47e1f4188b","web":"1:961776991058:web:b91d12f2892a5609f4188b","windows":"1:961776991058:web:3a912c0eb14028e5f4188b"}}}}}}
|
||||
{"flutter":{"platforms":{"android":{"default":{"projectId":"solian-0x001","appId":"1:961776991058:android:a8d3f7995b0b8e86f4188b","fileOutput":"android/app/google-services.json"}},"ios":{"default":{"projectId":"solian-0x001","appId":"1:961776991058:ios:727229d368cc47e1f4188b","uploadDebugSymbols":false,"fileOutput":"ios/Runner/GoogleService-Info.plist"}},"macos":{"default":{"projectId":"solian-0x001","appId":"1:961776991058:ios:727229d368cc47e1f4188b","uploadDebugSymbols":false,"fileOutput":"macos/Runner/GoogleService-Info.plist"}},"dart":{"lib/firebase_options.dart":{"projectId":"solian-0x001","configurations":{"android":"1:961776991058:android:a8d3f7995b0b8e86f4188b","ios":"1:961776991058:ios:727229d368cc47e1f4188b","macos":"1:961776991058:ios:727229d368cc47e1f4188b","web":"1:961776991058:web:3a912c0eb14028e5f4188b","windows":"1:961776991058:web:3a912c0eb14028e5f4188b"}}}}}}
|
||||
@@ -21,6 +21,6 @@
|
||||
<key>CFBundleVersion</key>
|
||||
<string>1.0</string>
|
||||
<key>MinimumOSVersion</key>
|
||||
<string>12.0</string>
|
||||
<string>13.0</string>
|
||||
</dict>
|
||||
</plist>
|
||||
|
||||
21
ios/Podfile
@@ -1,5 +1,4 @@
|
||||
# Uncomment this line to define a global platform for your project
|
||||
platform :ios, '13.0'
|
||||
platform :ios, '15.0'
|
||||
|
||||
# CocoaPods analytics sends network stats synchronously affecting flutter build latency.
|
||||
ENV['COCOAPODS_DISABLE_STATS'] = 'true'
|
||||
@@ -32,6 +31,8 @@ target 'Runner' do
|
||||
use_modular_headers!
|
||||
|
||||
pod 'Alamofire'
|
||||
pod 'Kingfisher', '~> 8.0'
|
||||
pod 'KingfisherWebP'
|
||||
|
||||
flutter_install_all_ios_pods File.dirname(File.realpath(__FILE__))
|
||||
|
||||
@@ -41,9 +42,21 @@ target 'Runner' do
|
||||
|
||||
target 'SolianNotificationService' do
|
||||
inherit! :search_paths
|
||||
pod 'Kingfisher', '~> 8.0'
|
||||
pod 'Alamofire'
|
||||
end
|
||||
|
||||
target 'SolianShareExtension' do
|
||||
inherit! :search_paths
|
||||
end
|
||||
end
|
||||
|
||||
target 'Solian Watch App' do
|
||||
platform :watchos, '11.0'
|
||||
|
||||
use_frameworks!
|
||||
use_modular_headers!
|
||||
|
||||
pod 'Kingfisher', '~> 8.0'
|
||||
pod 'KingfisherWebP'
|
||||
end
|
||||
|
||||
post_install do |installer|
|
||||
|
||||
357
ios/Podfile.lock
@@ -1,5 +1,5 @@
|
||||
PODS:
|
||||
- Alamofire (5.10.2)
|
||||
- Alamofire (5.11.0)
|
||||
- connectivity_plus (0.0.1):
|
||||
- Flutter
|
||||
- croppy (0.0.1):
|
||||
@@ -40,39 +40,93 @@ PODS:
|
||||
- file_picker (0.0.1):
|
||||
- DKImagePickerController/PhotoGallery
|
||||
- Flutter
|
||||
- Firebase/CoreOnly (11.13.0):
|
||||
- FirebaseCore (~> 11.13.0)
|
||||
- Firebase/Messaging (11.13.0):
|
||||
- Firebase/CoreOnly
|
||||
- FirebaseMessaging (~> 11.13.0)
|
||||
- firebase_core (3.14.0):
|
||||
- Firebase/CoreOnly (= 11.13.0)
|
||||
- file_saver (0.0.1):
|
||||
- Flutter
|
||||
- firebase_messaging (15.2.7):
|
||||
- Firebase/Messaging (= 11.13.0)
|
||||
- Firebase/CoreOnly (12.6.0):
|
||||
- FirebaseCore (~> 12.6.0)
|
||||
- Firebase/Crashlytics (12.6.0):
|
||||
- Firebase/CoreOnly
|
||||
- FirebaseCrashlytics (~> 12.6.0)
|
||||
- Firebase/Messaging (12.6.0):
|
||||
- Firebase/CoreOnly
|
||||
- FirebaseMessaging (~> 12.6.0)
|
||||
- firebase_analytics (12.1.0):
|
||||
- firebase_core
|
||||
- FirebaseAnalytics (= 12.6.0)
|
||||
- Flutter
|
||||
- firebase_core (4.3.0):
|
||||
- Firebase/CoreOnly (= 12.6.0)
|
||||
- Flutter
|
||||
- firebase_crashlytics (5.0.6):
|
||||
- Firebase/Crashlytics (= 12.6.0)
|
||||
- firebase_core
|
||||
- Flutter
|
||||
- FirebaseCore (11.13.0):
|
||||
- FirebaseCoreInternal (~> 11.13.0)
|
||||
- firebase_messaging (16.1.0):
|
||||
- Firebase/Messaging (= 12.6.0)
|
||||
- firebase_core
|
||||
- Flutter
|
||||
- FirebaseAnalytics (12.6.0):
|
||||
- FirebaseAnalytics/Default (= 12.6.0)
|
||||
- FirebaseCore (~> 12.6.0)
|
||||
- FirebaseInstallations (~> 12.6.0)
|
||||
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
|
||||
- GoogleUtilities/MethodSwizzler (~> 8.1)
|
||||
- GoogleUtilities/Network (~> 8.1)
|
||||
- "GoogleUtilities/NSData+zlib (~> 8.1)"
|
||||
- nanopb (~> 3.30910.0)
|
||||
- FirebaseAnalytics/Default (12.6.0):
|
||||
- FirebaseCore (~> 12.6.0)
|
||||
- FirebaseInstallations (~> 12.6.0)
|
||||
- GoogleAppMeasurement/Default (= 12.6.0)
|
||||
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
|
||||
- GoogleUtilities/MethodSwizzler (~> 8.1)
|
||||
- GoogleUtilities/Network (~> 8.1)
|
||||
- "GoogleUtilities/NSData+zlib (~> 8.1)"
|
||||
- nanopb (~> 3.30910.0)
|
||||
- FirebaseCore (12.6.0):
|
||||
- FirebaseCoreInternal (~> 12.6.0)
|
||||
- GoogleUtilities/Environment (~> 8.1)
|
||||
- GoogleUtilities/Logger (~> 8.1)
|
||||
- FirebaseCoreInternal (11.13.0):
|
||||
- FirebaseCoreExtension (12.6.0):
|
||||
- FirebaseCore (~> 12.6.0)
|
||||
- FirebaseCoreInternal (12.6.0):
|
||||
- "GoogleUtilities/NSData+zlib (~> 8.1)"
|
||||
- FirebaseInstallations (11.13.0):
|
||||
- FirebaseCore (~> 11.13.0)
|
||||
- FirebaseCrashlytics (12.6.0):
|
||||
- FirebaseCore (~> 12.6.0)
|
||||
- FirebaseInstallations (~> 12.6.0)
|
||||
- FirebaseRemoteConfigInterop (~> 12.6.0)
|
||||
- FirebaseSessions (~> 12.6.0)
|
||||
- GoogleDataTransport (~> 10.1)
|
||||
- GoogleUtilities/Environment (~> 8.1)
|
||||
- nanopb (~> 3.30910.0)
|
||||
- PromisesObjC (~> 2.4)
|
||||
- FirebaseInstallations (12.6.0):
|
||||
- FirebaseCore (~> 12.6.0)
|
||||
- GoogleUtilities/Environment (~> 8.1)
|
||||
- GoogleUtilities/UserDefaults (~> 8.1)
|
||||
- PromisesObjC (~> 2.4)
|
||||
- FirebaseMessaging (11.13.0):
|
||||
- FirebaseCore (~> 11.13.0)
|
||||
- FirebaseInstallations (~> 11.0)
|
||||
- GoogleDataTransport (~> 10.0)
|
||||
- FirebaseMessaging (12.6.0):
|
||||
- FirebaseCore (~> 12.6.0)
|
||||
- FirebaseInstallations (~> 12.6.0)
|
||||
- GoogleDataTransport (~> 10.1)
|
||||
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
|
||||
- GoogleUtilities/Environment (~> 8.1)
|
||||
- GoogleUtilities/Reachability (~> 8.1)
|
||||
- GoogleUtilities/UserDefaults (~> 8.1)
|
||||
- nanopb (~> 3.30910.0)
|
||||
- FirebaseRemoteConfigInterop (12.6.0)
|
||||
- FirebaseSessions (12.6.0):
|
||||
- FirebaseCore (~> 12.6.0)
|
||||
- FirebaseCoreExtension (~> 12.6.0)
|
||||
- FirebaseInstallations (~> 12.6.0)
|
||||
- GoogleDataTransport (~> 10.1)
|
||||
- GoogleUtilities/Environment (~> 8.1)
|
||||
- GoogleUtilities/UserDefaults (~> 8.1)
|
||||
- nanopb (~> 3.30910.0)
|
||||
- PromisesSwift (~> 2.1)
|
||||
- Flutter (1.0.0)
|
||||
- flutter_app_update (0.0.1):
|
||||
- Flutter
|
||||
- flutter_inappwebview_ios (0.0.1):
|
||||
- Flutter
|
||||
- flutter_inappwebview_ios/Core (= 0.0.1)
|
||||
@@ -80,21 +134,53 @@ PODS:
|
||||
- flutter_inappwebview_ios/Core (0.0.1):
|
||||
- Flutter
|
||||
- OrderedSet (~> 6.0.3)
|
||||
- flutter_keyboard_visibility (0.0.1):
|
||||
- Flutter
|
||||
- flutter_local_notifications (0.0.1):
|
||||
- Flutter
|
||||
- flutter_native_splash (2.4.3):
|
||||
- Flutter
|
||||
- flutter_platform_alert (0.0.1):
|
||||
- flutter_secure_storage_darwin (10.0.0):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
- flutter_timezone (0.0.1):
|
||||
- Flutter
|
||||
- flutter_udid (0.0.1):
|
||||
- Flutter
|
||||
- SAMKeychain
|
||||
- flutter_webrtc (0.14.0):
|
||||
- KeychainAccess
|
||||
- flutter_webrtc (1.2.0):
|
||||
- Flutter
|
||||
- WebRTC-SDK (= 125.6422.07)
|
||||
- WebRTC-SDK (= 137.7151.04)
|
||||
- gal (1.0.0):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
- GoogleAdsOnDeviceConversion (3.2.0):
|
||||
- GoogleUtilities/Environment (~> 8.1)
|
||||
- GoogleUtilities/Logger (~> 8.1)
|
||||
- GoogleUtilities/Network (~> 8.1)
|
||||
- nanopb (~> 3.30910.0)
|
||||
- GoogleAppMeasurement/Core (12.6.0):
|
||||
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
|
||||
- GoogleUtilities/MethodSwizzler (~> 8.1)
|
||||
- GoogleUtilities/Network (~> 8.1)
|
||||
- "GoogleUtilities/NSData+zlib (~> 8.1)"
|
||||
- nanopb (~> 3.30910.0)
|
||||
- GoogleAppMeasurement/Default (12.6.0):
|
||||
- GoogleAdsOnDeviceConversion (~> 3.2.0)
|
||||
- GoogleAppMeasurement/Core (= 12.6.0)
|
||||
- GoogleAppMeasurement/IdentitySupport (= 12.6.0)
|
||||
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
|
||||
- GoogleUtilities/MethodSwizzler (~> 8.1)
|
||||
- GoogleUtilities/Network (~> 8.1)
|
||||
- "GoogleUtilities/NSData+zlib (~> 8.1)"
|
||||
- nanopb (~> 3.30910.0)
|
||||
- GoogleAppMeasurement/IdentitySupport (12.6.0):
|
||||
- GoogleAppMeasurement/Core (= 12.6.0)
|
||||
- GoogleUtilities/AppDelegateSwizzler (~> 8.1)
|
||||
- GoogleUtilities/MethodSwizzler (~> 8.1)
|
||||
- GoogleUtilities/Network (~> 8.1)
|
||||
- "GoogleUtilities/NSData+zlib (~> 8.1)"
|
||||
- nanopb (~> 3.30910.0)
|
||||
- GoogleDataTransport (10.1.0):
|
||||
- nanopb (~> 3.30910.0)
|
||||
- PromisesObjC (~> 2.4)
|
||||
@@ -108,6 +194,9 @@ PODS:
|
||||
- GoogleUtilities/Logger (8.1.0):
|
||||
- GoogleUtilities/Environment
|
||||
- GoogleUtilities/Privacy
|
||||
- GoogleUtilities/MethodSwizzler (8.1.0):
|
||||
- GoogleUtilities/Logger
|
||||
- GoogleUtilities/Privacy
|
||||
- GoogleUtilities/Network (8.1.0):
|
||||
- GoogleUtilities/Logger
|
||||
- "GoogleUtilities/NSData+zlib"
|
||||
@@ -124,13 +213,34 @@ PODS:
|
||||
- GoogleUtilities/Privacy
|
||||
- image_picker_ios (0.0.1):
|
||||
- Flutter
|
||||
- in_app_review (2.0.0):
|
||||
- Flutter
|
||||
- irondash_engine_context (0.0.1):
|
||||
- Flutter
|
||||
- Kingfisher (8.3.2)
|
||||
- livekit_client (2.4.8):
|
||||
- KeychainAccess (4.2.2)
|
||||
- Kingfisher (8.6.2)
|
||||
- KingfisherWebP (1.7.2):
|
||||
- Kingfisher (~> 8.0)
|
||||
- libwebp (>= 1.1.0)
|
||||
- libwebp (1.5.0):
|
||||
- libwebp/demux (= 1.5.0)
|
||||
- libwebp/mux (= 1.5.0)
|
||||
- libwebp/sharpyuv (= 1.5.0)
|
||||
- libwebp/webp (= 1.5.0)
|
||||
- libwebp/demux (1.5.0):
|
||||
- libwebp/webp
|
||||
- libwebp/mux (1.5.0):
|
||||
- libwebp/demux
|
||||
- libwebp/sharpyuv (1.5.0)
|
||||
- libwebp/webp (1.5.0):
|
||||
- libwebp/sharpyuv
|
||||
- livekit_client (2.5.4):
|
||||
- Flutter
|
||||
- flutter_webrtc
|
||||
- WebRTC-SDK (= 125.6422.07)
|
||||
- WebRTC-SDK (= 137.7151.04)
|
||||
- local_auth_darwin (0.0.1):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
- media_kit_libs_ios_video (1.0.4):
|
||||
- Flutter
|
||||
- media_kit_video (0.0.1):
|
||||
@@ -150,13 +260,26 @@ PODS:
|
||||
- path_provider_foundation (0.0.1):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
- PromisesObjC (2.4.0)
|
||||
- record_ios (1.0.0):
|
||||
- permission_handler_apple (9.3.0):
|
||||
- Flutter
|
||||
- pointer_interceptor_ios (0.0.1):
|
||||
- Flutter
|
||||
- PromisesObjC (2.4.0)
|
||||
- PromisesSwift (2.4.0):
|
||||
- PromisesObjC (= 2.4.0)
|
||||
- protocol_handler_ios (0.0.1):
|
||||
- Flutter
|
||||
- receive_sharing_intent (1.8.1):
|
||||
- Flutter
|
||||
- record_ios (1.1.0):
|
||||
- Flutter
|
||||
- SDWebImage (5.21.5):
|
||||
- SDWebImage/Core (= 5.21.5)
|
||||
- SDWebImage/Core (5.21.5)
|
||||
- sensors_plus (0.0.1):
|
||||
- Flutter
|
||||
- share_plus (0.0.1):
|
||||
- Flutter
|
||||
- SAMKeychain (1.5.3)
|
||||
- SDWebImage (5.21.1):
|
||||
- SDWebImage/Core (= 5.21.1)
|
||||
- SDWebImage/Core (5.21.1)
|
||||
- shared_preferences_foundation (0.0.1):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
@@ -165,38 +288,41 @@ PODS:
|
||||
- sqflite_darwin (0.0.4):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
- sqlite3 (3.50.1):
|
||||
- sqlite3/common (= 3.50.1)
|
||||
- sqlite3/common (3.50.1)
|
||||
- sqlite3/dbstatvtab (3.50.1):
|
||||
- sqlite3 (3.51.1):
|
||||
- sqlite3/common (= 3.51.1)
|
||||
- sqlite3/common (3.51.1)
|
||||
- sqlite3/dbstatvtab (3.51.1):
|
||||
- sqlite3/common
|
||||
- sqlite3/fts5 (3.50.1):
|
||||
- sqlite3/fts5 (3.51.1):
|
||||
- sqlite3/common
|
||||
- sqlite3/math (3.50.1):
|
||||
- sqlite3/math (3.51.1):
|
||||
- sqlite3/common
|
||||
- sqlite3/perf-threadsafe (3.50.1):
|
||||
- sqlite3/perf-threadsafe (3.51.1):
|
||||
- sqlite3/common
|
||||
- sqlite3/rtree (3.50.1):
|
||||
- sqlite3/rtree (3.51.1):
|
||||
- sqlite3/common
|
||||
- sqlite3/session (3.51.1):
|
||||
- sqlite3/common
|
||||
- sqlite3_flutter_libs (0.0.1):
|
||||
- Flutter
|
||||
- FlutterMacOS
|
||||
- sqlite3 (~> 3.50.1)
|
||||
- sqlite3 (~> 3.51.1)
|
||||
- sqlite3/dbstatvtab
|
||||
- sqlite3/fts5
|
||||
- sqlite3/math
|
||||
- sqlite3/perf-threadsafe
|
||||
- sqlite3/rtree
|
||||
- sqlite3/session
|
||||
- super_native_extensions (0.0.1):
|
||||
- Flutter
|
||||
- SwiftyGif (5.4.5)
|
||||
- url_launcher_ios (0.0.1):
|
||||
- syncfusion_flutter_pdfviewer (0.0.1):
|
||||
- Flutter
|
||||
- volume_controller (0.0.1):
|
||||
- url_launcher_ios (0.0.1):
|
||||
- Flutter
|
||||
- wakelock_plus (0.0.1):
|
||||
- Flutter
|
||||
- WebRTC-SDK (125.6422.07)
|
||||
- WebRTC-SDK (137.7151.04)
|
||||
|
||||
DEPENDENCIES:
|
||||
- Alamofire
|
||||
@@ -204,34 +330,49 @@ DEPENDENCIES:
|
||||
- croppy (from `.symlinks/plugins/croppy/ios`)
|
||||
- device_info_plus (from `.symlinks/plugins/device_info_plus/ios`)
|
||||
- file_picker (from `.symlinks/plugins/file_picker/ios`)
|
||||
- file_saver (from `.symlinks/plugins/file_saver/ios`)
|
||||
- firebase_analytics (from `.symlinks/plugins/firebase_analytics/ios`)
|
||||
- firebase_core (from `.symlinks/plugins/firebase_core/ios`)
|
||||
- firebase_crashlytics (from `.symlinks/plugins/firebase_crashlytics/ios`)
|
||||
- firebase_messaging (from `.symlinks/plugins/firebase_messaging/ios`)
|
||||
- Flutter (from `Flutter`)
|
||||
- flutter_app_update (from `.symlinks/plugins/flutter_app_update/ios`)
|
||||
- flutter_inappwebview_ios (from `.symlinks/plugins/flutter_inappwebview_ios/ios`)
|
||||
- flutter_keyboard_visibility (from `.symlinks/plugins/flutter_keyboard_visibility/ios`)
|
||||
- flutter_local_notifications (from `.symlinks/plugins/flutter_local_notifications/ios`)
|
||||
- flutter_native_splash (from `.symlinks/plugins/flutter_native_splash/ios`)
|
||||
- flutter_platform_alert (from `.symlinks/plugins/flutter_platform_alert/ios`)
|
||||
- flutter_secure_storage_darwin (from `.symlinks/plugins/flutter_secure_storage_darwin/darwin`)
|
||||
- flutter_timezone (from `.symlinks/plugins/flutter_timezone/ios`)
|
||||
- flutter_udid (from `.symlinks/plugins/flutter_udid/ios`)
|
||||
- flutter_webrtc (from `.symlinks/plugins/flutter_webrtc/ios`)
|
||||
- gal (from `.symlinks/plugins/gal/darwin`)
|
||||
- image_picker_ios (from `.symlinks/plugins/image_picker_ios/ios`)
|
||||
- in_app_review (from `.symlinks/plugins/in_app_review/ios`)
|
||||
- irondash_engine_context (from `.symlinks/plugins/irondash_engine_context/ios`)
|
||||
- Kingfisher (~> 8.0)
|
||||
- KingfisherWebP
|
||||
- livekit_client (from `.symlinks/plugins/livekit_client/ios`)
|
||||
- local_auth_darwin (from `.symlinks/plugins/local_auth_darwin/darwin`)
|
||||
- media_kit_libs_ios_video (from `.symlinks/plugins/media_kit_libs_ios_video/ios`)
|
||||
- media_kit_video (from `.symlinks/plugins/media_kit_video/ios`)
|
||||
- native_exif (from `.symlinks/plugins/native_exif/ios`)
|
||||
- package_info_plus (from `.symlinks/plugins/package_info_plus/ios`)
|
||||
- pasteboard (from `.symlinks/plugins/pasteboard/ios`)
|
||||
- path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`)
|
||||
- permission_handler_apple (from `.symlinks/plugins/permission_handler_apple/ios`)
|
||||
- pointer_interceptor_ios (from `.symlinks/plugins/pointer_interceptor_ios/ios`)
|
||||
- protocol_handler_ios (from `.symlinks/plugins/protocol_handler_ios/ios`)
|
||||
- receive_sharing_intent (from `.symlinks/plugins/receive_sharing_intent/ios`)
|
||||
- record_ios (from `.symlinks/plugins/record_ios/ios`)
|
||||
- sensors_plus (from `.symlinks/plugins/sensors_plus/ios`)
|
||||
- share_plus (from `.symlinks/plugins/share_plus/ios`)
|
||||
- shared_preferences_foundation (from `.symlinks/plugins/shared_preferences_foundation/darwin`)
|
||||
- sign_in_with_apple (from `.symlinks/plugins/sign_in_with_apple/ios`)
|
||||
- sqflite_darwin (from `.symlinks/plugins/sqflite_darwin/darwin`)
|
||||
- sqlite3_flutter_libs (from `.symlinks/plugins/sqlite3_flutter_libs/darwin`)
|
||||
- super_native_extensions (from `.symlinks/plugins/super_native_extensions/ios`)
|
||||
- syncfusion_flutter_pdfviewer (from `.symlinks/plugins/syncfusion_flutter_pdfviewer/ios`)
|
||||
- url_launcher_ios (from `.symlinks/plugins/url_launcher_ios/ios`)
|
||||
- volume_controller (from `.symlinks/plugins/volume_controller/ios`)
|
||||
- wakelock_plus (from `.symlinks/plugins/wakelock_plus/ios`)
|
||||
|
||||
SPEC REPOS:
|
||||
@@ -240,17 +381,27 @@ SPEC REPOS:
|
||||
- DKImagePickerController
|
||||
- DKPhotoGallery
|
||||
- Firebase
|
||||
- FirebaseAnalytics
|
||||
- FirebaseCore
|
||||
- FirebaseCoreExtension
|
||||
- FirebaseCoreInternal
|
||||
- FirebaseCrashlytics
|
||||
- FirebaseInstallations
|
||||
- FirebaseMessaging
|
||||
- FirebaseRemoteConfigInterop
|
||||
- FirebaseSessions
|
||||
- GoogleAdsOnDeviceConversion
|
||||
- GoogleAppMeasurement
|
||||
- GoogleDataTransport
|
||||
- GoogleUtilities
|
||||
- KeychainAccess
|
||||
- Kingfisher
|
||||
- KingfisherWebP
|
||||
- libwebp
|
||||
- nanopb
|
||||
- OrderedSet
|
||||
- PromisesObjC
|
||||
- SAMKeychain
|
||||
- PromisesSwift
|
||||
- SDWebImage
|
||||
- sqlite3
|
||||
- SwiftyGif
|
||||
@@ -265,18 +416,30 @@ EXTERNAL SOURCES:
|
||||
:path: ".symlinks/plugins/device_info_plus/ios"
|
||||
file_picker:
|
||||
:path: ".symlinks/plugins/file_picker/ios"
|
||||
file_saver:
|
||||
:path: ".symlinks/plugins/file_saver/ios"
|
||||
firebase_analytics:
|
||||
:path: ".symlinks/plugins/firebase_analytics/ios"
|
||||
firebase_core:
|
||||
:path: ".symlinks/plugins/firebase_core/ios"
|
||||
firebase_crashlytics:
|
||||
:path: ".symlinks/plugins/firebase_crashlytics/ios"
|
||||
firebase_messaging:
|
||||
:path: ".symlinks/plugins/firebase_messaging/ios"
|
||||
Flutter:
|
||||
:path: Flutter
|
||||
flutter_app_update:
|
||||
:path: ".symlinks/plugins/flutter_app_update/ios"
|
||||
flutter_inappwebview_ios:
|
||||
:path: ".symlinks/plugins/flutter_inappwebview_ios/ios"
|
||||
flutter_keyboard_visibility:
|
||||
:path: ".symlinks/plugins/flutter_keyboard_visibility/ios"
|
||||
flutter_local_notifications:
|
||||
:path: ".symlinks/plugins/flutter_local_notifications/ios"
|
||||
flutter_native_splash:
|
||||
:path: ".symlinks/plugins/flutter_native_splash/ios"
|
||||
flutter_platform_alert:
|
||||
:path: ".symlinks/plugins/flutter_platform_alert/ios"
|
||||
flutter_secure_storage_darwin:
|
||||
:path: ".symlinks/plugins/flutter_secure_storage_darwin/darwin"
|
||||
flutter_timezone:
|
||||
:path: ".symlinks/plugins/flutter_timezone/ios"
|
||||
flutter_udid:
|
||||
@@ -287,10 +450,14 @@ EXTERNAL SOURCES:
|
||||
:path: ".symlinks/plugins/gal/darwin"
|
||||
image_picker_ios:
|
||||
:path: ".symlinks/plugins/image_picker_ios/ios"
|
||||
in_app_review:
|
||||
:path: ".symlinks/plugins/in_app_review/ios"
|
||||
irondash_engine_context:
|
||||
:path: ".symlinks/plugins/irondash_engine_context/ios"
|
||||
livekit_client:
|
||||
:path: ".symlinks/plugins/livekit_client/ios"
|
||||
local_auth_darwin:
|
||||
:path: ".symlinks/plugins/local_auth_darwin/darwin"
|
||||
media_kit_libs_ios_video:
|
||||
:path: ".symlinks/plugins/media_kit_libs_ios_video/ios"
|
||||
media_kit_video:
|
||||
@@ -303,8 +470,20 @@ EXTERNAL SOURCES:
|
||||
:path: ".symlinks/plugins/pasteboard/ios"
|
||||
path_provider_foundation:
|
||||
:path: ".symlinks/plugins/path_provider_foundation/darwin"
|
||||
permission_handler_apple:
|
||||
:path: ".symlinks/plugins/permission_handler_apple/ios"
|
||||
pointer_interceptor_ios:
|
||||
:path: ".symlinks/plugins/pointer_interceptor_ios/ios"
|
||||
protocol_handler_ios:
|
||||
:path: ".symlinks/plugins/protocol_handler_ios/ios"
|
||||
receive_sharing_intent:
|
||||
:path: ".symlinks/plugins/receive_sharing_intent/ios"
|
||||
record_ios:
|
||||
:path: ".symlinks/plugins/record_ios/ios"
|
||||
sensors_plus:
|
||||
:path: ".symlinks/plugins/sensors_plus/ios"
|
||||
share_plus:
|
||||
:path: ".symlinks/plugins/share_plus/ios"
|
||||
shared_preferences_foundation:
|
||||
:path: ".symlinks/plugins/shared_preferences_foundation/darwin"
|
||||
sign_in_with_apple:
|
||||
@@ -315,42 +494,60 @@ EXTERNAL SOURCES:
|
||||
:path: ".symlinks/plugins/sqlite3_flutter_libs/darwin"
|
||||
super_native_extensions:
|
||||
:path: ".symlinks/plugins/super_native_extensions/ios"
|
||||
syncfusion_flutter_pdfviewer:
|
||||
:path: ".symlinks/plugins/syncfusion_flutter_pdfviewer/ios"
|
||||
url_launcher_ios:
|
||||
:path: ".symlinks/plugins/url_launcher_ios/ios"
|
||||
volume_controller:
|
||||
:path: ".symlinks/plugins/volume_controller/ios"
|
||||
wakelock_plus:
|
||||
:path: ".symlinks/plugins/wakelock_plus/ios"
|
||||
|
||||
SPEC CHECKSUMS:
|
||||
Alamofire: 7193b3b92c74a07f85569e1a6c4f4237291e7496
|
||||
Alamofire: bd5e7b23a1a750975288482c1831d71e74415f86
|
||||
connectivity_plus: cb623214f4e1f6ef8fe7403d580fdad517d2f7dd
|
||||
croppy: 979e8ddc254f4642bffe7d52dc7193354b27ba30
|
||||
device_info_plus: 21fcca2080fbcd348be798aa36c3e5ed849eefbe
|
||||
DKImagePickerController: 946cec48c7873164274ecc4624d19e3da4c1ef3c
|
||||
DKPhotoGallery: b3834fecb755ee09a593d7c9e389d8b5d6deed60
|
||||
file_picker: a0560bc09d61de87f12d246fc47d2119e6ef37be
|
||||
Firebase: 3435bc66b4d494c2f22c79fd3aae4c1db6662327
|
||||
firebase_core: 700bac7ed92bb754fd70fbf01d72b36ecdd6d450
|
||||
firebase_messaging: 860c017fcfbb5e27c163062d1d3135388f3ef954
|
||||
FirebaseCore: c692c7f1c75305ab6aff2b367f25e11d73aa8bd0
|
||||
FirebaseCoreInternal: 29d7b3af4aaf0b8f3ed20b568c13df399b06f68c
|
||||
FirebaseInstallations: 0ee9074f2c1e86561ace168ee1470dc67aabaf02
|
||||
FirebaseMessaging: 195bbdb73e6ca1dbc76cd46e73f3552c084ef6e4
|
||||
Flutter: e0871f40cf51350855a761d2e70bf5af5b9b5de7
|
||||
file_saver: 6cdbcddd690cb02b0c1a0c225b37cd805c2bf8b6
|
||||
Firebase: a451a7b61536298fd5cbfe3a746fd40443a50679
|
||||
firebase_analytics: 4f9cca09e65f6c2944a862c6dc86f6bed9fb769c
|
||||
firebase_core: ba00a168e719694f38960502ceb560285603d073
|
||||
firebase_crashlytics: 13f4b77e9ce2a84b1f8ea07f293db5b6213ce1cf
|
||||
firebase_messaging: bf0e29321927edc02a563c984dbfa5b063864b15
|
||||
FirebaseAnalytics: d0a97a0db6425e5a5d966340b87f92ca7b13a557
|
||||
FirebaseCore: 0e38ad5d62d980a47a64b8e9301ffa311457be04
|
||||
FirebaseCoreExtension: 032fd6f8509e591fda8cb76f6651f20d926b121f
|
||||
FirebaseCoreInternal: 69bf1306a05b8ac43004f6cc1f804bb7b05b229e
|
||||
FirebaseCrashlytics: 3d6248c50726ee7832aef0e53cb84c9e64d9fa7e
|
||||
FirebaseInstallations: 631b38da2e11a83daa4bfb482f79d286a5dfa7ad
|
||||
FirebaseMessaging: a61bc42dcab3f7a346d94bbb54dab2c9435b18b2
|
||||
FirebaseRemoteConfigInterop: 3443b8cb8fffd76bb3e03b2a84bfd3db952fcda4
|
||||
FirebaseSessions: 2e8f808347e665dff3e5843f275715f07045297d
|
||||
Flutter: cabc95a1d2626b1b06e7179b784ebcf0c0cde467
|
||||
flutter_app_update: 816fdb2e30e4832a7c45e3f108d391c42ef040a9
|
||||
flutter_inappwebview_ios: b89ba3482b96fb25e00c967aae065701b66e9b99
|
||||
flutter_keyboard_visibility: 4625131e43015dbbe759d9b20daaf77e0e3f6619
|
||||
flutter_local_notifications: a5a732f069baa862e728d839dd2ebb904737effb
|
||||
flutter_native_splash: c32d145d68aeda5502d5f543ee38c192065986cf
|
||||
flutter_platform_alert: bf3b5fcd4ac14bd637e20527e9c471633071afd3
|
||||
flutter_secure_storage_darwin: acdb3f316ed05a3e68f856e0353b133eec373a23
|
||||
flutter_timezone: 7c838e17ffd4645d261e87037e5bebf6d38fe544
|
||||
flutter_udid: f7c3884e6ec2951efe4f9de082257fc77c4d15e9
|
||||
flutter_webrtc: fd0d3bdef8766a0736dbbe2e5b7e85f1f3c52117
|
||||
flutter_udid: 92a5d31fe0526b7b6002a2318df702e12e7eb300
|
||||
flutter_webrtc: c3e21fc0dcd9d8eb246ae4d5256fcbeb2f5ecd22
|
||||
gal: baecd024ebfd13c441269ca7404792a7152fde89
|
||||
GoogleAdsOnDeviceConversion: d68c69dd9581a0f5da02617b6f377e5be483970f
|
||||
GoogleAppMeasurement: 3bf40aff49a601af5da1c3345702fcb4991d35ee
|
||||
GoogleDataTransport: aae35b7ea0c09004c3797d53c8c41f66f219d6a7
|
||||
GoogleUtilities: 00c88b9a86066ef77f0da2fab05f65d7768ed8e1
|
||||
image_picker_ios: 7fe1ff8e34c1790d6fff70a32484959f563a928a
|
||||
image_picker_ios: e0ece4aa2a75771a7de3fa735d26d90817041326
|
||||
in_app_review: 7dd1ea365263f834b8464673f9df72c80c17c937
|
||||
irondash_engine_context: 8e58ca8e0212ee9d1c7dc6a42121849986c88486
|
||||
Kingfisher: 0621d0ac0c78fecb19f6dc5303bde2b52abaf2f5
|
||||
livekit_client: 9e901890552514206e5ff828903ed271531da264
|
||||
KeychainAccess: c0c4f7f38f6fc7bbe58f5702e25f7bd2f65abf51
|
||||
Kingfisher: 23d18f54677d973b713e54ce6a8f5eef6e7056ba
|
||||
KingfisherWebP: 38b9721821947f547afb78f933f75f4f9e0ae402
|
||||
libwebp: 02b23773aedb6ff1fd38cec7a77b81414c6842a8
|
||||
livekit_client: 53ca658779b78710fb458cccee28b53a13356c15
|
||||
local_auth_darwin: c3ee6cce0a8d56be34c8ccb66ba31f7f180aaebb
|
||||
media_kit_libs_ios_video: 5a18affdb97d1f5d466dc79988b13eff6c5e2854
|
||||
media_kit_video: 1746e198cb697d1ffb734b1d05ec429d1fcd1474
|
||||
nanopb: fad817b59e0457d11a5dfbde799381cd727c1275
|
||||
@@ -358,23 +555,29 @@ SPEC CHECKSUMS:
|
||||
OrderedSet: e539b66b644ff081c73a262d24ad552a69be3a94
|
||||
package_info_plus: af8e2ca6888548050f16fa2f1938db7b5a5df499
|
||||
pasteboard: 49088aeb6119d51f976a421db60d8e1ab079b63c
|
||||
path_provider_foundation: 080d55be775b7414fd5a5ef3ac137b97b097e564
|
||||
path_provider_foundation: bb55f6dbba17d0dccd6737fe6f7f34fbd0376880
|
||||
permission_handler_apple: 4ed2196e43d0651e8ff7ca3483a069d469701f2d
|
||||
pointer_interceptor_ios: da06a662d5bfd329602b45b2ab41bc0fb5fdb0f0
|
||||
PromisesObjC: f5707f49cb48b9636751c5b2e7d227e43fba9f47
|
||||
record_ios: fee1c924aa4879b882ebca2b4bce6011bcfc3d8b
|
||||
SAMKeychain: 483e1c9f32984d50ca961e26818a534283b4cd5c
|
||||
SDWebImage: f29024626962457f3470184232766516dee8dfea
|
||||
shared_preferences_foundation: 9e1978ff2562383bd5676f64ec4e9aa8fa06a6f7
|
||||
PromisesSwift: 9d77319bbe72ebf6d872900551f7eeba9bce2851
|
||||
protocol_handler_ios: 59f23ee71f3ec602d67902ca7f669a80957888d5
|
||||
receive_sharing_intent: 222384f00ffe7e952bbfabaa9e3967cb87e5fe00
|
||||
record_ios: f75fa1d57f840012775c0e93a38a7f3ceea1a374
|
||||
SDWebImage: e9c98383c7572d713c1a0d7dd2783b10599b9838
|
||||
sensors_plus: 6a11ed0c2e1d0bd0b20b4029d3bad27d96e0c65b
|
||||
share_plus: 50da8cb520a8f0f65671c6c6a99b3617ed10a58a
|
||||
shared_preferences_foundation: 7036424c3d8ec98dfe75ff1667cb0cd531ec82bb
|
||||
sign_in_with_apple: c5dcc141574c8c54d5ac99dd2163c0c72ad22418
|
||||
sqflite_darwin: 20b2a3a3b70e43edae938624ce550a3cbf66a3d0
|
||||
sqlite3: 1d85290c3321153511f6e900ede7a1608718bbd5
|
||||
sqlite3_flutter_libs: e7fc8c9ea2200ff3271f08f127842131746b70e2
|
||||
sqlite3: 8d708bc63e9f4ce48f0ad9d6269e478c5ced1d9b
|
||||
sqlite3_flutter_libs: d13b8b3003f18f596e542bcb9482d105577eff41
|
||||
super_native_extensions: b763c02dc3a8fd078389f410bf15149179020cb4
|
||||
SwiftyGif: 706c60cf65fa2bc5ee0313beece843c8eb8194d4
|
||||
url_launcher_ios: 694010445543906933d732453a59da0a173ae33d
|
||||
volume_controller: 3657a1f65bedb98fa41ff7dc5793537919f31b12
|
||||
syncfusion_flutter_pdfviewer: 90dc48305d2e33d4aa20681d1e98ddeda891bc14
|
||||
url_launcher_ios: 7a95fa5b60cc718a708b8f2966718e93db0cef1b
|
||||
wakelock_plus: e29112ab3ef0b318e58cfa5c32326458be66b556
|
||||
WebRTC-SDK: dff00a3892bc570b6014e046297782084071657e
|
||||
WebRTC-SDK: 40d4f5ba05cadff14e4db5614aec402a633f007e
|
||||
|
||||
PODFILE CHECKSUM: 0c13198c20d0416ef589aeb2e1dac5c50262254f
|
||||
PODFILE CHECKSUM: 585198f58dca90ac6492607c83a8d17045ab3852
|
||||
|
||||
COCOAPODS: 1.16.2
|
||||
|
||||
@@ -20,6 +20,20 @@
|
||||
ReferencedContainer = "container:Runner.xcodeproj">
|
||||
</BuildableReference>
|
||||
</BuildActionEntry>
|
||||
<BuildActionEntry
|
||||
buildForTesting = "YES"
|
||||
buildForRunning = "YES"
|
||||
buildForProfiling = "YES"
|
||||
buildForArchiving = "YES"
|
||||
buildForAnalyzing = "YES">
|
||||
<BuildableReference
|
||||
BuildableIdentifier = "primary"
|
||||
BlueprintIdentifier = "7310A7D32EB10962002C0FD3"
|
||||
BuildableName = "Solian Watch App.app"
|
||||
BlueprintName = "Solian Watch App"
|
||||
ReferencedContainer = "container:Runner.xcodeproj">
|
||||
</BuildableReference>
|
||||
</BuildActionEntry>
|
||||
</BuildActionEntries>
|
||||
</BuildAction>
|
||||
<TestAction
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
import Flutter
|
||||
import UIKit
|
||||
import WatchConnectivity
|
||||
|
||||
@main
|
||||
@objc class AppDelegate: FlutterAppDelegate {
|
||||
let notifyDelegate = NotifyDelegate()
|
||||
private static var sharedWatchConnectivityService: WatchConnectivityService?
|
||||
|
||||
override func application(
|
||||
_ application: UIApplication,
|
||||
@@ -11,7 +13,97 @@ import UIKit
|
||||
) -> Bool {
|
||||
UNUserNotificationCenter.current().delegate = notifyDelegate
|
||||
|
||||
let replyableMessageCategory = UNNotificationCategory(
|
||||
identifier: "CHAT_MESSAGE",
|
||||
actions: [
|
||||
UNTextInputNotificationAction(
|
||||
identifier: "reply_action",
|
||||
title: "Reply",
|
||||
options: []
|
||||
),
|
||||
],
|
||||
intentIdentifiers: [],
|
||||
options: []
|
||||
)
|
||||
UNUserNotificationCenter.current().setNotificationCategories([replyableMessageCategory])
|
||||
|
||||
GeneratedPluginRegistrant.register(with: self)
|
||||
|
||||
// Always initialize and retain a strong reference
|
||||
if WCSession.isSupported() {
|
||||
AppDelegate.sharedWatchConnectivityService = WatchConnectivityService.shared
|
||||
} else {
|
||||
print("[iOS] WCSession not supported on this device.")
|
||||
}
|
||||
|
||||
return super.application(application, didFinishLaunchingWithOptions: launchOptions)
|
||||
}
|
||||
}
|
||||
|
||||
final class WatchConnectivityService: NSObject, WCSessionDelegate {
|
||||
static let shared = WatchConnectivityService()
|
||||
private let session: WCSession = .default
|
||||
|
||||
private override init() {
|
||||
super.init()
|
||||
print("[iOS] Activating WCSession...")
|
||||
session.delegate = self
|
||||
session.activate()
|
||||
}
|
||||
|
||||
// MARK: - WCSessionDelegate
|
||||
|
||||
func session(_ session: WCSession, activationDidCompleteWith activationState: WCSessionActivationState, error: Error?) {
|
||||
if let error = error {
|
||||
print("[iOS] WCSession activation failed: \(error.localizedDescription)")
|
||||
} else {
|
||||
print("[iOS] WCSession activated with state: \(activationState.rawValue)")
|
||||
if activationState == .activated {
|
||||
sendDataToWatch()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
func sessionDidBecomeInactive(_ session: WCSession) {}
|
||||
|
||||
func sessionDidDeactivate(_ session: WCSession) {
|
||||
session.activate()
|
||||
}
|
||||
|
||||
func session(_ session: WCSession, didReceiveMessage message: [String : Any], replyHandler: @escaping ([String : Any]) -> Void) {
|
||||
print("[iOS] Received message: \(message)")
|
||||
if let request = message["request"] as? String, request == "data" {
|
||||
let token = UserDefaults.standard.getFlutterToken()
|
||||
let serverUrl = UserDefaults.standard.getServerUrl()
|
||||
|
||||
var data: [String: Any] = ["serverUrl": serverUrl ?? ""]
|
||||
if let token = token {
|
||||
data["token"] = token
|
||||
}
|
||||
|
||||
print("[iOS] Replying with data: \(data)")
|
||||
replyHandler(data)
|
||||
}
|
||||
}
|
||||
|
||||
func sendDataToWatch() {
|
||||
guard session.activationState == .activated else {
|
||||
return
|
||||
}
|
||||
|
||||
let token = UserDefaults.standard.getFlutterToken()
|
||||
let serverUrl = UserDefaults.standard.getServerUrl()
|
||||
|
||||
var data: [String: Any] = ["serverUrl": serverUrl ?? ""]
|
||||
if let token = token {
|
||||
data["token"] = token
|
||||
}
|
||||
|
||||
do {
|
||||
try session.updateApplicationContext(data)
|
||||
print("[iOS] Sent application context: \(data)")
|
||||
} catch {
|
||||
print("[iOS] Failed to send application context: \(error.localizedDescription)")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Before Width: | Height: | Size: 295 B |
|
Before Width: | Height: | Size: 282 B |
|
Before Width: | Height: | Size: 406 B |
|
Before Width: | Height: | Size: 762 B |
@@ -1,8 +1,10 @@
|
||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="10117" systemVersion="15F34" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r">
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="23727" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES" initialViewController="BYZ-38-t0r">
|
||||
<device id="retina6_12" orientation="portrait" appearance="light"/>
|
||||
<dependencies>
|
||||
<deployment identifier="iOS"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="10085"/>
|
||||
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="23721"/>
|
||||
<capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
|
||||
</dependencies>
|
||||
<scenes>
|
||||
<!--Flutter View Controller-->
|
||||
@@ -14,13 +16,14 @@
|
||||
<viewControllerLayoutGuide type="bottom" id="wfy-db-euE"/>
|
||||
</layoutGuides>
|
||||
<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
|
||||
<rect key="frame" x="0.0" y="0.0" width="600" height="600"/>
|
||||
<rect key="frame" x="0.0" y="0.0" width="393" height="852"/>
|
||||
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
|
||||
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
|
||||
<color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
|
||||
</view>
|
||||
</viewController>
|
||||
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
|
||||
</objects>
|
||||
<point key="canvasLocation" x="-26" y="-76"/>
|
||||
</scene>
|
||||
</scenes>
|
||||
</document>
|
||||
|
||||
@@ -2,6 +2,12 @@
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CLIENT_ID</key>
|
||||
<string>961776991058-stt7et4qvn3cpscl4r61gl1hnlatqkig.apps.googleusercontent.com</string>
|
||||
<key>REVERSED_CLIENT_ID</key>
|
||||
<string>com.googleusercontent.apps.961776991058-stt7et4qvn3cpscl4r61gl1hnlatqkig</string>
|
||||
<key>ANDROID_CLIENT_ID</key>
|
||||
<string>961776991058-r4iv9qoio57ul7utbfpgfrda2etvtch8.apps.googleusercontent.com</string>
|
||||
<key>API_KEY</key>
|
||||
<string>AIzaSyCzQIyiYKoYHTpGXhN-IjgMML8z797WVD8</string>
|
||||
<key>GCM_SENDER_ID</key>
|
||||
|
||||
@@ -1,83 +1,110 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
|
||||
<plist version="1.0">
|
||||
<dict>
|
||||
<key>CLIENT_ID</key>
|
||||
<string>961776991058-stt7et4qvn3cpscl4r61gl1hnlatqkig.apps.googleusercontent.com</string>
|
||||
<key>REVERSED_CLIENT_ID</key>
|
||||
<string>com.googleusercontent.apps.961776991058-stt7et4qvn3cpscl4r61gl1hnlatqkig</string>
|
||||
<key>PLIST_VERSION</key>
|
||||
<string>1</string>
|
||||
<key>BUNDLE_ID</key>
|
||||
<string>dev.solsynth.solian</string>
|
||||
<key>ITSAppUsesNonExemptEncryption</key>
|
||||
<false/>
|
||||
<key>CADisableMinimumFrameDurationOnPhone</key>
|
||||
<true/>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>$(DEVELOPMENT_LANGUAGE)</string>
|
||||
<key>CFBundleDisplayName</key>
|
||||
<string>Solian</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>solian</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>$(FLUTTER_BUILD_NAME)</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>$(FLUTTER_BUILD_NUMBER)</string>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>NSCalendarsUsageDescription</key>
|
||||
<string>Grant access to Calander help us to shows Solar Calander with your own events.</string>
|
||||
<key>NSCameraUsageDescription</key>
|
||||
<string>Grant access to Camera will allow Solian take photo or video for your post.</string>
|
||||
<key>NSMicrophoneUsageDescription</key>
|
||||
<string>Grant access to Microphone will allow Solian record audio for your post.</string>
|
||||
<key>NSPhotoLibraryAddUsageDescription</key>
|
||||
<string>Grant access to Photo Library will allow Solian download photo to album for you.</string>
|
||||
<key>NSPhotoLibraryUsageDescription</key>
|
||||
<string>Grant access to Photo Library will allow Solian upload photo or video for your post.</string>
|
||||
<key>UIApplicationSupportsIndirectInputEvents</key>
|
||||
<true/>
|
||||
<key>UIBackgroundModes</key>
|
||||
<array>
|
||||
<string>fetch</string>
|
||||
<string>audio</string>
|
||||
<string>remote-notification</string>
|
||||
<string>voip</string>
|
||||
</array>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIMainStoryboardFile</key>
|
||||
<string>Main</string>
|
||||
<key>UIStatusBarHidden</key>
|
||||
<false/>
|
||||
<key>UISupportedInterfaceOrientations</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>UISupportedInterfaceOrientations~ipad</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
</array>
|
||||
<key>NSUserActivityTypes</key>
|
||||
<array>
|
||||
<string>INStartCallIntent</string>
|
||||
<string>INSendMessageIntent</string>
|
||||
</array>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>AppGroupId</key>
|
||||
<string>$(CUSTOM_GROUP_ID)</string>
|
||||
<key>BUNDLE_ID</key>
|
||||
<string>dev.solsynth.solian</string>
|
||||
<key>CADisableMinimumFrameDurationOnPhone</key>
|
||||
<true/>
|
||||
<key>CFBundleDevelopmentRegion</key>
|
||||
<string>$(DEVELOPMENT_LANGUAGE)</string>
|
||||
<key>CFBundleDisplayName</key>
|
||||
<string>Solian</string>
|
||||
<key>CFBundleExecutable</key>
|
||||
<string>$(EXECUTABLE_NAME)</string>
|
||||
<key>CFBundleIdentifier</key>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>CFBundleInfoDictionaryVersion</key>
|
||||
<string>6.0</string>
|
||||
<key>CFBundleName</key>
|
||||
<string>solian</string>
|
||||
<key>CFBundlePackageType</key>
|
||||
<string>APPL</string>
|
||||
<key>CFBundleShortVersionString</key>
|
||||
<string>$(FLUTTER_BUILD_NAME)</string>
|
||||
<key>CFBundleSignature</key>
|
||||
<string>????</string>
|
||||
<key>CFBundleURLTypes</key>
|
||||
<array>
|
||||
<dict>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>ShareMedia-$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
</array>
|
||||
</dict>
|
||||
<dict>
|
||||
<key>CFBundleTypeRole</key>
|
||||
<string>Editor</string>
|
||||
<key>CFBundleURLName</key>
|
||||
<string></string>
|
||||
<key>CFBundleURLSchemes</key>
|
||||
<array>
|
||||
<string>solian</string>
|
||||
</array>
|
||||
</dict>
|
||||
</array>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>$(FLUTTER_BUILD_NUMBER)</string>
|
||||
<key>CLIENT_ID</key>
|
||||
<string>961776991058-stt7et4qvn3cpscl4r61gl1hnlatqkig.apps.googleusercontent.com</string>
|
||||
<key>ITSAppUsesNonExemptEncryption</key>
|
||||
<false/>
|
||||
<key>LSRequiresIPhoneOS</key>
|
||||
<true/>
|
||||
<key>NSCalendarsUsageDescription</key>
|
||||
<string>Grant access to Calander help us to shows Solar Calander with your own events.</string>
|
||||
<key>NSCameraUsageDescription</key>
|
||||
<string>Grant access to Camera will allow Solian take photo or video for your post.</string>
|
||||
<key>NSFaceIDUsageDescription</key>
|
||||
<string>Allow the Solar Network verify your ownership of the logged in account and continue your action quickly.</string>
|
||||
<key>NSMicrophoneUsageDescription</key>
|
||||
<string>Grant access to Microphone will allow Solian record audio for your post.</string>
|
||||
<key>NSPhotoLibraryAddUsageDescription</key>
|
||||
<string>Grant access to Photo Library will allow Solian download photo to album for you.</string>
|
||||
<key>NSPhotoLibraryUsageDescription</key>
|
||||
<string>Grant access to Photo Library will allow Solian upload photo or video for your post.</string>
|
||||
<key>NSUserActivityTypes</key>
|
||||
<array>
|
||||
<string>INStartCallIntent</string>
|
||||
<string>INSendMessageIntent</string>
|
||||
</array>
|
||||
<key>PLIST_VERSION</key>
|
||||
<string>1</string>
|
||||
<key>REVERSED_CLIENT_ID</key>
|
||||
<string>com.googleusercontent.apps.961776991058-stt7et4qvn3cpscl4r61gl1hnlatqkig</string>
|
||||
<key>UIApplicationSupportsIndirectInputEvents</key>
|
||||
<true/>
|
||||
<key>UIBackgroundModes</key>
|
||||
<array>
|
||||
<string>fetch</string>
|
||||
<string>audio</string>
|
||||
<string>remote-notification</string>
|
||||
<string>voip</string>
|
||||
</array>
|
||||
<key>UILaunchStoryboardName</key>
|
||||
<string>LaunchScreen</string>
|
||||
<key>UIMainStoryboardFile</key>
|
||||
<string>Main</string>
|
||||
<key>UIStatusBarHidden</key>
|
||||
<false/>
|
||||
<key>UISupportedInterfaceOrientations</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
</array>
|
||||
<key>WKCompanionAppBundleIdentifier</key>
|
||||
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
|
||||
<key>UISupportedInterfaceOrientations~ipad</key>
|
||||
<array>
|
||||
<string>UIInterfaceOrientationLandscapeLeft</string>
|
||||
<string>UIInterfaceOrientationLandscapeRight</string>
|
||||
<string>UIInterfaceOrientationPortrait</string>
|
||||
<string>UIInterfaceOrientationPortraitUpsideDown</string>
|
||||
</array>
|
||||
</dict>
|
||||
</plist>
|
||||
|
||||
@@ -10,40 +10,51 @@ import Alamofire
|
||||
|
||||
class NotifyDelegate: UIResponder, UNUserNotificationCenterDelegate {
|
||||
func userNotificationCenter(_ center: UNUserNotificationCenter, didReceive response: UNNotificationResponse, withCompletionHandler completionHandler: @escaping () -> Void) {
|
||||
if let textResponse = response as? UNTextInputNotificationResponse {
|
||||
let content = response.notification.request.content
|
||||
guard let metadata = content.userInfo["meta"] as? [AnyHashable: Any] else {
|
||||
return
|
||||
}
|
||||
|
||||
var token: String? = UserDefaults.standard.getFlutterToken()
|
||||
if token == nil {
|
||||
return
|
||||
}
|
||||
|
||||
let serverUrl = UserDefaults.standard.getServerUrl()
|
||||
let url = "\(serverUrl)/chat/\(metadata["room_id"] ?? "")/messages"
|
||||
|
||||
let parameters: [String: Any?] = [
|
||||
"content": textResponse.userText,
|
||||
"replied_message_id": metadata["message_id"]
|
||||
]
|
||||
|
||||
AF.request(url, method: .post, parameters: parameters, encoding: JSONEncoding.default, headers: HTTPHeaders(
|
||||
[HTTPHeader(name: "Authorization", value: "AtField \(token!)")]
|
||||
))
|
||||
.validate()
|
||||
.responseString { response in
|
||||
switch response.result {
|
||||
case .success(_):
|
||||
break
|
||||
case .failure(let error):
|
||||
print("Failed to send chat reply message: \(error)")
|
||||
break
|
||||
}
|
||||
}
|
||||
guard let textResponse = response as? UNTextInputNotificationResponse else {
|
||||
completionHandler()
|
||||
return
|
||||
}
|
||||
|
||||
completionHandler()
|
||||
let content = response.notification.request.content
|
||||
|
||||
// Only handle replies for new messages
|
||||
guard let notificationType = content.userInfo["type"] as? String, notificationType == "messages.new" else {
|
||||
completionHandler()
|
||||
return
|
||||
}
|
||||
|
||||
guard let metadata = content.userInfo["meta"] as? [AnyHashable: Any] else {
|
||||
completionHandler()
|
||||
return
|
||||
}
|
||||
|
||||
guard let token = UserDefaults.standard.getFlutterToken() else {
|
||||
completionHandler()
|
||||
return
|
||||
}
|
||||
|
||||
let serverUrl = UserDefaults.standard.getServerUrl()
|
||||
let url = "\(serverUrl)/messager/chat/\(metadata["room_id"] ?? "")/messages"
|
||||
|
||||
let parameters: [String: Any?] = [
|
||||
"content": textResponse.userText,
|
||||
"replied_message_id": metadata["message_id"]
|
||||
]
|
||||
|
||||
AF.request(url, method: .post, parameters: parameters, encoding: JSONEncoding.default, headers: HTTPHeaders(
|
||||
[HTTPHeader(name: "Authorization", value: "AtField \(token)")]
|
||||
))
|
||||
.validate()
|
||||
.responseString { response in
|
||||
switch response.result {
|
||||
case .success(_):
|
||||
break
|
||||
case .failure(let error):
|
||||
print("Failed to send chat reply message: \(error)")
|
||||
break
|
||||
}
|
||||
// Call completion handler after network request is finished
|
||||
completionHandler()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -11,10 +11,15 @@
|
||||
<key>com.apple.developer.associated-domains</key>
|
||||
<array>
|
||||
<string>webcredentials:solian.app</string>
|
||||
<string>applinks:solian.app</string>
|
||||
</array>
|
||||
<key>com.apple.developer.device-information.user-assigned-device-name</key>
|
||||
<true/>
|
||||
<key>com.apple.developer.usernotifications.communication</key>
|
||||
<true/>
|
||||
<key>com.apple.security.application-groups</key>
|
||||
<array>
|
||||
<string>group.solsynth.solian</string>
|
||||
</array>
|
||||
</dict>
|
||||
</plist>
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
import Foundation
|
||||
|
||||
func getAttachmentUrl(for identifier: String) -> String {
|
||||
let serverBaseUrl = "https://nt.solian.app"
|
||||
let serverBaseUrl = UserDefaults.standard.getServerUrl()
|
||||
|
||||
return identifier.starts(with: "http") ? identifier : "\(serverBaseUrl)/files/\(identifier)"
|
||||
return identifier.starts(with: "http") ? identifier : "\(serverBaseUrl)/drive/files/\(identifier)"
|
||||
}
|
||||
|
||||
@@ -26,6 +26,6 @@ extension UserDefaults {
|
||||
}
|
||||
|
||||
func getServerUrl(forKey key: String = "app_server_url") -> String {
|
||||
return self.getFlutterValue(forKey: key) ?? "https://nt.solian.app"
|
||||
return self.getFlutterValue(forKey: key) ?? "https://api.solian.app"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
{
|
||||
"colors" : [
|
||||
{
|
||||
"color" : {
|
||||
"platform" : "universal",
|
||||
"reference" : "systemIndigoColor"
|
||||
},
|
||||
"idiom" : "universal"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,318 @@
|
||||
{
|
||||
"images" : [
|
||||
{
|
||||
"filename" : "icon-ios-20x20@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "20x20"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-20x20@3x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "3x",
|
||||
"size" : "20x20"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-29x29@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "29x29"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-29x29@3x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "3x",
|
||||
"size" : "29x29"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-38x38@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "38x38"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-38x38@3x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "3x",
|
||||
"size" : "38x38"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-40x40@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "40x40"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-40x40@3x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "3x",
|
||||
"size" : "40x40"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-60x60@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "60x60"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-60x60@3x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "3x",
|
||||
"size" : "60x60"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-64x64@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "64x64"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-64x64@3x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "3x",
|
||||
"size" : "64x64"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-68x68@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "68x68"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-76x76@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "76x76"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-83.5x83.5@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"scale" : "2x",
|
||||
"size" : "83.5x83.5"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-ios-1024x1024.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "ios",
|
||||
"size" : "1024x1024"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-16x16.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "1x",
|
||||
"size" : "16x16"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-16x16@2x.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "2x",
|
||||
"size" : "16x16"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-32x32.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "1x",
|
||||
"size" : "32x32"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-32x32@2x.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "2x",
|
||||
"size" : "32x32"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-128x128.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "1x",
|
||||
"size" : "128x128"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-128x128@2x.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "2x",
|
||||
"size" : "128x128"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-256x256.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "1x",
|
||||
"size" : "256x256"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-256x256@2x.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "2x",
|
||||
"size" : "256x256"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-512x512.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "1x",
|
||||
"size" : "512x512"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-mac-512x512@2x.png",
|
||||
"idiom" : "mac",
|
||||
"scale" : "2x",
|
||||
"size" : "512x512"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-22x22@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "22x22"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-24x24@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "24x24"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-27.5x27.5@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "27.5x27.5"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-29x29@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "29x29"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-30x30@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "30x30"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-32x32@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "32x32"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-33x33@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "33x33"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-40x40@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "40x40"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-43.5x43.5@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "43.5x43.5"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-44x44@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "44x44"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-46x46@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "46x46"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-50x50@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "50x50"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-51x51@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "51x51"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-54x54@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "54x54"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-86x86@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "86x86"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-98x98@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "98x98"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-108x108@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "108x108"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-117x117@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "117x117"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-129x129@2x.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"scale" : "2x",
|
||||
"size" : "129x129"
|
||||
},
|
||||
{
|
||||
"filename" : "icon-watchos-1024x1024.png",
|
||||
"idiom" : "universal",
|
||||
"platform" : "watchos",
|
||||
"size" : "1024x1024"
|
||||
}
|
||||
],
|
||||
"info" : {
|
||||
"author" : "xcode",
|
||||
"version" : 1
|
||||
}
|
||||
}
|
||||
|
After Width: | Height: | Size: 45 KiB |
|
After Width: | Height: | Size: 1.5 KiB |
|
After Width: | Height: | Size: 2.5 KiB |
|
After Width: | Height: | Size: 2.4 KiB |
|
After Width: | Height: | Size: 4.1 KiB |
|
After Width: | Height: | Size: 3.4 KiB |
|
After Width: | Height: | Size: 5.7 KiB |
|
After Width: | Height: | Size: 3.6 KiB |
|
After Width: | Height: | Size: 6.1 KiB |
|
After Width: | Height: | Size: 6.1 KiB |
|
After Width: | Height: | Size: 9.6 KiB |
|
After Width: | Height: | Size: 6.6 KiB |
|
After Width: | Height: | Size: 10 KiB |
|
After Width: | Height: | Size: 7.0 KiB |
|
After Width: | Height: | Size: 7.8 KiB |
|
After Width: | Height: | Size: 8.8 KiB |
|
After Width: | Height: | Size: 6.6 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 473 B |
|
After Width: | Height: | Size: 1.2 KiB |
|
After Width: | Height: | Size: 14 KiB |
|
After Width: | Height: | Size: 30 KiB |
|
After Width: | Height: | Size: 1.2 KiB |