Jean-Paul Calderone
dffcdf2854
Clean up the Py2/Py3 boilerplate
2022-04-11 15:05:32 -04:00
Jean-Paul Calderone
f19bf8cf86
Parameterize the options object to the run_cli
helper
2022-04-11 15:04:55 -04:00
Itamar Turner-Trauring
4b20b67ce6
Client-side schema validation.
2022-04-11 14:03:48 -04:00
Itamar Turner-Trauring
dfad50b1c2
Better error.
2022-04-11 14:03:30 -04:00
Itamar Turner-Trauring
e5b0e51f72
Server-side schema validation of CBOR.
2022-04-11 13:11:45 -04:00
Itamar Turner-Trauring
bdcf054de6
Switch to generating certs on the fly since Python packaging was being a pain.
2022-04-08 13:37:18 -04:00
Itamar Turner-Trauring
423512ad00
Wait harder.
2022-04-06 11:48:17 -04:00
Itamar Turner-Trauring
22ebbba5ac
Extend testing.
2022-04-06 11:35:05 -04:00
Itamar Turner-Trauring
5a82ea880b
More specific methods.
2022-04-06 11:31:26 -04:00
Itamar Turner-Trauring
ab1297cdd6
Link to ticket.
2022-04-06 11:27:42 -04:00
Itamar Turner-Trauring
eda5925548
Get rid of another place where listen on port 0, and switch to FilePath only for now.
2022-04-06 11:25:37 -04:00
Itamar Turner-Trauring
710fad4f8a
Support broader range of server endpoints, and switch to more robust random port
...
assignment.
2022-04-06 11:10:42 -04:00
Itamar Turner-Trauring
2e934574f0
Switch to URL-safe base64 for SPKI hash, for nicer usage in NURLs.
2022-04-06 09:37:18 -04:00
Itamar Turner-Trauring
5972a13457
Add reactor argument.
2022-04-06 09:34:17 -04:00
Itamar Turner-Trauring
30a3b006a0
Include self-signed cert in package install.
2022-03-30 10:26:26 -04:00
Itamar Turner-Trauring
da6838d6f9
Stop talking about furl, it's a NURL.
2022-03-28 11:35:45 -04:00
Itamar Turner-Trauring
119ba9468e
Not needed.
2022-03-28 11:28:38 -04:00
Itamar Turner-Trauring
4e58748c4a
Get constants from OpenSSL directly.
2022-03-28 11:27:32 -04:00
Itamar Turner-Trauring
ae8a7eff43
Make mypy happy.
2022-03-25 15:52:31 -04:00
Itamar Turner-Trauring
638154b2ad
Cleanups.
2022-03-25 15:46:42 -04:00
Itamar Turner-Trauring
23ce581405
More tests; some still failing.
2022-03-25 14:01:06 -04:00
Itamar Turner-Trauring
bd6e537891
Hacky fix.
2022-03-25 13:52:25 -04:00
Itamar Turner-Trauring
712f4f1385
Sketch of first HTTPS client logic test.
2022-03-25 13:49:11 -04:00
Itamar Turner-Trauring
6f86675766
Split into its own file.
2022-03-25 10:59:16 -04:00
Itamar Turner-Trauring
9240d9d657
Expand the comment.
2022-03-25 10:46:14 -04:00
Itamar Turner-Trauring
e50d88f46d
Technically this doesn't matter, because it's client-side, but it's good habit.
2022-03-25 10:45:54 -04:00
meejah
cc682d0413
Merge branch 'master' into 3828.key-length
2022-03-24 11:40:52 -06:00
Itamar Turner-Trauring
be0ff08275
Possibly correct, but communicating, end-to-end TLS with some amount of
...
validation logic.
Still untested!
2022-03-24 12:12:11 -04:00
Jean-Paul Calderone
f48055179f
Merge pull request #1186 from tahoe-lafs/3883.drop-cpuusagemonitor-foolscap-dep
...
Drop the Foolscap dependency in allmydata.stats
Fixes: ticket:3883
2022-03-24 08:09:42 -04:00
Jean-Paul Calderone
c737bcdb6f
use the generic version of the correct types for samples
2022-03-23 18:40:12 -04:00
Itamar Turner-Trauring
5310747eaa
Start hooking up end-to-end tests with TLS, fixing bugs along the way.
...
At this point the issue is that the client fails certificate validation (which
is expected lacking the pinning validation logic, which should be added next).
2022-03-23 16:33:29 -04:00
Itamar Turner-Trauring
eef99c1f22
Merge remote-tracking branch 'origin/master' into 3875-http-storage-furls
2022-03-23 15:59:07 -04:00
Jean-Paul Calderone
98634ae5cb
allow the correct number of samples in
...
also speed up the test with some shorter intervals
2022-03-18 12:36:48 -04:00
Jean-Paul Calderone
b56f79c7ad
read initial cpu usage value at service start time
...
This removes the Foolscap dependency.
2022-03-18 10:43:17 -04:00
Jean-Paul Calderone
ce381f3e39
pull the default initial_cpu value out to class scope
...
also add python 3 syntax type annotations
2022-03-18 10:42:40 -04:00
Jean-Paul Calderone
32e88e580b
switch to a deque
...
this makes more of the data structure someone else's responsibility and
probably improves performance too (but I didn't measure)
2022-03-18 10:41:33 -04:00
Jean-Paul Calderone
b83b6adfbc
remove py2 compat boilerplate
2022-03-18 10:41:07 -04:00
Itamar Turner-Trauring
7de3d93b0e
Switch to TypeError.
2022-03-18 10:12:51 -04:00
Itamar Turner-Trauring
fae9556e3d
Centralize client serialization logic too.
2022-03-14 11:28:54 -04:00
Itamar Turner-Trauring
0aa8089d81
Explicitly tell the server that the client accepts CBOR.
2022-03-14 11:20:23 -04:00
Itamar Turner-Trauring
106cc708a0
Use a constant.
2022-03-14 11:18:53 -04:00
Itamar Turner-Trauring
722f8e9598
Expand docs.
2022-03-14 11:17:06 -04:00
Itamar Turner-Trauring
b6073b11c2
Refactor to check HTTP content-type of request body.
2022-03-14 11:16:09 -04:00
Itamar Turner-Trauring
fef332754b
Switch to shared utility so server can use it too.
2022-03-14 11:09:40 -04:00
Itamar Turner-Trauring
13fd3b3685
Get rid of Python 2 crud.
2022-03-14 11:01:20 -04:00
Itamar Turner-Trauring
1e108f8445
Don't use a custom parser.
2022-03-14 11:01:09 -04:00
Itamar Turner-Trauring
b8ab3dd6a7
Server handles Accept headers.
2022-03-14 10:53:22 -04:00
Itamar Turner-Trauring
e55c3e8acf
Check for CBOR content-encoding header in client.
2022-03-14 10:35:39 -04:00
Itamar Turner-Trauring
5baf63219d
Always use UTF-8 for corruption reports.
2022-03-10 17:41:28 -05:00
Itamar Turner-Trauring
7e25b43dba
Direct unit tests for advising share is corrupt.
2022-03-10 11:28:48 -05:00
Itamar Turner-Trauring
922ee4feb1
Sketch of advise_corrupt_share support for immutables.
2022-03-10 11:09:45 -05:00
Itamar Turner-Trauring
f736683347
Finish testing and implementing lease renewal.
2022-03-09 13:35:50 -05:00
Itamar Turner-Trauring
aee0f7dc69
Sketch of lease renewal implementation.
2022-03-09 13:10:13 -05:00
Itamar Turner-Trauring
636ab017d4
Disconnection is purely a Foolscap concern.
2022-03-09 12:47:14 -05:00
Itamar Turner-Trauring
e598fbbc85
Get rid of redundant code.
2022-03-09 12:42:24 -05:00
Itamar Turner-Trauring
5d51aac0d3
Clarify.
2022-03-09 12:41:40 -05:00
Itamar Turner-Trauring
edb9eda53b
Clarify.
2022-03-09 12:41:10 -05:00
Itamar Turner-Trauring
ac271cfb3d
Merge remote-tracking branch 'origin/master' into 3877-immutable-storage-apis-continued
2022-03-09 11:23:02 -05:00
Itamar Turner-Trauring
86769c19bf
Finish abort logic and tests.
2022-03-09 11:19:23 -05:00
Itamar Turner-Trauring
ef4f912a68
Less error-prone testing assertion, and fix a testing bug.
2022-03-09 11:11:39 -05:00
Itamar Turner-Trauring
4fc7ef7528
Basic HTTP test for aborts.
2022-03-09 10:57:05 -05:00
Itamar Turner-Trauring
f47741afb1
Correct behavior on timed out immutable uploads.
2022-03-09 10:45:21 -05:00
Itamar Turner-Trauring
92b952a5fe
Authenticate writes!
2022-03-09 10:45:08 -05:00
Itamar Turner-Trauring
c642218173
Sketch of aborting uploads.
2022-03-08 10:41:56 -05:00
Itamar Turner-Trauring
5203873995
Refactor to unify data structure logic.
2022-03-08 10:13:37 -05:00
Itamar Turner-Trauring
5be7cbc171
Merge pull request #1182 from tahoe-lafs/3876-per-bucket-upload-secret
...
Allow per-bucket upload secret
Fixes ticket:3876
2022-03-08 10:10:48 -05:00
Itamar Turner-Trauring
7721c134f2
Change the semantics of HTTP bucket creation so that it's possible to have a
...
different upload secret per upload.
2022-03-07 09:28:21 -05:00
Itamar Turner-Trauring
40e5ab1661
Merge pull request #1178 from tahoe-lafs/3860-http-more-immutables
...
More immutable support for HTTP storage API
Fixes ticket:3860
2022-03-07 09:12:56 -05:00
Itamar Turner-Trauring
87ab56426a
Validate another edge case of bad storage index.
2022-03-07 08:46:05 -05:00
Itamar Turner-Trauring
4efa65d3db
Typo.
2022-03-07 08:29:26 -05:00
Itamar Turner-Trauring
60bcd5fe9f
Address review comments.
2022-03-07 08:25:12 -05:00
Itamar Turner-Trauring
9f4f6668c0
Tweaks.
2022-03-07 08:21:58 -05:00
Itamar Turner-Trauring
7146cff227
Sketch of TLS listening and furl construction for the HTTP storage server.
2022-03-02 10:40:39 -05:00
Itamar Turner-Trauring
32cbc7b9df
Function for getting SPKI hash.
2022-03-02 10:35:41 -05:00
Itamar Turner-Trauring
f81cd6e595
Use an option also available on PyPy3.
2022-02-23 10:57:36 -05:00
meejah
2928a480ff
RSA key-size is not configurable, it's 2048bits
2022-02-16 21:46:24 -07:00
meejah
5cd95920b6
Merge branch 'master' into 3828.key-length.1
2022-02-16 21:18:50 -07:00
Itamar Turner-Trauring
5aa00abc3d
Use the correct API (since direct returns break Python 2 imports)
2022-02-11 15:02:14 -05:00
Itamar Turner-Trauring
abf3048ab3
More passing HTTP IStorageServer tests.
2022-02-10 17:07:21 -05:00
Itamar Turner-Trauring
7466ee25a8
Don't send header if it makes no sense to do so.
2022-02-10 13:57:57 -05:00
Itamar Turner-Trauring
b049d4a792
Fix get_version with new API.
2022-02-10 13:52:47 -05:00
Itamar Turner-Trauring
fa2f142bc9
Another ticket.
2022-02-10 13:50:09 -05:00
Itamar Turner-Trauring
aa68be645f
Return Content-Range in responses.
2022-02-10 13:48:33 -05:00
Itamar Turner-Trauring
416af7328c
Support lack of Range header.
2022-02-10 13:31:09 -05:00
Itamar Turner-Trauring
7db1ddd875
Implement Range header validation.
2022-02-10 13:15:48 -05:00
Itamar Turner-Trauring
5d9e0c9bca
Not found tests and implementation.
2022-02-09 13:14:27 -05:00
Itamar Turner-Trauring
45ee5e3346
Done elsewhere.
2022-02-09 13:08:34 -05:00
Itamar Turner-Trauring
bae5d58ab9
Another test.
2022-02-09 13:07:34 -05:00
Itamar Turner-Trauring
faacde4e32
Conflicting writes.
2022-02-09 12:41:32 -05:00
Itamar Turner-Trauring
8c739343f3
Reduce duplication.
2022-02-09 12:38:32 -05:00
Itamar Turner-Trauring
95d7548629
Upload to non-existent place.
2022-02-09 12:30:38 -05:00
Itamar Turner-Trauring
72bac785ee
Done elsewhere.
2022-02-09 12:27:08 -05:00
Itamar Turner-Trauring
ecb1a3c5a0
Just require content-range for simplicity.
2022-02-09 12:25:47 -05:00
Itamar Turner-Trauring
d38183335e
Handle bad Content-Range headers.
2022-02-08 10:46:55 -05:00
Itamar Turner-Trauring
7107a85fba
Refactor client, separating low-level and high-level concerns.
2022-02-08 10:19:37 -05:00
Itamar Turner-Trauring
ce2468cdff
Validate inputs automatically as part of parsing.
2022-02-04 10:35:38 -05:00
Itamar Turner-Trauring
e6f32e33bc
Merge branch '3871-http-list-storage-index-shares' into 3860-http-more-immutables
2022-02-04 09:30:17 -05:00
Itamar Turner-Trauring
5e3a31166d
Better explanation.
2022-02-04 09:26:58 -05:00
Itamar Turner-Trauring
7454929be0
Less code duplication.
2022-02-04 09:26:25 -05:00
Itamar Turner-Trauring
52322c25d3
Merge remote-tracking branch 'origin/master' into 3871-http-list-storage-index-shares
2022-02-04 09:19:51 -05:00