summaryrefslogtreecommitdiff
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Add `tests/chutney/integration-e2e-shadow`Jim Newsome2024-09-182-0/+102
| | | | | This is a wrapper script for running `tests/chutney/integration-e2e` under shadow.
* chutney test: rework installation and tracking of chutney itselfJim Newsome2024-09-182-1/+23
| | | | | | | | | | | Previously `tests/chutney/setup` would locate *or install* chutney and set `CHUTNEY_PATH` for itself. However that `CHUTNEY_PATH` wasn't propagated to other steps or "up" to the new `integration-e2e` wrapper script. Tracking it in the arti.run along with other dynamic info lets us ensure we consistently use the same chutney across steps, and in the higher level `integration-e2e` script.
* chutney test: add option to skip tests incompatible with shadowJim Newsome2024-09-181-5/+17
|
* chutney: don't hard-code expected IP address for example.comJim Newsome2024-09-181-2/+6
| | | | | | It looks like it changed at some point. Rather than hard-coding, just do the lookup locally and compare the tor-lookup result against that.
* chutney test: move logic from .gitlab-ci.yml to integration-e2eJim Newsome2024-09-181-0/+10
| | | | | | | Having this in a script is a step towards being able to run exactly the same test under shadow without duplicating this high-level logic. It's also convenient for running the ci test locally.
* shadow CI: Disable SOCKS/DNS proxying for the arti onion services.Gabriela Moldovan2024-09-171-0/+6
| | | | This tests that #1569 works.
* shadow: add obfs4 arti client + tor bridgeopara2024-08-2116-1/+82
|
* shadow ci: don't explicitly set storage.keystore.enabledJim Newsome2024-08-061-4/+0
| | | | | | | | Setting it for all arti processes causes a warning to be logged to stderr, which causes the shadow ci script to fail. It's enabled by default anyway when the feature is compiled in, so we don't need to enable it explicitly.
* shadow CI: fail on arti logged errorsJim Newsome2024-08-061-0/+9
|
* shadow ci: fail on nonempty stderr fileJim Newsome2024-08-061-0/+9
| | | | This would have caught #1513 before it was merged.
* shadow test: Add another client for the restricted discovery service.Gabriela Moldovan2024-08-056-0/+75
| | | | | This tests that the client configured in the `authorized_clients` directory of the service is able to connect.
* shadow test: Set the right permissions for authorized_clients.Gabriela Moldovan2024-08-051-0/+1
|
* shadow test: Add a new arti client for connecting to filserver-onion-arti-auth.Gabriela Moldovan2024-08-056-0/+63
| | | | | This will be used with the new `fileserver-onion-arti-auth` test hidden service.
* shadow test: Add fileserver-onion-arti-authGabriela Moldovan2024-08-057-0/+46
| | | | | | | | | This adds a new restricted discovery hidden service (`fpqqmiwzqiv63jczrshh4qcmlxw6gujcai3arobq23wikt7hk7ojadid.onion`) that has 2 authorized clients: * `alice`, the client configured in the `restricted_discovery.static` list in its TOML config * `default`, the client configured in `authorized_clients/default.auth`
* ci: Fix variable not expanding.Gabriela Moldovan2024-06-051-3/+4
|
* ci: Fix shellcheck warnings.Gabriela Moldovan2024-06-051-2/+2
|
* ci: If there are internal errors, log where they were found.Gabriela Moldovan2024-06-051-2/+3
|
* ci: Make the shadow simulation fail if an internal error is logged.Gabriela Moldovan2024-06-041-0/+24
|
* Revert "shadow ci: Increase start_time of the new test."Gabriela Moldovan2024-06-031-2/+2
| | | | | | We don't need this now that #1417 is fixed. This reverts commit a9010f6300c25e4602ecf8017ca176c724ecdfa5.
* shadow ci: Increase start_time of the new test.Gabriela Moldovan2024-06-031-2/+2
| | | | | | | | | | | | | | Without this change, one of the tgen processes doesn't exit as expected: ``` 618990:00:06:50.991981 [4717:shadow-worker] 00:30:00.000000000 [ERROR] [torclient-onion-artiserver:11.0.0.19] [process.rs:1525] [shadow_rs::host::process] process 'torclient-onion-artiserver.tgen.1001' exited with status StoppedByShadow; expected end state was exited: 0 but was running ``` This is because of a stub circuit selection bug that only manifests when the `torclient-onion-artiserver` and `torclient-onion-artiserver-full-vanguards` tests are run at the same time. See #1417 for more details.
* shadow test: Add test for onion svc using full vanguards.Gabriela Moldovan2024-06-039-0/+106
| | | | | | | This adds an onion service that uses full vanguards, and a client that connects to it. Closes #1408
* shadow ci: Put the test hosts in a HOSTS variable.Gabriela Moldovan2024-06-031-2/+9
| | | | | Moving them to a separate variable makes the script more readable as we add more hosts.
* Merge branch 'script-suffixes' into 'main'Ian Jackson2024-05-162-1/+1
|\ | | | | | | | | Forbid script suffixes See merge request tpo/core/arti!2153
| * Rename tests/shadow/run.sh to runIan Jackson2024-05-162-1/+1
| |
* | doc: Use locked buildpinkforest2024-05-162-2/+2
|/
* CI: Don't build arti with experimental features in rust-latest.Gabriela Moldovan2024-03-141-1/+1
| | | | | | | | Some experimental features (i.e. `vanguards`) break the shadow integration tests. Since the examples enable `experimental`, we need `rust-latest` to build arti using `-p arti`, rather than from the workspace level (because cargo does feature unification when building the packages as a workspace).
* tor-hsclient: Remove client nickname from the client key specifiers.Gabriela Moldovan2024-02-221-0/+0
| | | | Closes #1283
* arti, arti-client, tor-keymgr: Remove keystore dir configuration.Gabriela Moldovan2024-02-211-1/+3
| | | | Closes #1202
* tor-hsservice: Rename the service keystore dir to "hss".Gabriela Moldovan2024-02-012-0/+0
| | | | | | | | | | | The onion service keys now live in the `hss/<nickname>` subdirectory within the keystore. This layout change is **not** backwards-compatible, so if you want to use your existing hidden service keys, you will need to manually move them to `<keystore_root>/hss`. Closes #1260
* tor-keymgr: Lowercase the role when building the ArtiPath.Gabriela Moldovan2024-01-313-1/+1
| | | | | | | The role is a slug, and slugs are not allowed to contain uppercase characters. Closes #1195
* tor-keymgr: Strip .onion suffix from HsId before building Slug.Gabriela Moldovan2024-01-311-0/+0
| | | | | | We are about to replace `ArtiPathComponent` with `Slug`, but `Slug`s don't support `.`, so let's strip the `.onion` suffix before encoding it in the `ArtiPath`.
* shadow ci: add instructions for building arti-extraJim Newsome2024-01-161-2/+20
|
* shadow test: Update the test client auth keys.Gabriela Moldovan2023-12-142-7/+6
| | | | | The algorithm name for x25519 keys has changed, so the test keys need to be updated.
* shadow test: Update hidden service keys.Gabriela Moldovan2023-12-143-8/+8
| | | | | The algorithm name for expanded ed25519 keys has changed, so the test keys need to be updated.
* shadow test: remove workaround for #1170Jim Newsome2023-12-131-9/+0
| | | | | | | Disabling the shadow option --model-unblocked-syscall-latency causes this bug not to surface. Better to remove this workaround for now so that we can revisit again if/when it does rather than continue to mask it.
* shadow test: disable --model-unblocked-syscall-latencyJim Newsome2023-12-131-1/+0
| | | | | | | | | This option is mostly a workaround for busy loops and other subtle race conditions. While having it enabled can let us ignore some benign busy loops and timing edge cases, it can also hide real problems; e.g. burning extra CPU in a busy-loop. https://shadow.github.io/docs/guide/limitations.html#busy-loops
* shadow test: add tor client connecting to arti hsJim Newsome2023-12-134-1/+16
|
* shadow test: add client for arti hsJim Newsome2023-12-135-1/+64
| | | | | This also adds a workaround - the arti service doesn't appear to register itself (set up intro points) unless first used as a client.
* shadow test: add hidden service keystore to templateJim Newsome2023-12-132-0/+9
| | | | This is to ensure a stable HS address.
* shadow test: add fileserver-onion-artiJim Newsome2023-12-132-0/+24
|
* shadow ci: use proxy.sock_listen instead of socks_portJim Newsome2023-12-131-5/+5
| | | | socks_port is deprecated
* shadow ci: reformat arti argument lists (no-op)Jim Newsome2023-12-131-5/+33
| | | | | Put one argument per line and use a yaml list instead of string (shadow accepts either here).
* shadow ci: add host articlient-extraJim Newsome2023-12-073-1/+20
| | | | | | | | | | | The arti-extra binary has several experimental features enabled. Currently it is used to test experimental onion service features, but it would be useful also do a test of the arti-extra binary in the same configuration and workload as the arti binary (which has the default featureset). In a follow-up commit, we'll enable the experimental ntor-v3 handshake implementation in the arti-extra binary.
* tor-keymgr: Encode whether the key is public or private in the file extension.Gabriela Moldovan2023-10-131-0/+0
| | | | | | | | | | | | | | There are 2 reasons to make this change: * because having the word `private` in the extension will make it more difficult to accidentally misuse or misplace a private key (see https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1618#note_2947461) * because `Keystore`s will soon grow a `list()` function returning all `(ArtiPath, KeyType)`s in the keystore, and in order for `ArtiNativeKeystore` to implement this function, it will need to be able to reverse the `KeyType -> file extension` mapping (if two different `KeyType`s are mapped to the same extension, `ArtiNativeKeystore`s won't be able to reverse the mapping)
* tor-keymgr: Fix typo in key names.Gabriela Moldovan2023-09-121-0/+0
| | | | The secret keys are prefixed with `KS`, not `KP`.
* tor-keymgr: Remove redundant _private suffix from key extension.Gabriela Moldovan2023-09-121-0/+0
| | | | The privateness of the keys is encoded in their name.
* keymgr: Do not expect x25519 keys to be stored as ed25519 ssh keys.Gabriela Moldovan2023-08-162-6/+6
| | | | | | | | | | | | | | | | | | | | | | Previously, the Arti key store would store x25519 secret keys as ed25519 OpenSSH keys, which it would convert to x25519 upon loading (using the conversion function added in !1297 (merged)). This approach isn't good enough though: most people will probably want to bring their existing x25519 keys, and in order to store those in OpenSSH format, we'd need convert them to ed25519, which is impossible (because the secret part of an x25519 key contains a SHA512'd secret, whereas the corresponding, "un-expanded", ed25519 secret key contains the secret itself rather than the SHA). Now that `ssh-key` has support for ssh keys with [custom algorithm names], we can store x25519 in OpenSSH format directly. This commit changes the storage format used by the keymgr for x25519 client auth keys (from ed25519-ssh to our own custom key type with an algorithm name of `"[email protected]"`). Closes #936 [custom algorithm names]: https://github.com/RustCrypto/SSH/pull/136
* arti-client: Use the config struct from tor-keymgr.Gabriela Moldovan2023-07-131-2/+3
|
* CI: Reduce the success threshold for the HS client integration tests.Gabriela Moldovan2023-07-121-1/+17
| | | | Prompted by https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/1399#note_2921505
* CI: Add client auth integration test.Gabriela Moldovan2023-07-1213-1/+80
|