diff --git a/.github/workflows/startos-iso.yaml b/.github/workflows/startos-iso.yaml index 079f28caa..1ec009dfb 100644 --- a/.github/workflows/startos-iso.yaml +++ b/.github/workflows/startos-iso.yaml @@ -8,7 +8,7 @@ on: type: choice description: Environment options: - - "" + - NONE - dev - unstable - dev-unstable @@ -18,6 +18,16 @@ on: options: - standard - fast + platform: + type: choice + description: Platform + options: + - ALL + - x86_64 + - x86_64-nonfree + - aarch64 + - aarch64-nonfree + - raspberrypi push: branches: - master @@ -29,7 +39,7 @@ on: env: NODEJS_VERSION: "18.15.0" - ENVIRONMENT: '${{ fromJson(format(''["{0}", ""]'', github.event.inputs.environment || ''dev''))[github.event.inputs.environment == ''''] }}' + ENVIRONMENT: '${{ fromJson(format(''["{0}", ""]'', github.event.inputs.environment || ''dev''))[github.event.inputs.environment == ''NONE''] }}' jobs: all: @@ -37,27 +47,41 @@ jobs: strategy: fail-fast: false matrix: - platform: - [x86_64, x86_64-nonfree, aarch64, aarch64-nonfree, raspberrypi] + platform: >- + ${{ + fromJson( + format( + '[ + ["{0}"], + ["x86_64", "x86_64-nonfree", "aarch64", "aarch64-nonfree", "raspberrypi"] + ]', + github.event.inputs.platform || 'ALL' + ) + )[(github.event.inputs.platform || 'ALL') == 'ALL'] + }} runs-on: >- ${{ fromJson( format( '["ubuntu-22.04", "{0}"]', fromJson('{ - "x86_64": "buildjet-32vcpu-ubuntu-2204", - "x86_64-nonfree": "buildjet-32vcpu-ubuntu-2204", - "aarch64": "buildjet-8vcpu-ubuntu-2204-arm", - "aarch64-nonfree": "buildjet-8vcpu-ubuntu-2204-arm", - "raspberrypi": "buildjet-16vcpu-ubuntu-2204-arm", - }')[matrix.platform] + "x86_64": ["buildjet-32vcpu-ubuntu-2204", "buildjet-32vcpu-ubuntu-2204"], + "x86_64-nonfree": ["buildjet-32vcpu-ubuntu-2204", "buildjet-32vcpu-ubuntu-2204"], + "aarch64": ["buildjet-16vcpu-ubuntu-2204-arm", "buildjet-32vcpu-ubuntu-2204-arm"], + "aarch64-nonfree": ["buildjet-16vcpu-ubuntu-2204-arm", "buildjet-32vcpu-ubuntu-2204-arm"], + "raspberrypi": ["buildjet-16vcpu-ubuntu-2204-arm", "buildjet-32vcpu-ubuntu-2204-arm"], + }')[matrix.platform][github.event.inputs.platform == matrix.platform] ) )[github.event.inputs.runner == 'fast'] }} steps: + - name: Free space + run: df -h && rm -rf /opt/hostedtoolcache* && df -h + if: ${{ github.event.inputs.runner != 'fast' }} + - run: | sudo mount -t tmpfs tmpfs . - if: ${{ github.event.inputs.runner == 'fast' && (matrix.platform == 'x86_64' || matrix.platform == 'x86_64-nonfree') }} + if: ${{ github.event.inputs.runner == 'fast' && (matrix.platform == 'x86_64' || matrix.platform == 'x86_64-nonfree' || github.event.inputs.platform == matrix.platform) }} - uses: actions/checkout@v3 with: @@ -72,8 +96,7 @@ jobs: - run: | cp -r debian embassyos-0.3.x/ VERSION=0.3.x ./control.sh - cp embassyos-0.3.x/backend/embassyd.service embassyos-0.3.x/debian/embassyos.embassyd.service - cp embassyos-0.3.x/backend/embassy-init.service embassyos-0.3.x/debian/embassyos.embassy-init.service + cp embassyos-0.3.x/backend/startd.service embassyos-0.3.x/debian/embassyos.startd.service working-directory: embassy-os-deb - uses: actions/setup-node@v3 @@ -84,7 +107,7 @@ jobs: id: npm-cache-dir run: | echo "dir=$(npm config get cache)" >> $GITHUB_OUTPUT - - uses: buildjet/cache@v3 + - uses: actions/cache@v3 id: npm-cache with: path: ${{ steps.npm-cache-dir.outputs.dir }} @@ -134,7 +157,7 @@ jobs: - run: sudo mount -t tmpfs tmpfs /var/tmp/debspawn if: ${{ github.event.inputs.runner == 'fast' && (matrix.platform == 'x86_64' || matrix.platform == 'x86_64-nonfree') }} - - uses: buildjet/cache@v3 + - uses: actions/cache@v3 with: path: /var/lib/debspawn key: ${{ runner.os }}-${{ matrix.platform }}-debspawn-init @@ -143,7 +166,7 @@ jobs: - run: "mv embassy-os-deb/embassyos_0.3.x-1_*.deb startos-image-recipes/overlays/deb/" - - run: "rm -rf embassy-os-deb" + - run: "rm -rf embassy-os-deb ${{ steps.npm-cache-dir.outputs.dir }} $HOME/.cargo" - name: Run iso build working-directory: startos-image-recipes diff --git a/Makefile b/Makefile index 1586ce8d5..127842576 100644 --- a/Makefile +++ b/Makefile @@ -3,20 +3,20 @@ ARCH := $(shell if [ "$(OS_ARCH)" = "raspberrypi" ]; then echo aarch64; else ech ENVIRONMENT_FILE = $(shell ./check-environment.sh) GIT_HASH_FILE = $(shell ./check-git-hash.sh) VERSION_FILE = $(shell ./check-version.sh) -EMBASSY_BINS := backend/target/$(ARCH)-unknown-linux-gnu/release/embassyd backend/target/$(ARCH)-unknown-linux-gnu/release/embassy-init backend/target/$(ARCH)-unknown-linux-gnu/release/embassy-cli backend/target/$(ARCH)-unknown-linux-gnu/release/embassy-sdk backend/target/$(ARCH)-unknown-linux-gnu/release/avahi-alias libs/target/aarch64-unknown-linux-musl/release/embassy_container_init libs/target/x86_64-unknown-linux-musl/release/embassy_container_init -EMBASSY_UIS := frontend/dist/ui frontend/dist/setup-wizard frontend/dist/diagnostic-ui frontend/dist/install-wizard +EMBASSY_BINS := backend/target/$(ARCH)-unknown-linux-gnu/release/startbox libs/target/aarch64-unknown-linux-musl/release/embassy_container_init libs/target/x86_64-unknown-linux-musl/release/embassy_container_init +EMBASSY_UIS := frontend/dist/raw/ui frontend/dist/raw/setup-wizard frontend/dist/raw/diagnostic-ui frontend/dist/raw/install-wizard BUILD_SRC := $(shell find build) -EMBASSY_SRC := backend/embassyd.service backend/embassy-init.service $(EMBASSY_UIS) $(BUILD_SRC) +EMBASSY_SRC := backend/startd.service $(BUILD_SRC) COMPAT_SRC := $(shell find system-images/compat/ -not -path 'system-images/compat/target/*' -and -not -name *.tar -and -not -name target) UTILS_SRC := $(shell find system-images/utils/ -not -name *.tar) BINFMT_SRC := $(shell find system-images/binfmt/ -not -name *.tar) -BACKEND_SRC := $(shell find backend/src) $(shell find backend/migrations) $(shell find patch-db/*/src) $(shell find libs/*/src) libs/*/Cargo.toml backend/Cargo.toml backend/Cargo.lock +BACKEND_SRC := $(shell find backend/src) $(shell find backend/migrations) $(shell find patch-db/*/src) $(shell find libs/*/src) libs/*/Cargo.toml backend/Cargo.toml backend/Cargo.lock frontend/dist/static FRONTEND_SHARED_SRC := $(shell find frontend/projects/shared) $(shell ls -p frontend/ | grep -v / | sed 's/^/frontend\//g') frontend/package.json frontend/node_modules frontend/config.json patch-db/client/dist frontend/patchdb-ui-seed.json FRONTEND_UI_SRC := $(shell find frontend/projects/ui) FRONTEND_SETUP_WIZARD_SRC := $(shell find frontend/projects/setup-wizard) FRONTEND_DIAGNOSTIC_UI_SRC := $(shell find frontend/projects/diagnostic-ui) FRONTEND_INSTALL_WIZARD_SRC := $(shell find frontend/projects/install-wizard) -PATCH_DB_CLIENT_SRC := $(shell find patch-db/client -not -path patch-db/client/dist) +PATCH_DB_CLIENT_SRC := $(shell find patch-db/client -not -path patch-db/client/dist -and -not -path patch-db/client/node_modules) GZIP_BIN := $(shell which pigz || which gzip) ALL_TARGETS := $(EMBASSY_BINS) system-images/compat/docker-images/$(ARCH).tar system-images/utils/docker-images/$(ARCH).tar system-images/binfmt/docker-images/$(ARCH).tar $(EMBASSY_SRC) $(shell if [ "$(OS_ARCH)" = "raspberrypi" ]; then echo cargo-deps/aarch64-unknown-linux-gnu/release/pi-beep; fi) $(ENVIRONMENT_FILE) $(GIT_HASH_FILE) $(VERSION_FILE) @@ -24,9 +24,11 @@ ifeq ($(REMOTE),) mkdir = mkdir -p $1 rm = rm -rf $1 cp = cp -r $1 $2 + ln = ln -sf $1 $2 else mkdir = ssh $(REMOTE) 'mkdir -p $1' rm = ssh $(REMOTE) 'sudo rm -rf $1' + ln = ssh $(REMOTE) 'sudo ln -sf $1 $2' define cp tar --transform "s|^$1|x|" -czv -f- $1 | ssh $(REMOTE) "sudo tar --transform 's|^x|$2|' -xzv -f- -C /" endef @@ -71,10 +73,12 @@ startos_raspberrypi.img: $(BUILD_SRC) startos.raspberrypi.squashfs $(VERSION_FIL # For creating os images. DO NOT USE install: $(ALL_TARGETS) $(call mkdir,$(DESTDIR)/usr/bin) - $(call cp,backend/target/$(ARCH)-unknown-linux-gnu/release/embassy-init,$(DESTDIR)/usr/bin/embassy-init) - $(call cp,backend/target/$(ARCH)-unknown-linux-gnu/release/embassyd,$(DESTDIR)/usr/bin/embassyd) - $(call cp,backend/target/$(ARCH)-unknown-linux-gnu/release/embassy-cli,$(DESTDIR)/usr/bin/embassy-cli) - $(call cp,backend/target/$(ARCH)-unknown-linux-gnu/release/avahi-alias,$(DESTDIR)/usr/bin/avahi-alias) + $(call cp,backend/target/$(ARCH)-unknown-linux-gnu/release/startbox,$(DESTDIR)/usr/bin/startbox) + $(call ln,/usr/bin/startbox,$(DESTDIR)/usr/bin/startd) + $(call ln,/usr/bin/startbox,$(DESTDIR)/usr/bin/start-cli) + $(call ln,/usr/bin/startbox,$(DESTDIR)/usr/bin/start-sdk) + $(call ln,/usr/bin/startbox,$(DESTDIR)/usr/bin/avahi-alias) + $(call ln,/usr/bin/startbox,$(DESTDIR)/usr/bin/embassy-cli) if [ "$(OS_ARCH)" = "raspberrypi" ]; then $(call cp,cargo-deps/aarch64-unknown-linux-gnu/release/pi-beep,$(DESTDIR)/usr/bin/pi-beep); fi $(call mkdir,$(DESTDIR)/usr/lib) @@ -94,22 +98,14 @@ install: $(ALL_TARGETS) $(call cp,system-images/utils/docker-images/$(ARCH).tar,$(DESTDIR)/usr/lib/embassy/system-images/utils.tar) $(call cp,system-images/binfmt/docker-images/$(ARCH).tar,$(DESTDIR)/usr/lib/embassy/system-images/binfmt.tar) - $(call mkdir,$(DESTDIR)/var/www/html) - $(call cp,frontend/dist/diagnostic-ui,$(DESTDIR)/var/www/html/diagnostic) - $(call cp,frontend/dist/setup-wizard,$(DESTDIR)/var/www/html/setup) - $(call cp,frontend/dist/install-wizard,$(DESTDIR)/var/www/html/install) - $(call cp,frontend/dist/ui,$(DESTDIR)/var/www/html/main) - $(call cp,index.html,$(DESTDIR)/var/www/html/index.html) - update-overlay: @echo "\033[33m!!! THIS WILL ONLY REFLASH YOUR DEVICE IN MEMORY !!!\033[0m" @echo "\033[33mALL CHANGES WILL BE REVERTED IF YOU RESTART THE DEVICE\033[0m" @if [ -z "$(REMOTE)" ]; then >&2 echo "Must specify REMOTE" && false; fi - @if [ "`ssh $(REMOTE) 'cat /usr/lib/embassy/VERSION.txt'`" != "`cat ./VERSION.txt`" ]; then >&2 echo "Embassy requires migrations: update-overlay is unavailable." && false; fi - @if ssh $(REMOTE) "pidof embassy-init"; then >&2 echo "Embassy in INIT: update-overlay is unavailable." && false; fi - ssh $(REMOTE) "sudo systemctl stop embassyd" + @if [ "`ssh $(REMOTE) 'cat /usr/lib/embassy/VERSION.txt'`" != "`cat ./VERSION.txt`" ]; then >&2 echo "StartOS requires migrations: update-overlay is unavailable." && false; fi + ssh $(REMOTE) "sudo systemctl stop startd" $(MAKE) install REMOTE=$(REMOTE) OS_ARCH=$(OS_ARCH) - ssh $(REMOTE) "sudo systemctl start embassyd" + ssh $(REMOTE) "sudo systemctl start startd" update: @if [ -z "$(REMOTE)" ]; then >&2 echo "Must specify REMOTE" && false; fi @@ -132,11 +128,6 @@ system-images/utils/docker-images/aarch64.tar system-images/utils/docker-images/ system-images/binfmt/docker-images/aarch64.tar system-images/binfmt/docker-images/x86_64.tar: $(BINFMT_SRC) | sudo cd system-images/binfmt && make -raspios.img: - wget --continue https://downloads.raspberrypi.org/raspios_lite_arm64/images/raspios_lite_arm64-2022-01-28/2022-01-28-raspios-bullseye-arm64-lite.zip - unzip 2022-01-28-raspios-bullseye-arm64-lite.zip - mv 2022-01-28-raspios-bullseye-arm64-lite.img raspios.img - snapshots: libs/snapshot_creator/Cargo.toml cd libs/ && ./build-v8-snapshot.sh cd libs/ && ./build-arm-v8-snapshot.sh @@ -148,18 +139,21 @@ $(EMBASSY_BINS): $(BACKEND_SRC) $(ENVIRONMENT_FILE) $(GIT_HASH_FILE) frontend/pa frontend/node_modules: frontend/package.json npm --prefix frontend ci -frontend/dist/ui: $(FRONTEND_UI_SRC) $(FRONTEND_SHARED_SRC) $(ENVIRONMENT_FILE) +frontend/dist/raw/ui: $(FRONTEND_UI_SRC) $(FRONTEND_SHARED_SRC) $(ENVIRONMENT_FILE) npm --prefix frontend run build:ui -frontend/dist/setup-wizard: $(FRONTEND_SETUP_WIZARD_SRC) $(FRONTEND_SHARED_SRC) $(ENVIRONMENT_FILE) +frontend/dist/raw/setup-wizard: $(FRONTEND_SETUP_WIZARD_SRC) $(FRONTEND_SHARED_SRC) $(ENVIRONMENT_FILE) npm --prefix frontend run build:setup -frontend/dist/diagnostic-ui: $(FRONTEND_DIAGNOSTIC_UI_SRC) $(FRONTEND_SHARED_SRC) $(ENVIRONMENT_FILE) +frontend/dist/raw/diagnostic-ui: $(FRONTEND_DIAGNOSTIC_UI_SRC) $(FRONTEND_SHARED_SRC) $(ENVIRONMENT_FILE) npm --prefix frontend run build:dui -frontend/dist/install-wizard: $(FRONTEND_INSTALL_WIZARD_SRC) $(FRONTEND_SHARED_SRC) $(ENVIRONMENT_FILE) +frontend/dist/raw/install-wizard: $(FRONTEND_INSTALL_WIZARD_SRC) $(FRONTEND_SHARED_SRC) $(ENVIRONMENT_FILE) npm --prefix frontend run build:install-wiz +frontend/dist/static: $(EMBASSY_UIS) + ./compress-uis.sh + frontend/config.json: $(GIT_HASH_FILE) frontend/config-sample.json jq '.useMocks = false' frontend/config-sample.json > frontend/config.json jq '.packageArch = "$(ARCH)"' frontend/config.json > frontend/config.json.tmp @@ -186,13 +180,10 @@ backend-$(ARCH).tar: $(EMBASSY_BINS) frontends: $(EMBASSY_UIS) # this is a convenience step to build the UI -ui: frontend/dist/ui +ui: frontend/dist/raw/ui # used by github actions backend: $(EMBASSY_BINS) -cargo-deps/aarch64-unknown-linux-gnu/release/nc-broadcast: | sudo - ARCH=$(ARCH) ./build-cargo-dep.sh nc-broadcast - cargo-deps/aarch64-unknown-linux-gnu/release/pi-beep: | sudo - ARCH=$(ARCH) ./build-cargo-dep.sh pi-beep + ARCH=aarch64 ./build-cargo-dep.sh pi-beep diff --git a/README.md b/README.md index 503f97eec..5bca6b0b1 100644 --- a/README.md +++ b/README.md @@ -32,6 +32,8 @@ To pursue this option, follow one of our [DIY guides](https://start9.com/latest/ ## :heart: Contributing There are multiple ways to contribute: work directly on StartOS, package a service for the marketplace, or help with documentation and guides. To learn more about contributing, see [here](https://start9.com/contribute/). +To report security issues, please email our security team - security@start9.com. + ## UI Screenshots

StartOS diff --git a/backend/Cargo.lock b/backend/Cargo.lock index 426c47637..82c501f3f 100644 --- a/backend/Cargo.lock +++ b/backend/Cargo.lock @@ -14,9 +14,9 @@ dependencies = [ [[package]] name = "addr2line" -version = "0.19.0" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a76fd60b23679b7d19bd066031410fb7e458ccc5e958eb5c325888ce4baedc97" +checksum = "f4fa78e18c64fce05e902adecd7a5eed15a5e0a3439f7b0e169f0252214865e3" dependencies = [ "gimli", ] @@ -46,16 +46,27 @@ version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" dependencies = [ - "getrandom 0.2.8", + "getrandom 0.2.10", + "once_cell", + "version_check", +] + +[[package]] +name = "ahash" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c99f64d1e06488f620f932677e24bc6e2897582980441ae90a671415bd7ec2f" +dependencies = [ + "cfg-if 1.0.0", "once_cell", "version_check", ] [[package]] name = "aho-corasick" -version = "0.7.20" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" +checksum = "43f6cb1bf222025340178f382c426f13757b2960e89779dfcb319c32542a5a41" dependencies = [ "memchr", ] @@ -75,6 +86,18 @@ dependencies = [ "alloc-no-stdlib", ] +[[package]] +name = "allocator-api2" +version = "0.2.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" + +[[package]] +name = "android-tzdata" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e999941b234f3131b00bc13c22d06e8c5ff726d1b6318ac7eb276997bbb4fef0" + [[package]] name = "android_system_properties" version = "0.1.5" @@ -95,21 +118,21 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.69" +version = "1.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "224afbd727c3d6e4b90103ece64b8d1b67fbb1973b1046c2281eed3f3803f800" +checksum = "3b13c32d80ecc7ab747b80c3784bce54ee8a7a0cc4fbda9bf4cda2cf6fe90854" [[package]] name = "arrayref" -version = "0.3.6" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4c527152e37cf757a3f78aae5a06fbeefdb07ccc535c980a3208ee3060dd544" +checksum = "6b4930d2cb77ce62f89ee5d5289b4ac049559b1c45539271f5ed4fdc7db34545" [[package]] name = "arrayvec" -version = "0.7.2" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8da52d66c7071e2e3fa2a1e5c6d088fec47b593032b254f5e980de8ea54454d6" +checksum = "96d30a06541fbafbc7f82ed10c06164cfbd2c401138f6addd8404629c4b16711" [[package]] name = "ascii-canvas" @@ -122,23 +145,22 @@ dependencies = [ [[package]] name = "ast_node" -version = "0.7.7" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc4c00309ed1c8104732df4a5fa9acc3b796b6f8531dfbd5ce0078c86f997244" +checksum = "c704e2f6ee1a98223f5a7629a6ef0f3decb3b552ed282889dc957edff98ce1e6" dependencies = [ - "darling 0.10.2", "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "swc_macros_common", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] name = "async-channel" -version = "1.8.0" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf46fee83e5ccffc220104713af3292ff9bc7c64c7de289f66dae8e38d826833" +checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35" dependencies = [ "concurrent-queue", "event-listener", @@ -161,34 +183,35 @@ dependencies = [ [[package]] name = "async-stream" -version = "0.3.3" +version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dad5c83079eae9969be7fadefe640a1c566901f05ff91ab221de4b6f68d9507e" +checksum = "cd56dd203fef61ac097dd65721a419ddccb106b2d2b70ba60a6b529f03961a51" dependencies = [ "async-stream-impl", "futures-core", + "pin-project-lite", ] [[package]] name = "async-stream-impl" -version = "0.3.3" +version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10f203db73a71dfa2fb6dd22763990fa26f3d2625a6da2da900d23b87d26be27" +checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] name = "async-trait" -version = "0.1.64" +version = "0.1.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cd7fce9ba8c3c042128ce72d8b2ddbf3a05747efb67ea0313c635e10bda47a2" +checksum = "7b2d0f03b3640e3a630367e40c468cb7f309529c708ed1d88597047b0e7c6ef7" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] @@ -228,9 +251,9 @@ dependencies = [ [[package]] name = "backtrace" -version = "0.3.67" +version = "0.3.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233d376d6d185f2a3093e58f283f60f880315b6c60075b01f36b3b85154564ca" +checksum = "4319208da049c43661739c5fade2ba182f09d1dc2299b32298d3a31692b17e12" dependencies = [ "addr2line", "cc", @@ -253,12 +276,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "23ce669cd6c8588f79e15cf450314f9638f967fc5770ff1c7c1deb0925ea7cfa" -[[package]] -name = "base64" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b41b7ea54a0c9d92199de89e20e58d49f02f8e699814ef3fdf266f6f748d15c7" - [[package]] name = "base64" version = "0.13.1" @@ -267,15 +284,15 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" [[package]] name = "base64" -version = "0.21.0" +version = "0.21.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" +checksum = "604178f6c5c21f02dc555784810edfb88d34ac2c73b2eae109655649ee73ce3d" [[package]] name = "base64ct" -version = "1.5.3" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b645a089122eccb6111b4f81cbc1a49f5900ac4666bb93ac027feaecf15607bf" +checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" [[package]] name = "basic-cookies" @@ -290,9 +307,9 @@ dependencies = [ [[package]] name = "better_scoped_tls" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b73e8ecdec39e98aa3b19e8cd0b8ed8f77ccb86a6b0b2dc7cd86d105438a2123" +checksum = "794edcc9b3fb07bb4aecaa11f093fd45663b4feadb782d68303a2268bc2701de" dependencies = [ "scoped-tls", ] @@ -321,7 +338,7 @@ version = "0.55.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "75b13ce559e6433d360c26305643803cb52cfbabbc2b9c47ce04a58493dfb443" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cexpr", "cfg-if 0.1.10", "clang-sys", @@ -331,8 +348,8 @@ dependencies = [ "lazycell", "log", "peeking_take_while", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "regex", "rustc-hash", "shlex", @@ -360,6 +377,12 @@ version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" +[[package]] +name = "bitflags" +version = "2.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "630be753d4e58660abd17930c71b647fe46c27ea6b63cc59e1e3851406972e42" + [[package]] name = "bitmaps" version = "2.1.0" @@ -395,7 +418,7 @@ checksum = "3c2f0dc9a68c6317d884f97cc36cf5a3d20ba14ce404227df55e1af708ab04bc" dependencies = [ "arrayref", "arrayvec", - "constant_time_eq 0.2.4", + "constant_time_eq 0.2.6", ] [[package]] @@ -410,9 +433,9 @@ dependencies = [ [[package]] name = "block-buffer" -version = "0.10.3" +version = "0.10.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69cce20737498f97b993470a6e536b8523f0af7892a4f928cceb1ac5e52ebe7e" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" dependencies = [ "generic-array", ] @@ -482,29 +505,11 @@ dependencies = [ "alloc-stdlib", ] -[[package]] -name = "bstr" -version = "0.2.17" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba3569f383e8f1598449f1a423e72e99569137b47740b1da11ef19af3d5c3223" -dependencies = [ - "lazy_static", - "memchr", - "regex-automata", - "serde", -] - -[[package]] -name = "build_const" -version = "0.2.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b4ae4235e6dac0694637c763029ecea1a2ec9e4e06ec2729bd21ba4d9c863eb7" - [[package]] name = "bumpalo" -version = "3.12.0" +version = "3.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d261e256854913907f67ed06efbc3338dfe6179796deefc1ff763fc1aee5535" +checksum = "a3e2c3daef883ecc1b5d58c15adae93470a91d425f3532ba1695849656af3fc1" [[package]] name = "byteorder" @@ -530,7 +535,7 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f4aedb84272dbe89af497cf81375129abda4fc0a9e7c5d317498c15cc30c0d27" dependencies = [ - "nom 5.1.2", + "nom 5.1.3", ] [[package]] @@ -547,13 +552,13 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "chrono" -version = "0.4.23" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16b0a3d9ed01224b22057780a37bb8c5dbfe1be8ba48678e7bf57ec4b385411f" +checksum = "ec837a71355b28f6556dbd569b37b3f363091c0bd4b2e735674521b4c5fd9bc5" dependencies = [ + "android-tzdata", "iana-time-zone", "js-sys", - "num-integer", "num-traits", "serde", "time 0.1.45", @@ -562,10 +567,19 @@ dependencies = [ ] [[package]] -name = "ciborium" -version = "0.2.0" +name = "chumsky" +version = "0.9.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b0c137568cc60b904a7724001b35ce2630fd00d5d84805fbb608ab89509d788f" +checksum = "23170228b96236b5a7299057ac284a321457700bc8c41a4476052f0f4ba5349d" +dependencies = [ + "hashbrown 0.12.3", +] + +[[package]] +name = "ciborium" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "effd91f6c78e5a4ace8a5d3c0b6bfaec9e2baaef55f3efc00e45fb2e477ee926" dependencies = [ "ciborium-io", "ciborium-ll", @@ -574,15 +588,15 @@ dependencies = [ [[package]] name = "ciborium-io" -version = "0.2.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "346de753af073cc87b52b2083a506b38ac176a44cfb05497b622e27be899b369" +checksum = "cdf919175532b369853f5d5e20b26b43112613fd6fe7aee757e35f7a44642656" [[package]] name = "ciborium-ll" -version = "0.2.0" +version = "0.2.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "213030a2b5a4e0c0892b6652260cf6ccac84827b83a85a534e178e3906c4cf1b" +checksum = "defaa24ecc093c77630e6c15e17c51f5e187bf35ee514f4e2d67baaa96dae22b" dependencies = [ "ciborium-io", "half", @@ -599,9 +613,9 @@ dependencies = [ [[package]] name = "clang-sys" -version = "1.4.0" +version = "1.6.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fa2e27ae6ab525c3d369ded447057bca5438d86dc3a68f6faafb8269ba82ebf3" +checksum = "c688fc74432808e3eb684cae8830a86be1d66a2bd58e1f248ed0960a590baf6f" dependencies = [ "glob", "libc", @@ -616,7 +630,7 @@ checksum = "a0610544180c38b88101fecf2dd634b174a62eef6946f84dfc6a7127512b381c" dependencies = [ "ansi_term", "atty", - "bitflags", + "bitflags 1.3.2", "strsim 0.8.0", "textwrap 0.11.0", "unicode-width", @@ -625,14 +639,14 @@ dependencies = [ [[package]] name = "clap" -version = "3.2.23" +version = "3.2.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "71655c45cb9845d3270c9d6df84ebe72b4dad3c2ba3f7023ad47c144e4e473a5" +checksum = "4ea181bf566f71cb9a5d17a59e1871af638180a18fb0035c92ae62b705207123" dependencies = [ "atty", - "bitflags", + "bitflags 1.3.2", "clap_lex", - "indexmap", + "indexmap 1.9.3", "strsim 0.10.0", "termcolor", "textwrap 0.16.0", @@ -647,16 +661,6 @@ dependencies = [ "os_str_bytes", ] -[[package]] -name = "codespan-reporting" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" -dependencies = [ - "termcolor", - "unicode-width", -] - [[package]] name = "color-eyre" version = "0.6.2" @@ -686,18 +690,18 @@ dependencies = [ [[package]] name = "concurrent-queue" -version = "2.1.0" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c278839b831783b70278b14df4d45e1beb1aad306c07bb796637de9a0e323e8e" +checksum = "62ec6771ecfa0762d24683ee5a32ad78487a3d3afdc0fb8cae19d2c5deb50b7c" dependencies = [ "crossbeam-utils", ] [[package]] name = "const-oid" -version = "0.9.1" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cec318a675afcb6a1ea1d4340e2d377e56e47c266f28043ceccbf4412ddfdd3b" +checksum = "795bc6e66a8e340f075fcf6227e417a2dc976b92b91f3cdc778bb858778b6747" [[package]] name = "constant_time_eq" @@ -707,9 +711,9 @@ checksum = "245097e9a4535ee1e3e3931fcfcd55a796a44c643e8596ff6566d68f09b87bbc" [[package]] name = "constant_time_eq" -version = "0.2.4" +version = "0.2.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f3ad85c1f65dc7b37604eb0e89748faf0b9653065f2a8ef69f96a687ec1e9279" +checksum = "21a53c0a4d288377e7415b53dcfc3c04da5cdc2cc95c8d5ac178b58f0b861ad6" [[package]] name = "convert_case" @@ -724,39 +728,41 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e859cd57d0710d9e06c381b550c06e76992472a8c6d527aecd2fc673dcc231fb" dependencies = [ "percent-encoding", - "time 0.3.17", + "time 0.3.23", "version_check", ] [[package]] name = "cookie_store" -version = "0.16.1" +version = "0.16.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e4b6aa369f41f5faa04bb80c9b1f4216ea81646ed6124d76ba5c49a7aafd9cd" +checksum = "d606d0fba62e13cf04db20536c05cb7f13673c161cb47a47a82b9b9e7d3f1daa" dependencies = [ "cookie", "idna 0.2.3", "log", "publicsuffix", "serde", + "serde_derive", "serde_json", - "time 0.3.17", + "time 0.3.23", "url", ] [[package]] name = "cookie_store" -version = "0.19.0" +version = "0.19.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bca9b3c618262fc0c85ecbc814c144e04be9c6eec08b315e7cd1cfbe0bb6ca84" +checksum = "d5a18f35792056f8c7c2de9c002e7e4fe44c7b5f66e7d99f46468dbb730a7ea7" dependencies = [ "cookie", "idna 0.3.0", "log", "publicsuffix", "serde", + "serde_derive", "serde_json", - "time 0.3.17", + "time 0.3.23", "url", ] @@ -772,28 +778,19 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dc" +checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" [[package]] name = "cpufeatures" -version = "0.2.5" +version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28d997bd5e24a5928dd43e46dc529867e207907fe0b239c3477d924f7f2ca320" +checksum = "a17b76ff3a4162b0b27f354a0c87015ddad39d35f9c0c36607a3bdd175dde1f1" dependencies = [ "libc", ] -[[package]] -name = "crc" -version = "1.8.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d663548de7f5cca343f1e0a48d14dcfb0e9eb4e079ec58883b7251539fa10aeb" -dependencies = [ - "build_const", -] - [[package]] name = "crc" version = "3.0.1" @@ -830,9 +827,9 @@ dependencies = [ [[package]] name = "crossbeam-utils" -version = "0.8.14" +version = "0.8.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb766fa798726286dbbb842f174001dab8abc7b627a1dd86e0b7222a95d929f" +checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" dependencies = [ "cfg-if 1.0.0", ] @@ -877,13 +874,12 @@ dependencies = [ [[package]] name = "csv" -version = "1.1.6" +version = "1.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22813a6dc45b335f9bade10bf7271dc477e81113e89eb251a0bc2a8a81c536e1" +checksum = "626ae34994d3d8d668f4269922248239db4ae42d538b14c398b74a52208e8086" dependencies = [ - "bstr", "csv-core", - "itoa 0.4.8", + "itoa", "ryu", "serde", ] @@ -925,60 +921,6 @@ dependencies = [ "zeroize", ] -[[package]] -name = "cxx" -version = "1.0.90" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90d59d9acd2a682b4e40605a242f6670eaa58c5957471cbf85e8aa6a0b97a5e8" -dependencies = [ - "cc", - "cxxbridge-flags", - "cxxbridge-macro", - "link-cplusplus", -] - -[[package]] -name = "cxx-build" -version = "1.0.90" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebfa40bda659dd5c864e65f4c9a2b0aff19bea56b017b9b77c73d3766a453a38" -dependencies = [ - "cc", - "codespan-reporting", - "once_cell", - "proc-macro2 1.0.51", - "quote 1.0.23", - "scratch", - "syn 1.0.107", -] - -[[package]] -name = "cxxbridge-flags" -version = "1.0.90" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "457ce6757c5c70dc6ecdbda6925b958aae7f959bda7d8fb9bde889e34a09dc03" - -[[package]] -name = "cxxbridge-macro" -version = "1.0.90" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ebf883b7aacd7b2aeb2a7b338648ee19f57c140d4ee8e52c68979c6b2f7f2263" -dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", -] - -[[package]] -name = "darling" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d706e75d87e35569db781a9b5e2416cff1236a47ed380831f959382ccd5f858" -dependencies = [ - "darling_core 0.10.2", - "darling_macro 0.10.2", -] - [[package]] name = "darling" version = "0.13.4" @@ -991,26 +933,12 @@ dependencies = [ [[package]] name = "darling" -version = "0.14.3" +version = "0.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c0808e1bd8671fb44a113a14e13497557533369847788fa2ae912b6ebfce9fa8" +checksum = "0209d94da627ab5605dcccf08bb18afa5009cfbef48d8a8b7d7bdbc79be25c5e" dependencies = [ - "darling_core 0.14.3", - "darling_macro 0.14.3", -] - -[[package]] -name = "darling_core" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0c960ae2da4de88a91b2d920c2a7233b400bc33cb28453a2987822d8392519b" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2 1.0.51", - "quote 1.0.23", - "strsim 0.9.3", - "syn 1.0.107", + "darling_core 0.20.3", + "darling_macro 0.20.3", ] [[package]] @@ -1021,35 +949,24 @@ checksum = "859d65a907b6852c9361e3185c862aae7fafd2887876799fa55f5f99dc40d610" dependencies = [ "fnv", "ident_case", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "strsim 0.10.0", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] name = "darling_core" -version = "0.14.3" +version = "0.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "001d80444f28e193f30c2f293455da62dcf9a6b29918a4253152ae2b1de592cb" +checksum = "177e3443818124b357d8e76f53be906d60937f0d3a90773a664fa63fa253e621" dependencies = [ "fnv", "ident_case", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "strsim 0.10.0", - "syn 1.0.107", -] - -[[package]] -name = "darling_macro" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b5a2f4ac4969822c62224815d069952656cadc7084fdca9751e6d959189b72" -dependencies = [ - "darling_core 0.10.2", - "quote 1.0.23", - "syn 1.0.107", + "syn 2.0.18", ] [[package]] @@ -1059,84 +976,116 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" dependencies = [ "darling_core 0.13.4", - "quote 1.0.23", - "syn 1.0.107", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] name = "darling_macro" -version = "0.14.3" +version = "0.20.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b36230598a2d5de7ec1c6f51f72d8a99a9208daff41de2084d06e3fd3ea56685" +checksum = "836a9bbc7ad63342d6d6e7b815ccab164bc77a2d95d84bc3117a8c0d5c98e2d5" dependencies = [ - "darling_core 0.14.3", - "quote 1.0.23", - "syn 1.0.107", + "darling_core 0.20.3", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] name = "dashmap" -version = "5.4.0" +version = "5.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907076dfda823b0b36d2a1bb5f90c96660a5bbcd7729e10727f07858f22c4edc" +checksum = "6943ae99c34386c84a470c499d3414f66502a41340aa895406e0d2e4a207b91d" dependencies = [ "cfg-if 1.0.0", - "hashbrown", + "hashbrown 0.14.0", "lock_api", "once_cell", - "parking_lot_core 0.9.7", + "parking_lot_core 0.9.8", ] [[package]] name = "data-encoding" -version = "2.3.3" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23d8666cb01533c39dde32bcbab8e227b4ed6679b2c925eba05feabea39508fb" +checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" [[package]] name = "data-url" -version = "0.1.1" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a30bfce702bcfa94e906ef82421f2c0e61c076ad76030c16ee5d2e9a32fe193" +checksum = "8d7439c3735f405729d52c3fbbe4de140eaf938a1fe47d227c27f8254d4302a5" + +[[package]] +name = "deno-proc-macro-rules" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c65c2ffdafc1564565200967edc4851c7b55422d3913466688907efd05ea26f" dependencies = [ - "matches", + "deno-proc-macro-rules-macros", + "proc-macro2 1.0.66", + "syn 2.0.18", ] [[package]] -name = "debug_unreachable" -version = "0.1.1" +name = "deno-proc-macro-rules-macros" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a032eac705ca39214d169f83e3d3da290af06d8d1d344d1baad2fd002dca4b3" +checksum = "3047b312b7451e3190865713a4dd6e1f821aed614ada219766ebc3024a690435" dependencies = [ - "unreachable", + "once_cell", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] name = "deno_ast" -version = "0.15.0" +version = "0.27.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2989afff97ba7da10f186e9a45e946b4ef943b9d4babd2ee7b4b24cc9906b69" +checksum = "a39dc5554b1c835c62914b545f8b378563a997521e39a8f03450b37b216143ef" dependencies = [ "anyhow", "base64 0.13.1", - "data-url", + "deno_media_type", "dprint-swc-ext", "serde", - "swc_ecmascript", + "swc_atoms", + "swc_common", + "swc_config", + "swc_config_macro", + "swc_ecma_ast", + "swc_ecma_codegen", + "swc_ecma_codegen_macros", + "swc_ecma_loader", + "swc_ecma_parser", + "swc_ecma_transforms_base", + "swc_ecma_transforms_classes", + "swc_ecma_transforms_macros", + "swc_ecma_transforms_proposal", + "swc_ecma_transforms_react", + "swc_ecma_transforms_typescript", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_eq_ignore_macros", + "swc_macros_common", + "swc_visit", + "swc_visit_macros", "text_lines", "url", ] [[package]] name = "deno_core" -version = "0.136.0" +version = "0.195.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07ced67ffe84c64aee6e84e40558835752b6f12807f84d15da8f5954e2b670c5" +checksum = "408e433386de30dd501cf82d26ca1fb4cd84b055536f8f6f9c78c3380649d94b" dependencies = [ "anyhow", + "bytes", "deno_ops", "futures", - "indexmap", + "indexmap 1.9.3", "libc", "log", "once_cell", @@ -1145,21 +1094,44 @@ dependencies = [ "serde", "serde_json", "serde_v8", + "smallvec", "sourcemap", + "tokio", "url", "v8", ] [[package]] -name = "deno_ops" -version = "0.14.0" +name = "deno_media_type" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05520711837dd592d2861319ea3cf2dfd81e39bb92e41758ee9172f3623daebd" +checksum = "63772a60d740a41d97fbffb4788fc3779e6df47289e01892c12be38f4a5beded" dependencies = [ + "data-url", + "serde", + "url", +] + +[[package]] +name = "deno_ops" +version = "0.73.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6d06feb9b26ccd2997f35610517d5a8f1dd423e21364509523f72474601f87f" +dependencies = [ + "deno-proc-macro-rules", + "lazy-regex", + "once_cell", + "pmutil", "proc-macro-crate", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "regex", + "strum", + "strum_macros", + "syn 1.0.109", + "syn 2.0.18", + "thiserror", + "v8", ] [[package]] @@ -1180,10 +1152,10 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4fb810d30a7c1953f91334de7244731fc3f3c10d7fe163338a35b9f640960321" dependencies = [ "convert_case", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "rustc_version 0.4.0", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] @@ -1203,11 +1175,11 @@ dependencies = [ [[package]] name = "digest" -version = "0.10.6" +version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ - "block-buffer 0.10.3", + "block-buffer 0.10.4", "const-oid", "crypto-common", "subtle", @@ -1262,25 +1234,32 @@ checksum = "69dde51e8fef5e12c1d65e0929b03d66e4c0c18282bc30ed2ca050ad6f44dd82" [[package]] name = "dotenvy" -version = "0.15.6" +version = "0.15.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03d8c417d7a8cb362e0c37e5d815f5eb7c37f79ff93707329d5a194e42e54ca0" +checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b" [[package]] name = "dprint-swc-ext" -version = "0.1.1" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3df529037ff02f1c43ae8c6cce54d9ad85546ff89cb5c1988f56130c16e16a48" +checksum = "dd4dda8a1b920e8be367aeaad035753d21bb69b3c50515afb41ab1eefbb886b5" dependencies = [ "bumpalo", "num-bigint", "rustc-hash", "swc_atoms", "swc_common", - "swc_ecmascript", + "swc_ecma_ast", + "swc_ecma_parser", "text_lines", ] +[[package]] +name = "dyn-clone" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "304e6508efa593091e97a9abbc10f90aa7ca635b6d2784feff3c89d41dd12272" + [[package]] name = "ecdsa" version = "0.14.8" @@ -1349,7 +1328,7 @@ dependencies = [ "base16ct", "crypto-bigint", "der", - "digest 0.10.6", + "digest 0.10.7", "ff", "generic-array", "group", @@ -1361,116 +1340,6 @@ dependencies = [ "zeroize", ] -[[package]] -name = "embassy-os" -version = "0.3.4-rev.3" -dependencies = [ - "aes", - "async-compression", - "async-stream", - "async-trait", - "avahi-sys", - "base32", - "base64 0.13.1", - "base64ct", - "basic-cookies", - "bimap", - "bollard", - "bytes", - "chrono", - "ciborium", - "clap 3.2.23", - "color-eyre", - "cookie", - "cookie_store 0.19.0", - "current_platform", - "digest 0.10.6", - "digest 0.9.0", - "divrem", - "ed25519", - "ed25519-dalek", - "embassy_container_init", - "emver", - "fd-lock-rs", - "futures", - "git-version", - "gpt", - "helpers", - "hex", - "hmac 0.12.1", - "http", - "hyper", - "hyper-ws-listener", - "id-pool", - "imbl 2.0.0", - "indexmap", - "ipnet", - "iprange", - "isocountry", - "itertools 0.10.5", - "josekit", - "js_engine", - "jsonpath_lib", - "lazy_static", - "libc", - "log", - "mbrman", - "models", - "nix 0.25.1", - "nom 7.1.3", - "num", - "num_enum", - "openssh-keys", - "openssl", - "p256 0.12.0", - "patch-db", - "pbkdf2", - "pin-project", - "pkcs8", - "prettytable-rs", - "proptest", - "proptest-derive", - "rand 0.7.3", - "rand 0.8.5", - "regex", - "reqwest", - "reqwest_cookie_store", - "rpassword", - "rpc-toolkit", - "rust-argon2", - "scopeguard", - "serde", - "serde_json", - "serde_with 2.2.0", - "serde_yaml", - "sha2 0.10.6", - "sha2 0.9.9", - "simple-logging", - "sqlx", - "ssh-key", - "stderrlog", - "tar", - "thiserror", - "tokio", - "tokio-rustls", - "tokio-socks", - "tokio-stream", - "tokio-tar", - "tokio-tungstenite", - "tokio-util", - "toml", - "torut", - "tracing", - "tracing-error 0.2.0", - "tracing-futures", - "tracing-subscriber 0.3.16", - "trust-dns-server", - "typed-builder", - "url", - "uuid 1.3.0", - "zeroize", -] - [[package]] name = "embassy_container_init" version = "0.1.0" @@ -1489,7 +1358,7 @@ dependencies = [ "tracing", "tracing-error 0.2.0", "tracing-futures", - "tracing-subscriber 0.3.16", + "tracing-subscriber 0.3.17", "yajrc 0.1.0 (git+https://github.com/dr-bonez/yajrc.git?branch=develop)", ] @@ -1506,9 +1375,9 @@ dependencies = [ [[package]] name = "ena" -version = "0.14.0" +version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d7402b94a93c24e742487327a7cd839dc9d36fec9de9fb25b09f2dae459f36c3" +checksum = "c533630cf40e9caa44bd91aadc88a75d75a4c3a12b4cfde353cbed41daa1e1f1" dependencies = [ "log", ] @@ -1541,21 +1410,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c9720bba047d567ffc8a3cba48bf19126600e249ab7f128e9233e6376976a116" dependencies = [ "heck 0.4.1", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", -] - -[[package]] -name = "enum_kind" -version = "0.2.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b940da354ae81ef0926c5eaa428207b8f4f091d3956c891dfbd124162bed99" -dependencies = [ - "pmutil", - "proc-macro2 1.0.51", - "swc_macros_common", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] @@ -1585,14 +1442,20 @@ dependencies = [ ] [[package]] -name = "errno" -version = "0.2.8" +name = "equivalent" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f639046355ee4f37944e44f60642c6f3a7efa3cf6b78c78a0d989a8ce6c396a1" +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" + +[[package]] +name = "errno" +version = "0.3.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4bcfec3a70f97c962c307b2d2c56e358cf1d00b558d74262b5f929ee8cc7e73a" dependencies = [ "errno-dragonfly", "libc", - "winapi", + "windows-sys 0.48.0", ] [[package]] @@ -1623,9 +1486,9 @@ dependencies = [ [[package]] name = "fastrand" -version = "1.8.0" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a407cfaa3385c4ae6b23e84623d48c2798d06e3e6a1878f7f59f17b3f86499" +checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" dependencies = [ "instant", ] @@ -1651,14 +1514,14 @@ dependencies = [ [[package]] name = "filetime" -version = "0.2.20" +version = "0.2.21" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8a3de6e8d11b22ff9edc6d916f890800597d60f8b2da1caf2955c274638d6412" +checksum = "5cbc844cecaee9d4443931972e1289c8ff485cb4cc2767cb03ca139ed6885153" dependencies = [ "cfg-if 1.0.0", "libc", "redox_syscall 0.2.16", - "windows-sys 0.45.0", + "windows-sys 0.48.0", ] [[package]] @@ -1669,9 +1532,9 @@ checksum = "0ce7134b9999ecaf8bcd65542e436736ef32ddca1b3e06094cb6ec5755203b80" [[package]] name = "flate2" -version = "1.0.25" +version = "1.0.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" +checksum = "3b9429470923de8e8cbd4d2dc513535400b4b3fef0319fb5c4e1f520a7bef743" dependencies = [ "crc32fast", "miniz_oxide", @@ -1700,9 +1563,9 @@ checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" [[package]] name = "form_urlencoded" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" +checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" dependencies = [ "percent-encoding", ] @@ -1718,14 +1581,14 @@ dependencies = [ [[package]] name = "from_variant" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0981e470d2ab9f643df3921d54f1952ea100c39fdb6a3fdc820e20d2291df6c" +checksum = "1d449976075322384507443937df2f1d5577afbf4282f12a5a66ef29fa3e6307" dependencies = [ "pmutil", - "proc-macro2 1.0.51", + "proc-macro2 1.0.66", "swc_macros_common", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] @@ -1746,9 +1609,9 @@ checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" [[package]] name = "futures" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "13e2792b0ff0340399d58445b88fd9770e3489eff258a4cbc1523418f12abf84" +checksum = "23342abe12aba583913b2e62f22225ff9c950774065e4bfb61a19cd9770fec40" dependencies = [ "futures-channel", "futures-core", @@ -1761,9 +1624,9 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e5317663a9089767a1ec00a487df42e0ca174b61b4483213ac24448e4664df5" +checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" dependencies = [ "futures-core", "futures-sink", @@ -1771,15 +1634,15 @@ dependencies = [ [[package]] name = "futures-core" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ec90ff4d0fe1f57d600049061dc6bb68ed03c7d2fbd697274c41805dcb3f8608" +checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" [[package]] name = "futures-executor" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e8de0a35a6ab97ec8869e32a2473f4b1324459e14c29275d14b10cb1fd19b50e" +checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" dependencies = [ "futures-core", "futures-task", @@ -1799,38 +1662,38 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bfb8371b6fb2aeb2d280374607aeabfc99d95c72edfe51692e42d3d7f0d08531" +checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" [[package]] name = "futures-macro" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95a73af87da33b5acf53acfebdc339fe592ecf5357ac7c0a7734ab9d8c876a70" +checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] name = "futures-sink" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f310820bb3e8cfd46c80db4d7fb8353e15dfff853a127158425f31e0be6c8364" +checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" [[package]] name = "futures-task" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcf79a1bf610b10f42aea489289c5a2c478a786509693b80cd39c44ccd936366" +checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" [[package]] name = "futures-util" -version = "0.3.26" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9c1d6de3acfef38d2be4b1f543f553131788603495be83da675e180c8d6b7bd1" +checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" dependencies = [ "futures-channel", "futures-core", @@ -1846,9 +1709,9 @@ dependencies = [ [[package]] name = "generic-array" -version = "0.14.6" +version = "0.14.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bff49e947297f3312447abdca79f45f4738097cc82b06e72054d2223f601f1b9" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" dependencies = [ "typenum", "version_check", @@ -1867,9 +1730,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.8" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c05aeb6a22b8f62540c194aac980f2115af067bfe15a0734d7277a768d396b31" +checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" dependencies = [ "cfg-if 1.0.0", "libc", @@ -1878,9 +1741,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.27.1" +version = "0.27.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "221996f774192f0f718773def8201c4ae31f02616a54ccfc2d358bb0e5cefdec" +checksum = "b6c80984affa11d98d1b88b66ac8853f143217b399d3c74116778ff8fdb4ed2e" [[package]] name = "git-version" @@ -1899,9 +1762,9 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fe69f1cbdb6e28af2bac214e943b99ce8a0a06b447d15d3e61161b0423139f3f" dependencies = [ "proc-macro-hack", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] @@ -1912,14 +1775,14 @@ checksum = "d2fabcfbdc87f4758337ca535fb41a6d701b65693ce38287d856d1674551ec9b" [[package]] name = "gpt" -version = "3.0.0" +version = "3.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5dd7365d734a70ac5dd7be791b0c96083852188df015b8c665bb2dadb108a743" +checksum = "8283e7331b8c93b9756e0cfdbcfb90312852f953c6faf9bf741e684cc3b6ad69" dependencies = [ - "bitflags", - "crc 1.8.1", + "bitflags 2.3.3", + "crc", "log", - "uuid 0.8.2", + "uuid", ] [[package]] @@ -1935,9 +1798,9 @@ dependencies = [ [[package]] name = "h2" -version = "0.3.15" +version = "0.3.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f9f29bc9dda355256b2916cf526ab02ce0aeaaaf2bad60d65ef3f12f11dd0f4" +checksum = "97ec8491ebaf99c8eaa73058b045fe58073cd6be7f596ac993ced0b0a0c01049" dependencies = [ "bytes", "fnv", @@ -1945,7 +1808,7 @@ dependencies = [ "futures-sink", "futures-util", "http", - "indexmap", + "indexmap 1.9.3", "slab", "tokio", "tokio-util", @@ -1964,16 +1827,26 @@ version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" dependencies = [ - "ahash", + "ahash 0.7.6", +] + +[[package]] +name = "hashbrown" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c6201b9ff9fd90a5a3bac2e56a830d0caa509576f0e503818ee82c181b3437a" +dependencies = [ + "ahash 0.8.3", + "allocator-api2", ] [[package]] name = "hashlink" -version = "0.8.1" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69fe1fcf8b4278d860ad0548329f892a3631fb63f82574df68275f34cdbe0ffa" +checksum = "312f66718a2d7789ffef4f4b7b213138ed9f1eb3aa1d0d82fc99f88fb3ffd26f" dependencies = [ - "hashbrown", + "hashbrown 0.14.0", ] [[package]] @@ -2023,18 +1896,9 @@ dependencies = [ [[package]] name = "hermit-abi" -version = "0.2.6" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] - -[[package]] -name = "hermit-abi" -version = "0.3.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fed44880c466736ef9a5c5b5facefb5ed0785676d0c02d612db14e54f0d84286" +checksum = "443144c8cdadd93ebf52ddb4056d257f5b52c04d3c804e657d19eb73fc33668b" [[package]] name = "hex" @@ -2042,6 +1906,12 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +[[package]] +name = "hifijson" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85ef6b41c333e6dd2a4aaa59125a19b633cd17e7aaf372b2260809777bcdef4a" + [[package]] name = "hkdf" version = "0.12.3" @@ -2067,18 +1937,18 @@ version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", ] [[package]] name = "http" -version = "0.2.8" +version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75f43d41e26995c17e71ee126451dd3941010b0514a81a9d11f3b341debc2399" +checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" dependencies = [ "bytes", "fnv", - "itoa 1.0.5", + "itoa", ] [[package]] @@ -2110,7 +1980,7 @@ version = "1.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "df004cfca50ef23c36850aaaa59ad52cc70d0e90243c3c7737a4dd32dc7a3c4f" dependencies = [ - "quick-error 1.2.3", + "quick-error", ] [[package]] @@ -2121,9 +1991,9 @@ checksum = "9a3a5bfb195931eeb336b2a7b4d761daec841b97f947d34394601737a7bba5e4" [[package]] name = "hyper" -version = "0.14.24" +version = "0.14.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5e011372fa0b68db8350aa7a248930ecc7839bf46d8485577d69f117a75f164c" +checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" dependencies = [ "bytes", "futures-channel", @@ -2134,7 +2004,7 @@ dependencies = [ "http-body", "httparse", "httpdate", - "itoa 1.0.5", + "itoa", "pin-project-lite", "socket2", "tokio", @@ -2188,26 +2058,25 @@ dependencies = [ [[package]] name = "iana-time-zone" -version = "0.1.53" +version = "0.1.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64c122667b287044802d6ce17ee2ddf13207ed924c712de9a66a5814d5b64765" +checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" dependencies = [ "android_system_properties", "core-foundation-sys", "iana-time-zone-haiku", "js-sys", "wasm-bindgen", - "winapi", + "windows", ] [[package]] name = "iana-time-zone-haiku" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0703ae284fc167426161c2e3f1da3ea71d94b21bedbcc9494e92b28e334e3dca" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" dependencies = [ - "cxx", - "cxx-build", + "cc", ] [[package]] @@ -2246,6 +2115,16 @@ dependencies = [ "unicode-normalization", ] +[[package]] +name = "idna" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" +dependencies = [ + "unicode-bidi", + "unicode-normalization", +] + [[package]] name = "if_chain" version = "1.0.2" @@ -2288,6 +2167,25 @@ dependencies = [ "bitmaps 3.2.0", ] +[[package]] +name = "include_dir" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "18762faeff7122e89e0857b02f7ce6fcc0d101d5e9ad2ad7846cc01d61b7f19e" +dependencies = [ + "include_dir_macros", +] + +[[package]] +name = "include_dir_macros" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f" +dependencies = [ + "proc-macro2 1.0.66", + "quote 1.0.31", +] + [[package]] name = "indenter" version = "0.3.3" @@ -2296,15 +2194,25 @@ checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" [[package]] name = "indexmap" -version = "1.9.2" +version = "1.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399" +checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" dependencies = [ "autocfg", - "hashbrown", + "hashbrown 0.12.3", "serde", ] +[[package]] +name = "indexmap" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5477fe2230a79769d8dc68e0eabf5437907c0457a5614a9e8dddb67f65eb65d" +dependencies = [ + "equivalent", + "hashbrown 0.14.0", +] + [[package]] name = "instant" version = "0.1.12" @@ -2316,13 +2224,13 @@ dependencies = [ [[package]] name = "internment" -version = "0.7.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a798d7677f07d6f1e77be484ea8626ddb1566194de399f1206306820c406371" +checksum = "161079c3ad892faa215fcfcf3fd7a6a3c9288df2b06a2c2bad7fbfad4f01d69d" dependencies = [ - "ahash", + "ahash 0.7.6", "dashmap", - "hashbrown", + "hashbrown 0.12.3", "once_cell", "parking_lot 0.12.1", "serde", @@ -2330,19 +2238,20 @@ dependencies = [ [[package]] name = "io-lifetimes" -version = "1.0.5" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1abeb7a0dd0f8181267ff8adc397075586500b81b28a73e8a0208b00fc170fb3" +checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" dependencies = [ + "hermit-abi 0.3.2", "libc", - "windows-sys 0.45.0", + "windows-sys 0.48.0", ] [[package]] name = "ipnet" -version = "2.7.1" +version = "2.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30e22bd8629359895450b59ea7a776c850561b96a3b1d31321c1949d9e6c9146" +checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" dependencies = [ "serde", ] @@ -2359,27 +2268,26 @@ dependencies = [ [[package]] name = "is-macro" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c068d4c6b922cd6284c609cfa6dec0e41615c9c5a1a4ba729a970d8daba05fb" +checksum = "8a7d079e129b77477a49c5c4f1cfe9ce6c2c909ef52520693e8e811a714c7b20" dependencies = [ "Inflector", "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] name = "is-terminal" -version = "0.4.3" +version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "22e18b0a45d56fe973d6db23972bf5bc46f988a4a2385deac9cc29572f09daef" +checksum = "cb0889898416213fab133e1d33a0e5858a48177452750691bde3666d0fdbaf8b" dependencies = [ - "hermit-abi 0.3.1", - "io-lifetimes", - "rustix", - "windows-sys 0.45.0", + "hermit-abi 0.3.2", + "rustix 0.38.4", + "windows-sys 0.48.0", ] [[package]] @@ -2412,24 +2320,56 @@ dependencies = [ [[package]] name = "itoa" -version = "0.4.8" +version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b71991ff56294aa922b450139ee08b3bfc70982c6b2c7562771375cf73542dd4" +checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" [[package]] -name = "itoa" -version = "1.0.5" +name = "jaq-core" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fad582f4b9e86b6caa621cabeb0963332d92eea04729ab12892c2533951e6440" +checksum = "3ab6f495d0fe97460255aef70fbd77d3b5a7701930163ad69c963b9c6d5d5726" +dependencies = [ + "ahash 0.7.6", + "dyn-clone", + "hifijson", + "indexmap 1.9.3", + "itertools 0.10.5", + "jaq-parse", + "log", + "once_cell", + "regex", + "serde_json", +] + +[[package]] +name = "jaq-parse" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f0f97f01eb9e87af3cbcc843b0dfe693fc6b0a2b9093dc8980dd9fc682826b0" +dependencies = [ + "chumsky", + "serde", +] + +[[package]] +name = "jaq-std" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b261109851c8687bc55eab26e6d81e96f3fdab367e2d3d5706947c218ddaf22" +dependencies = [ + "bincode", + "jaq-parse", +] [[package]] name = "josekit" -version = "0.8.2" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9ef871a7a5f162afa718c416e9cbdd54241a58c922e07870e898ebad2425d8d8" +checksum = "33a96c4f2128a6f44ecf7c36df2b03dddf5a07b060a4d5ebc0a81e9821f7c60e" dependencies = [ "anyhow", - "base64 0.13.1", + "base64 0.21.2", "flate2", "once_cell", "openssl", @@ -2437,14 +2377,14 @@ dependencies = [ "serde", "serde_json", "thiserror", - "time 0.3.17", + "time 0.3.23", ] [[package]] name = "js-sys" -version = "0.3.61" +version = "0.3.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "445dde2150c55e483f3d8416706b97ec8e8237c307e5b7b4b8dd15e6af2a0730" +checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" dependencies = [ "wasm-bindgen", ] @@ -2457,38 +2397,16 @@ dependencies = [ "dashmap", "deno_ast", "deno_core", - "dprint-swc-ext", "embassy_container_init", "helpers", "itertools 0.10.5", + "lazy_static", "models", "pin-project", "reqwest", "serde", "serde_json", - "sha2 0.10.6", - "swc_atoms", - "swc_common", - "swc_config", - "swc_config_macro", - "swc_ecma_ast", - "swc_ecma_codegen", - "swc_ecma_codegen_macros", - "swc_ecma_parser", - "swc_ecma_transforms", - "swc_ecma_transforms_base", - "swc_ecma_transforms_classes", - "swc_ecma_transforms_macros", - "swc_ecma_transforms_proposal", - "swc_ecma_transforms_react", - "swc_ecma_transforms_typescript", - "swc_ecma_utils", - "swc_ecma_visit", - "swc_ecmascript", - "swc_eq_ignore_macros", - "swc_macros_common", - "swc_visit", - "swc_visit_macros", + "sha2 0.10.7", "tokio", "tracing", ] @@ -2525,30 +2443,29 @@ dependencies = [ [[package]] name = "keccak" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3afef3b6eff9ce9d8ff9b3601125eec7f0c8cbac7abd14f355d053fa56c98768" +checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" dependencies = [ "cpufeatures", ] [[package]] name = "lalrpop" -version = "0.19.8" +version = "0.19.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b30455341b0e18f276fa64540aff54deafb54c589de6aca68659c63dd2d5d823" +checksum = "0a1cbf952127589f2851ab2046af368fd20645491bb4b376f04b7f94d7a9837b" dependencies = [ "ascii-canvas", - "atty", "bit-set", "diff", "ena", + "is-terminal", "itertools 0.10.5", "lalrpop-util", "petgraph", - "pico-args", "regex", - "regex-syntax", + "regex-syntax 0.6.29", "string_cache", "term", "tiny-keccak", @@ -2557,13 +2474,36 @@ dependencies = [ [[package]] name = "lalrpop-util" -version = "0.19.8" +version = "0.19.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcf796c978e9b4d983414f4caedc9273aa33ee214c5b887bd55fde84c85d2dc4" +checksum = "d3c48237b9604c5a4702de6b824e02006c3214327564636aef27c1028a8fa0ed" dependencies = [ "regex", ] +[[package]] +name = "lazy-regex" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff63c423c68ea6814b7da9e88ce585f793c87ddd9e78f646970891769c8235d4" +dependencies = [ + "lazy-regex-proc_macros", + "once_cell", + "regex", +] + +[[package]] +name = "lazy-regex-proc_macros" +version = "2.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8edfc11b8f56ce85e207e62ea21557cfa09bb24a8f6b04ae181b086ff8611c22" +dependencies = [ + "proc-macro2 1.0.66", + "quote 1.0.31", + "regex", + "syn 1.0.109", +] + [[package]] name = "lazy_async_pool" version = "0.3.3" @@ -2664,9 +2604,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.139" +version = "0.2.147" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "201de327520df007757c1f0adce6e827fe8562fbc28bfd9c15571c66ca1f5f79" +checksum = "b4668fb0ea861c1df094127ac5f1da3409a82116a4ba74fca2e58ef927159bb3" [[package]] name = "libloading" @@ -2680,18 +2620,9 @@ dependencies = [ [[package]] name = "libm" -version = "0.2.6" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "348108ab3fba42ec82ff6e9564fc4ca0247bdccdc68dd8af9764bbc79c3c8ffb" - -[[package]] -name = "link-cplusplus" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecd207c9c713c34f95a097a5b029ac2ce6010530c7b49d7fea24d977dede04f5" -dependencies = [ - "cc", -] +checksum = "f7012b1bbb0719e1097c47611d3898568c546d597c2e74d66f6087edd5233ff4" [[package]] name = "linux-raw-sys" @@ -2700,10 +2631,22 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" [[package]] -name = "lock_api" -version = "0.4.9" +name = "linux-raw-sys" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" +checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" + +[[package]] +name = "linux-raw-sys" +version = "0.4.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "09fc20d2ca12cb9f044c93e3bd6d32d523e6e2ec3db4f7b2939cd99026ecd3f0" + +[[package]] +name = "lock_api" +version = "0.4.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" dependencies = [ "autocfg", "scopeguard", @@ -2711,12 +2654,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.17" +version = "0.4.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if 1.0.0", -] +checksum = "b06a4cde4c0f271a446782e3eff8de789548ce57dbc8eca9292c27f4a42004b4" [[package]] name = "matchers" @@ -2724,7 +2664,7 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" dependencies = [ - "regex-automata", + "regex-automata 0.1.10", ] [[package]] @@ -2735,9 +2675,9 @@ checksum = "2532096657941c2fea9c289d370a250971c689d4f143798ff67113ec042024a5" [[package]] name = "mbrman" -version = "0.5.1" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4b239f4755d00466e3ac1d55ddeaf77a66c7580352fc6cbc40d56c218fc94a9" +checksum = "9c487024623ae38584610237dd1be8932bb2b324474b23c37a25f9fbe6bf5e9e" dependencies = [ "bincode", "bitvec", @@ -2763,7 +2703,7 @@ version = "0.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6365506850d44bff6e2fbcb5176cf63650e48bd45ef2fe2665ae1570e0f4b9ca" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -2783,9 +2723,9 @@ dependencies = [ [[package]] name = "mime" -version = "0.3.16" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a60c7ce501c71e03a9c9c0d35b861413ae925bd979cc7a4e30d060069aaac8d" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" [[package]] name = "minimal-lexical" @@ -2795,23 +2735,22 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.6.2" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" +checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" dependencies = [ "adler", ] [[package]] name = "mio" -version = "0.8.5" +version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5d732bc30207a6423068df043e3d02e0735b155ad7ce1a6f76fe2baa5b158de" +checksum = "927a765cd3fc26206e66b296465fa9d3e5ab003e651c1b3c060e7956d96b19d2" dependencies = [ "libc", - "log", "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys 0.42.0", + "windows-sys 0.48.0", ] [[package]] @@ -2865,6 +2804,16 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" +[[package]] +name = "new_mime_guess" +version = "4.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2d684d1b59e0dc07b37e2203ef576987473288f530082512aff850585c61b1f" +dependencies = [ + "mime", + "unicase", +] + [[package]] name = "nibble_vec" version = "0.1.0" @@ -2880,7 +2829,7 @@ version = "0.23.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8f3790c00a0150112de0f4cd161e3d7fc4b2d8a5542ffc35f099a2562aecb35c" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cc", "cfg-if 1.0.0", "libc", @@ -2893,7 +2842,7 @@ version = "0.24.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fa52e972a9a719cecb6864fb88568781eb706bac2cd1d4f04a648542dbf78069" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cfg-if 1.0.0", "libc", "memoffset", @@ -2906,7 +2855,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f346ff70e7dbfd675fe90590b92d59ef2de15a8779ae305ebcbfd3f0caf59be4" dependencies = [ "autocfg", - "bitflags", + "bitflags 1.3.2", "cfg-if 1.0.0", "libc", "memoffset", @@ -2915,9 +2864,9 @@ dependencies = [ [[package]] name = "nom" -version = "5.1.2" +version = "5.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffb4262d26ed83a1c0a33a38fe2bb15797329c85770da05e6b828ddb782627af" +checksum = "08959a387a676302eebf4ddbcbc611da04285579f76f88ee0506c63b1a61dd4b" dependencies = [ "memchr", "version_check", @@ -2933,15 +2882,6 @@ dependencies = [ "minimal-lexical", ] -[[package]] -name = "nom8" -version = "0.2.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae01545c9c7fc4486ab7debaf2aad7003ac19431791868fb2e8066df97fad2f8" -dependencies = [ - "memchr", -] - [[package]] name = "nu-ansi-term" version = "0.46.0" @@ -2954,9 +2894,9 @@ dependencies = [ [[package]] name = "num" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "43db66d1170d347f9a065114077f7dccb00c1b9478c89384490a3425279a4606" +checksum = "b05180d69e3da0e530ba2a1dae5110317e49e3b7f3d41be227dc5f92e49ee7af" dependencies = [ "num-bigint", "num-complex", @@ -2975,14 +2915,15 @@ dependencies = [ "autocfg", "num-integer", "num-traits", + "rand 0.8.5", "serde", ] [[package]] name = "num-bigint-dig" -version = "0.8.2" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2399c9463abc5f909349d8aa9ba080e0b88b3ce2885389b60b993f39b1a56905" +checksum = "dc84195820f291c7697304f3cbdadd1cb7199c0efc917ff5eafd71225c136151" dependencies = [ "byteorder", "lazy_static", @@ -3049,49 +2990,49 @@ dependencies = [ [[package]] name = "num_cpus" -version = "1.15.0" +version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" dependencies = [ - "hermit-abi 0.2.6", + "hermit-abi 0.3.2", "libc", ] [[package]] name = "num_enum" -version = "0.5.9" +version = "0.5.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8d829733185c1ca374f17e52b762f24f535ec625d2cc1f070e34c8a9068f341b" +checksum = "1f646caf906c20226733ed5b1374287eb97e3c2a5c227ce668c1f2ce20ae57c9" dependencies = [ "num_enum_derive", ] [[package]] name = "num_enum_derive" -version = "0.5.9" +version = "0.5.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2be1598bf1c313dcdd12092e3f1920f463462525a21b7b4e11b4168353d0123e" +checksum = "dcbff9bc912032c62bf65ef1d5aea88983b420f4f839db1e9b0c281a25c9c799" dependencies = [ "proc-macro-crate", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] name = "object" -version = "0.30.3" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ea86265d3d3dcb6a27fc51bd29a4bf387fae9d2986b823079d4986af253eb439" +checksum = "8bda667d9f2b5051b8833f59f3bf748b28ef54f850f4fcb389a252aa383866d1" dependencies = [ "memchr", ] [[package]] name = "once_cell" -version = "1.17.0" +version = "1.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f61fba1741ea2b3d6a1e3178721804bb716a68a6aeba1149b5d52e3d464ea66" +checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" [[package]] name = "opaque-debug" @@ -3114,11 +3055,11 @@ dependencies = [ [[package]] name = "openssl" -version = "0.10.45" +version = "0.10.55" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b102428fd03bc5edf97f62620f7298614c45cedf287c271e7ed450bbaf83f2e1" +checksum = "345df152bc43501c5eb9e4654ff05f794effb78d4efe3d53abc158baddc0703d" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cfg-if 1.0.0", "foreign-types", "libc", @@ -3129,13 +3070,13 @@ dependencies = [ [[package]] name = "openssl-macros" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b501e44f11665960c7e7fcf062c7d96a14ade4aa98116c004b2e37b5be7d736c" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] @@ -3146,20 +3087,19 @@ checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" [[package]] name = "openssl-src" -version = "111.25.0+1.1.1t" +version = "111.26.0+1.1.1u" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3173cd3626c43e3854b1b727422a276e568d9ec5fe8cec197822cf52cfb743d6" +checksum = "efc62c9f12b22b8f5208c23a7200a442b2e5999f8bdf80233852122b5a4f6f37" dependencies = [ "cc", ] [[package]] name = "openssl-sys" -version = "0.9.80" +version = "0.9.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23bbbf7854cd45b83958ebe919f0e8e516793727652e27fda10a8384cfc790b7" +checksum = "374533b0e45f3a7ced10fcaeccca020e66656bc03dac384f852e4e5a7a8104a6" dependencies = [ - "autocfg", "cc", "libc", "openssl-src", @@ -3169,9 +3109,9 @@ dependencies = [ [[package]] name = "os_str_bytes" -version = "6.4.1" +version = "6.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b7820b9daea5457c9f21c69448905d723fbd21136ccf521748f23fd49e723ee" +checksum = "4d5d9eb14b174ee9aa2ef96dc2b94637a2d4b6e7cb873c7e171f0c20c6cf3eac" [[package]] name = "overload" @@ -3193,7 +3133,7 @@ checksum = "51f44edd08f51e2ade572f141051021c5af22677e42b7dd28a88155151c33594" dependencies = [ "ecdsa 0.14.8", "elliptic-curve", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -3205,7 +3145,7 @@ dependencies = [ "ecdsa 0.15.1", "elliptic-curve", "primeorder", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -3216,7 +3156,7 @@ checksum = "dfc8c5bf642dde52bb9e87c0ecd8ca5a76faac2eeed98dedb7c717997e1080aa" dependencies = [ "ecdsa 0.14.8", "elliptic-curve", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -3237,7 +3177,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" dependencies = [ "lock_api", - "parking_lot_core 0.9.7", + "parking_lot_core 0.9.8", ] [[package]] @@ -3256,15 +3196,15 @@ dependencies = [ [[package]] name = "parking_lot_core" -version = "0.9.7" +version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9069cbb9f99e3a5083476ccb29ceb1de18b9118cafa53e90c9551235de2b9521" +checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" dependencies = [ "cfg-if 1.0.0", "libc", - "redox_syscall 0.2.16", + "redox_syscall 0.3.5", "smallvec", - "windows-sys 0.45.0", + "windows-targets 0.48.1", ] [[package]] @@ -3280,9 +3220,9 @@ dependencies = [ [[package]] name = "paste" -version = "1.0.11" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d01a5bd0424d00070b0098dd17ebca6f961a959dead1dbcbbbc1d1cd8d3deeba" +checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" [[package]] name = "patch-db" @@ -3311,8 +3251,8 @@ name = "patch-db-macro" version = "0.1.0" dependencies = [ "patch-db-macro-internals", - "proc-macro2 1.0.51", - "syn 1.0.107", + "proc-macro2 1.0.66", + "syn 1.0.109", ] [[package]] @@ -3320,21 +3260,27 @@ name = "patch-db-macro-internals" version = "0.1.0" dependencies = [ "heck 0.3.3", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] +[[package]] +name = "pathdiff" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" + [[package]] name = "pbkdf2" version = "0.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "83a0692ec44e4cf1ef28ca317f14f8f07da2d95ec3fa01f86e4467b725e60917" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", "hmac 0.12.1", "password-hash", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -3354,9 +3300,9 @@ dependencies = [ [[package]] name = "percent-encoding" -version = "2.2.0" +version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" +checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" [[package]] name = "petgraph" @@ -3365,7 +3311,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "4dd7d28ee937e54fe3080c91faa1c3a46c06de6252988a7f4592ba2310ef22a4" dependencies = [ "fixedbitset", - "indexmap", + "indexmap 1.9.3", ] [[package]] @@ -3398,9 +3344,9 @@ dependencies = [ "phf_generator", "phf_shared", "proc-macro-hack", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] @@ -3412,37 +3358,31 @@ dependencies = [ "siphasher", ] -[[package]] -name = "pico-args" -version = "0.4.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "db8bcd96cb740d03149cbad5518db9fd87126a10ab519c011893b1754134c468" - [[package]] name = "pin-project" -version = "1.0.12" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad29a609b6bcd67fee905812e544992d216af9d755757c05ed2d0e15a74c6ecc" +checksum = "030ad2bc4db10a8944cb0d837f158bdfec4d4a4873ab701a95046770d11f8842" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.0.12" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "069bdb1e05adc7a8990dce9cc75370895fbe4e3d58b9b73bf1aee56359344a55" +checksum = "ec2e072ecce94ec471b13398d5402c188e76ac03cf74dd1a975161b23a3f6d9c" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] name = "pin-project-lite" -version = "0.2.9" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" +checksum = "4c40d25201921e5ff0c862a505c6557ea88568a4e3ace775ab55e93f2f4f9d57" [[package]] name = "pin-utils" @@ -3474,9 +3414,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.26" +version = "0.3.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" +checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" [[package]] name = "pmutil" @@ -3484,9 +3424,9 @@ version = "0.5.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3894e5d549cccbe44afecf72922f277f603cd4bb0219c8342631ef18fffbe004" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] @@ -3526,9 +3466,9 @@ dependencies = [ [[package]] name = "proc-macro-crate" -version = "1.3.0" +version = "1.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "66618389e4ec1c7afe67d51a9bf34ff9236480f8d51e7489b7d5ab0303c13f34" +checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" dependencies = [ "once_cell", "toml_edit", @@ -3551,9 +3491,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.51" +version = "1.0.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d727cae5b39d21da60fa540906919ad737832fe0b1c165da3a34d6548c849d6" +checksum = "18fb31db3f9bddb2ea821cde30a9f70117e3f119938b5ee630b7403aa6e2ead9" dependencies = [ "unicode-ident", ] @@ -3564,31 +3504,30 @@ version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b1de8dacb0873f77e6aefc6d71e044761fcc68060290f5b1089fcdf84626bb69" dependencies = [ - "bitflags", + "bitflags 1.3.2", "byteorder", "chrono", "flate2", "hex", "lazy_static", - "rustix", + "rustix 0.36.15", ] [[package]] name = "proptest" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "29f1b898011ce9595050a68e60f90bad083ff2987a695a42357134c8381fba70" +checksum = "4e35c06b98bf36aba164cc17cb25f7e232f5c4aeea73baa14b8a9f0d92dbfa65" dependencies = [ "bit-set", - "bitflags", + "bitflags 1.3.2", "byteorder", "lazy_static", "num-traits", - "quick-error 2.0.1", "rand 0.8.5", "rand_chacha 0.3.1", "rand_xorshift", - "regex-syntax", + "regex-syntax 0.6.29", "rusty-fork", "tempfile", "unarray", @@ -3611,6 +3550,15 @@ version = "2.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "33cb294fe86a74cbcf50d4445b37da762029549ebeea341421c7c70370f86cac" +[[package]] +name = "psm" +version = "0.1.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5787f7cda34e3033a72192c018bc5883100330f362ef279a8cbccfce8bb4e874" +dependencies = [ + "cc", +] + [[package]] name = "publicsuffix" version = "2.2.3" @@ -3627,12 +3575,6 @@ version = "1.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a1d01941d82fa2ab50be1e79e6714289dd7cde78eba4c074bc5a4374f650dfe0" -[[package]] -name = "quick-error" -version = "2.0.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a993555f31e5a609f617c12db6250dedcac1b0a85076912c436e6fc9b2c8e6a3" - [[package]] name = "quote" version = "0.6.13" @@ -3644,11 +3586,11 @@ dependencies = [ [[package]] name = "quote" -version = "1.0.23" +version = "1.0.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8856d8364d252a14d474036ea1358d63c9e6965c8e5c1885c18f73d70bff9c7b" +checksum = "5fe8a65d69dd0808184ebb5f836ab526bb259db23c657efa38711b1072ee47f0" dependencies = [ - "proc-macro2 1.0.51", + "proc-macro2 1.0.66", ] [[package]] @@ -3726,7 +3668,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.8", + "getrandom 0.2.10", ] [[package]] @@ -3768,7 +3710,16 @@ version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" dependencies = [ - "bitflags", + "bitflags 1.3.2", +] + +[[package]] +name = "redox_syscall" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" +dependencies = [ + "bitflags 1.3.2", ] [[package]] @@ -3777,20 +3728,21 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" dependencies = [ - "getrandom 0.2.8", + "getrandom 0.2.10", "redox_syscall 0.2.16", "thiserror", ] [[package]] name = "regex" -version = "1.7.1" +version = "1.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48aaa5748ba571fb95cd2c85c09f629215d3a6ece942baa100950af03a34f733" +checksum = "b2eae68fc220f7cf2532e4494aded17545fce192d59cd996e0fe7887f4ceb575" dependencies = [ "aho-corasick", "memchr", - "regex-syntax", + "regex-automata 0.3.3", + "regex-syntax 0.7.4", ] [[package]] @@ -3799,34 +3751,42 @@ version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" dependencies = [ - "regex-syntax", + "regex-syntax 0.6.29", +] + +[[package]] +name = "regex-automata" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "39354c10dd07468c2e73926b23bb9c2caca74c5501e38a35da70406f1d923310" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax 0.7.4", ] [[package]] name = "regex-syntax" -version = "0.6.28" +version = "0.6.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "456c603be3e8d448b072f410900c09faf164fbce2d480456f50eea6e25f9c848" +checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] -name = "remove_dir_all" -version = "0.5.3" +name = "regex-syntax" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7" -dependencies = [ - "winapi", -] +checksum = "e5ea92a5b6195c6ef2a0295ea818b312502c6fc94dde986c5553242e18fd4ce2" [[package]] name = "reqwest" -version = "0.11.14" +version = "0.11.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21eed90ec8570952d53b772ecf8f206aa1ec9a3d76b2521c56c42973f2d91ee9" +checksum = "cde824a14b7c14f85caff81225f411faacc04a2013f41670f41443742b1c1c55" dependencies = [ - "base64 0.21.0", + "base64 0.21.2", "bytes", "cookie", - "cookie_store 0.16.1", + "cookie_store 0.16.2", "encoding_rs", "futures-core", "futures-util", @@ -3867,7 +3827,7 @@ checksum = "06b407c05de7a0f7e4cc2a56af5e9bd6468e509124e81078ce1f8bc2ed3536bf" dependencies = [ "bytes", "cookie", - "cookie_store 0.19.0", + "cookie_store 0.19.1", "reqwest", "url", ] @@ -3915,7 +3875,7 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "5353673ffd8265292281141560d2b851e4da49e83e2f5e255fd473736d45ee10" dependencies = [ - "clap 3.2.23", + "clap 3.2.25", "futures", "hyper", "lazy_static", @@ -3937,9 +3897,9 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f8e4b9cb00baf2d61bcd35e98d67dcb760382a3b4540df7e63b38d053c8a7b8b" dependencies = [ - "proc-macro2 1.0.51", + "proc-macro2 1.0.66", "rpc-toolkit-macro-internals", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] @@ -3948,9 +3908,9 @@ version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3e2ce21b936feaecdab9c9a8e75b9dca64374ccc11951a58045ad6559b75f42" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] @@ -3960,7 +3920,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "094052d5470cbcef561cb848a7209968c9f12dfa6d668f4bca048ac5de51099c" dependencies = [ "byteorder", - "digest 0.10.6", + "digest 0.10.7", "num-bigint-dig", "num-integer", "num-iter", @@ -3998,9 +3958,9 @@ dependencies = [ [[package]] name = "rustc-demangle" -version = "0.1.21" +version = "0.1.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ef03e0a2b150c7a90d01faf6254c9c48a41e95fb2a8c2ac1c6f0d2b9aefc342" +checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" [[package]] name = "rustc-hash" @@ -4023,23 +3983,50 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" dependencies = [ - "semver 1.0.16", + "semver 1.0.18", ] [[package]] name = "rustix" -version = "0.36.8" +version = "0.36.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f43abb88211988493c1abb44a70efa56ff0ce98f233b7b276146f1f3f7ba9644" +checksum = "c37f1bd5ef1b5422177b7646cba67430579cfe2ace80f284fee876bca52ad941" dependencies = [ - "bitflags", + "bitflags 1.3.2", "errno", "io-lifetimes", "libc", - "linux-raw-sys", + "linux-raw-sys 0.1.4", "windows-sys 0.45.0", ] +[[package]] +name = "rustix" +version = "0.37.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d69718bf81c6127a49dc64e44a742e8bb9213c0ff8869a22c308f84c1d4ab06" +dependencies = [ + "bitflags 1.3.2", + "errno", + "io-lifetimes", + "libc", + "linux-raw-sys 0.3.8", + "windows-sys 0.48.0", +] + +[[package]] +name = "rustix" +version = "0.38.4" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0a962918ea88d644592894bc6dc55acc6c0956488adcebbfb6e273506b7fd6e5" +dependencies = [ + "bitflags 2.3.3", + "errno", + "libc", + "linux-raw-sys 0.4.3", + "windows-sys 0.48.0", +] + [[package]] name = "rustls" version = "0.20.8" @@ -4054,18 +4041,18 @@ dependencies = [ [[package]] name = "rustls-pemfile" -version = "1.0.2" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d194b56d58803a43635bdc398cd17e383d6f71f9182b9a192c127ca42494a59b" +checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" dependencies = [ - "base64 0.21.0", + "base64 0.21.2", ] [[package]] name = "rustversion" -version = "1.0.11" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5583e89e108996506031660fe09baa5011b9dd0341b89029313006d1fb508d70" +checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" [[package]] name = "rusty-fork" @@ -4074,24 +4061,24 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "cb3dcc6e454c328bb824492db107ab7c0ae8fcffe4ad210136ef014458c1bc4f" dependencies = [ "fnv", - "quick-error 1.2.3", + "quick-error", "tempfile", "wait-timeout", ] [[package]] name = "ryu" -version = "1.0.12" +version = "1.0.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b4b9743ed687d4b4bcedf9ff5eaa7398495ae14e61cba0a295704edbc7decde" +checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" [[package]] name = "schannel" -version = "0.1.21" +version = "0.1.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "713cfb06c7059f3588fb8044c0fad1d09e3c01d225e25b9220dbfdcf16dbb1b3" +checksum = "0c3733bf4cf7ea0880754e19cb5a462007c4a8c1914bff372ccc95b464f1df88" dependencies = [ - "windows-sys 0.42.0", + "windows-sys 0.48.0", ] [[package]] @@ -4102,15 +4089,9 @@ checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" [[package]] name = "scopeguard" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "scratch" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddccb15bcce173023b3fedd9436f882a0739b8dfb45e4f6b6002bee5929f61b2" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" [[package]] name = "sct" @@ -4138,11 +4119,11 @@ dependencies = [ [[package]] name = "security-framework" -version = "2.8.2" +version = "2.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a332be01508d814fed64bf28f798a146d73792121129962fdf335bb3c49a4254" +checksum = "1fc758eb7bffce5b308734e9b0c1468893cae9ff70ebf13e7090be8dcbcc83a8" dependencies = [ - "bitflags", + "bitflags 1.3.2", "core-foundation", "core-foundation-sys", "libc", @@ -4151,9 +4132,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.8.0" +version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31c9bb296072e961fcbd8853511dd39c2d8be2deb1e17c6860b1d30732b323b4" +checksum = "f51d0c0d83bec45f16480d0ce0058397a69e48fcdc52d1dc8855fb68acbd31a7" dependencies = [ "core-foundation-sys", "libc", @@ -4170,9 +4151,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.16" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58bc9567378fc7690d6b2addae4e60ac2eeea07becb2c64b9f218b53865cba2a" +checksum = "b0293b4b29daaf487284529cc2f5675b8e57c61f70167ba415a463651fd6a918" [[package]] name = "semver-parser" @@ -4182,9 +4163,9 @@ checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" [[package]] name = "serde" -version = "1.0.152" +version = "1.0.164" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb7d1f0d3021d347a83e556fc4683dea2ea09d87bccdf88ff5c12545d89d5efb" +checksum = "9e8c8cf938e98f769bc164923b06dce91cea1751522f46f8466461af04c9027d" dependencies = [ "serde_derive", ] @@ -4200,9 +4181,9 @@ dependencies = [ [[package]] name = "serde_bytes" -version = "0.11.9" +version = "0.11.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "416bda436f9aab92e02c8e10d49a15ddd339cea90b6e340fe51ed97abb548294" +checksum = "f3c5113243e4a3a1c96587342d067f3e6b0f50790b6cf40d2868eb647a3eef0e" dependencies = [ "serde", ] @@ -4227,23 +4208,23 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.152" +version = "1.0.164" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af487d118eecd09402d70a5d72551860e788df87b464af30e5ea6a38c75c541e" +checksum = "d9735b638ccc51c28bf6914d90a2e9725b377144fc612c49a611fddd1b631d68" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] name = "serde_json" -version = "1.0.93" +version = "1.0.99" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cad406b69c91885b5107daf2c29572f6c8cdb3c66826821e286c533490c0bc76" +checksum = "46266871c240a00b8f503b877622fe33430b3c7d963bdc0f2adc511e54a1eae3" dependencies = [ - "indexmap", - "itoa 1.0.5", + "indexmap 2.0.0", + "itoa", "ryu", "serde", ] @@ -4255,20 +4236,24 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d3491c14715ca2294c4d6a88f15e84739788c1d030eed8c110436aafdaa2f3fd" dependencies = [ "form_urlencoded", - "itoa 1.0.5", + "itoa", "ryu", "serde", ] [[package]] name = "serde_v8" -version = "0.47.0" +version = "0.106.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ca1daa2506c9d62744fff84d3534192f2e1c70cdf3bed95f298d89156c00b06" +checksum = "1506733ba5b864018c44320fa3bb11dbb4bf01b62dd09eda007be73034371c51" dependencies = [ "bytes", "derive_more", + "num-bigint", "serde", + "serde_bytes", + "smallvec", + "thiserror", "v8", ] @@ -4284,18 +4269,18 @@ dependencies = [ [[package]] name = "serde_with" -version = "2.2.0" +version = "2.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30d904179146de381af4c93d3af6ca4984b3152db687dacb9c3c35e86f39809c" +checksum = "07ff71d2c147a7b57362cead5e22f772cd52f6ab31cfcd9edcd7f6aeb2a0afbe" dependencies = [ "base64 0.13.1", "chrono", "hex", - "indexmap", + "indexmap 1.9.3", "serde", "serde_json", - "serde_with_macros 2.2.0", - "time 0.3.17", + "serde_with_macros 2.3.3", + "time 0.3.23", ] [[package]] @@ -4305,31 +4290,31 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" dependencies = [ "darling 0.13.4", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] name = "serde_with_macros" -version = "2.2.0" +version = "2.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a1966009f3c05f095697c537312f5415d1e3ed31ce0a56942bac4c771c5c335e" +checksum = "881b6f881b17d13214e5d494c939ebab463d01264ce1811e9d4ac3a882e7695f" dependencies = [ - "darling 0.14.3", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "darling 0.20.3", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] name = "serde_yaml" -version = "0.9.17" +version = "0.9.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8fb06d4b6cdaef0e0c51fa881acb721bed3c924cfaa71d9c94a3b771dfdf6567" +checksum = "da6075b41c7e3b079e5f246eb6094a44850d3a4c25a67c581c80796c80134012" dependencies = [ - "indexmap", - "itoa 1.0.5", + "indexmap 2.0.0", + "itoa", "ryu", "serde", "unsafe-libyaml", @@ -4337,13 +4322,13 @@ dependencies = [ [[package]] name = "sha-1" -version = "0.10.1" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5058ada175748e33390e40e872bd0fe59a19f265d0158daa551c5a88a76009c" +checksum = "028f48d513f9678cda28f6e4064755b3fbb2af6acd672f2c209b62323f7aea0f" dependencies = [ "cfg-if 1.0.0", "cpufeatures", - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -4354,7 +4339,7 @@ checksum = "f04293dc80c3993519f2d7f6f511707ee7094fe0c6d3406feb330cdb3540eba3" dependencies = [ "cfg-if 1.0.0", "cpufeatures", - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -4372,13 +4357,13 @@ dependencies = [ [[package]] name = "sha2" -version = "0.10.6" +version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" +checksum = "479fb9d862239e610720565ca91403019f2f00410f1864c5aa7479b950a76ed8" dependencies = [ "cfg-if 1.0.0", "cpufeatures", - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -4423,7 +4408,7 @@ version = "1.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", "rand_core 0.6.4", ] @@ -4433,7 +4418,7 @@ version = "2.0.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8fe458c98333f9c8152221191a77e2a44e8325d0193484af2e9421a53019e57d" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", "rand_core 0.6.4", ] @@ -4466,24 +4451,35 @@ dependencies = [ [[package]] name = "slab" -version = "0.4.7" +version = "0.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4614a76b2a8be0058caa9dbbaf66d988527d86d003c11a94fbd335d7661edcef" +checksum = "6528351c9bc8ab22353f9d776db39a20288e8d6c37ef8cfe3317cf875eecfc2d" dependencies = [ "autocfg", ] [[package]] name = "smallvec" -version = "1.10.0" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" +checksum = "62bb4feee49fdd9f707ef802e22365a35de4b7b299de4763d44bfea899442ff9" + +[[package]] +name = "smartstring" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fb72c633efbaa2dd666986505016c32c3044395ceaf881518399d2f4127ee29" +dependencies = [ + "autocfg", + "static_assertions", + "version_check", +] [[package]] name = "socket2" -version = "0.4.7" +version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02e2d2db9033d13a1567121ddd7a095ee144db4e1ca1b1bda3419bc0da294ebd" +checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" dependencies = [ "libc", "winapi", @@ -4491,17 +4487,16 @@ dependencies = [ [[package]] name = "sourcemap" -version = "6.0.1" +version = "6.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e031f2463ecbdd5f34c950f89f5c1e1032f22c0f8e3dc4bdb2e8b6658cf61eb" +checksum = "eed16231c92d0a6f0388f56e0ab2be24ecff1173f8e22f0ea5e074d0525631cb" dependencies = [ - "base64 0.11.0", + "data-encoding", "if_chain", - "lazy_static", - "regex", "rustc_version 0.2.3", "serde", "serde_json", + "unicode-id", "url", ] @@ -4534,9 +4529,9 @@ dependencies = [ [[package]] name = "sqlx" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9249290c05928352f71c077cc44a464d880c63f26f7534728cca008e135c0428" +checksum = "f8de3b03a925878ed54a954f621e64bf55a3c1bd29652d0d1a17830405350188" dependencies = [ "sqlx-core", "sqlx-macros", @@ -4544,18 +4539,18 @@ dependencies = [ [[package]] name = "sqlx-core" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbc16ddba161afc99e14d1713a453747a2b07fc097d2009f4c300ec99286105" +checksum = "fa8241483a83a3f33aa5fff7e7d9def398ff9990b2752b6c6112b83c6d246029" dependencies = [ - "ahash", + "ahash 0.7.6", "atoi", "base64 0.13.1", - "bitflags", + "bitflags 1.3.2", "byteorder", "bytes", "chrono", - "crc 3.0.1", + "crc", "crossbeam-queue", "dirs", "dotenvy", @@ -4569,8 +4564,8 @@ dependencies = [ "hex", "hkdf", "hmac 0.12.1", - "indexmap", - "itoa 1.0.5", + "indexmap 1.9.3", + "itoa", "libc", "log", "md-5 0.10.5", @@ -4584,7 +4579,7 @@ dependencies = [ "serde", "serde_json", "sha1", - "sha2 0.10.6", + "sha2 0.10.7", "smallvec", "sqlformat", "sqlx-rt", @@ -4598,31 +4593,31 @@ dependencies = [ [[package]] name = "sqlx-macros" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b850fa514dc11f2ee85be9d055c512aa866746adfacd1cb42d867d68e6a5b0d9" +checksum = "9966e64ae989e7e575b19d7265cb79d7fc3cbbdf179835cb0d716f294c2049c9" dependencies = [ "dotenvy", "either", "heck 0.4.1", "hex", "once_cell", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "serde", "serde_json", - "sha2 0.10.6", + "sha2 0.10.7", "sqlx-core", "sqlx-rt", - "syn 1.0.107", + "syn 1.0.109", "url", ] [[package]] name = "sqlx-rt" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c5b2d25fa654cc5f841750b8e1cdedbe21189bf9a9382ee90bfa9dd3562396" +checksum = "804d3f245f894e61b1e6263c84b23ca675d96753b5abfd5cc8597d86806e8024" dependencies = [ "once_cell", "tokio", @@ -4637,7 +4632,7 @@ checksum = "19cfdc32e0199062113edf41f344fbf784b8205a94600233c84eb838f45191e1" dependencies = [ "base64ct", "pem-rfc7468", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -4652,12 +4647,145 @@ dependencies = [ "rand_core 0.6.4", "rsa", "sec1", - "sha2 0.10.6", + "sha2 0.10.7", "signature 1.6.4", "ssh-encoding", "zeroize", ] +[[package]] +name = "stable_deref_trait" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" + +[[package]] +name = "stacker" +version = "0.1.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c886bd4480155fd3ef527d45e9ac8dd7118a898a46530b7b94c3e21866259fce" +dependencies = [ + "cc", + "cfg-if 1.0.0", + "libc", + "psm", + "winapi", +] + +[[package]] +name = "start-os" +version = "0.3.4-rev.4" +dependencies = [ + "aes", + "async-compression", + "async-stream", + "async-trait", + "avahi-sys", + "base32", + "base64 0.13.1", + "base64ct", + "basic-cookies", + "bimap", + "bollard", + "bytes", + "chrono", + "ciborium", + "clap 3.2.25", + "color-eyre", + "cookie", + "cookie_store 0.19.1", + "current_platform", + "digest 0.10.7", + "digest 0.9.0", + "divrem", + "ed25519", + "ed25519-dalek", + "embassy_container_init", + "emver", + "fd-lock-rs", + "futures", + "git-version", + "gpt", + "helpers", + "hex", + "hmac 0.12.1", + "http", + "hyper", + "hyper-ws-listener", + "id-pool", + "imbl 2.0.0", + "include_dir", + "indexmap 1.9.3", + "ipnet", + "iprange", + "isocountry", + "itertools 0.10.5", + "jaq-core", + "jaq-std", + "josekit", + "js_engine", + "jsonpath_lib", + "lazy_static", + "libc", + "log", + "mbrman", + "models", + "new_mime_guess", + "nix 0.25.1", + "nom 7.1.3", + "num", + "num_enum", + "openssh-keys", + "openssl", + "p256 0.12.0", + "patch-db", + "pbkdf2", + "pin-project", + "pkcs8", + "prettytable-rs", + "proptest", + "proptest-derive", + "rand 0.7.3", + "rand 0.8.5", + "regex", + "reqwest", + "reqwest_cookie_store", + "rpassword", + "rpc-toolkit", + "rust-argon2", + "scopeguard", + "serde", + "serde_json", + "serde_with 2.3.3", + "serde_yaml", + "sha2 0.10.7", + "sha2 0.9.9", + "simple-logging", + "sqlx", + "ssh-key", + "stderrlog", + "tar", + "thiserror", + "tokio", + "tokio-rustls", + "tokio-socks", + "tokio-stream", + "tokio-tar", + "tokio-tungstenite", + "tokio-util", + "toml", + "torut", + "tracing", + "tracing-error 0.2.0", + "tracing-futures", + "tracing-subscriber 0.3.17", + "trust-dns-server", + "typed-builder", + "url", + "uuid", + "zeroize", +] + [[package]] name = "static_assertions" version = "1.1.0" @@ -4679,9 +4807,9 @@ dependencies = [ [[package]] name = "string_cache" -version = "0.8.4" +version = "0.8.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "213494b7a2b503146286049378ce02b482200519accc31872ee8be91fa820a08" +checksum = "f91138e76242f575eb1d3b38b4f1362f10d3a43f47d182a5b359af488a02293b" dependencies = [ "new_debug_unreachable", "once_cell", @@ -4699,28 +4827,28 @@ checksum = "6bb30289b722be4ff74a408c3cc27edeaad656e06cb1fe8fa9231fa59c728988" dependencies = [ "phf_generator", "phf_shared", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", ] [[package]] name = "string_enum" -version = "0.3.2" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "994453cd270ad0265796eb24abf5540091ed03e681c5f3c12bc33e4db33253e1" +checksum = "0090512bdfee4b56d82480d66c0fd8a6f53f0fe0f97e075e949b252acdd482e0" dependencies = [ "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "swc_macros_common", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] name = "stringprep" -version = "0.1.2" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ee348cb74b87454fff4b551cbf727025810a004f88aeacae7f85b87f4e9a1c1" +checksum = "db3737bde7edce97102e0e2b15365bf7a20bfdb5f60f4f9e8d7004258a51a8da" dependencies = [ "unicode-bidi", "unicode-normalization", @@ -4732,18 +4860,34 @@ version = "0.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a" -[[package]] -name = "strsim" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6446ced80d6c486436db5c078dde11a9f73d42b57fb273121e160b84f63d894c" - [[package]] name = "strsim" version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" +[[package]] +name = "strum" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "063e6045c0e62079840579a7e47a355ae92f60eb74daaf156fb1e84ba164e63f" +dependencies = [ + "strum_macros", +] + +[[package]] +name = "strum_macros" +version = "0.24.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59" +dependencies = [ + "heck 0.4.1", + "proc-macro2 1.0.66", + "quote 1.0.31", + "rustversion", + "syn 1.0.109", +] + [[package]] name = "subtle" version = "2.4.1" @@ -4752,27 +4896,31 @@ checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" [[package]] name = "swc_atoms" -version = "0.2.11" +version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba8735ce37e421749498e038955abc1135eec6a4af0b54a173e55d2e5542d472" +checksum = "93d0307dc4bfd107d49c7528350c372758cfca94fb503629b9a056e6a1572860" dependencies = [ + "once_cell", + "rustc-hash", + "serde", "string_cache", "string_cache_codegen", + "triomphe", ] [[package]] name = "swc_common" -version = "0.18.7" +version = "0.31.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4516bf4969a924bfd1801aed5c4b214687665898c14b7584d227827faff9d6c" +checksum = "19c774005489d2907fb67909cf42af926e72edee1366512777c605ba2ef19c94" dependencies = [ - "ahash", + "ahash 0.7.6", "ast_node", "better_scoped_tls", "cfg-if 1.0.0", - "debug_unreachable", "either", "from_variant", + "new_debug_unreachable", "num-bigint", "once_cell", "rustc-hash", @@ -4780,6 +4928,7 @@ dependencies = [ "siphasher", "sourcemap", "string_cache", + "swc_atoms", "swc_eq_ignore_macros", "swc_visit", "tracing", @@ -4789,12 +4938,11 @@ dependencies = [ [[package]] name = "swc_config" -version = "0.1.1" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8bb05ef56c14b95dd7e62e95960153af811b9a447287f1f6ca59f1337fb83d4" +checksum = "89c8fc2c12bb1634c7c32fc3c9b6b963ad8f034cc62c4ecddcf215dc4f6f959d" dependencies = [ - "anyhow", - "indexmap", + "indexmap 1.9.3", "serde", "serde_json", "swc_config_macro", @@ -4802,23 +4950,24 @@ dependencies = [ [[package]] name = "swc_config_macro" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb64bc03d90fd5c90d6ab917bb2b1d7fbd31957df39e31ea24a3f554b4372251" +checksum = "7dadb9998d4f5fc36ef558ed5a092579441579ee8c6fcce84a5228cca9df4004" dependencies = [ "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "swc_macros_common", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] name = "swc_ecma_ast" -version = "0.78.1" +version = "0.104.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21f40169fe465e9a93cda5fe397c3afcb69be5ba2f76c4ab22137af6effaebcc" +checksum = "b5cf9dd351d0c285dcd36535267953a18995d4dda0cbe34ac9d1df61aa415b26" dependencies = [ + "bitflags 2.3.3", "is-macro", "num-bigint", "scoped-tls", @@ -4831,15 +4980,15 @@ dependencies = [ [[package]] name = "swc_ecma_codegen" -version = "0.108.6" +version = "0.139.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5eec1d30c8f85e8267a8efc66d680aa777902d567c3a05b7dfd42965a4872243" +checksum = "c66d1ea16bb9b7ea6f87f17325742ff256fcbd65b188af57c2bf415fe4afc945" dependencies = [ - "bitflags", "memchr", "num-bigint", "once_cell", "rustc-hash", + "serde", "sourcemap", "swc_atoms", "swc_common", @@ -4850,29 +4999,44 @@ dependencies = [ [[package]] name = "swc_ecma_codegen_macros" -version = "0.7.0" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59949619b2ef45eedb6c399d05f2c3c7bc678b5074b3103bb670f9e05bb99042" +checksum = "bf4ee0caee1018808d94ecd09490cb7affd3d504b19aa11c49238f5fc4b54901" dependencies = [ "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "swc_macros_common", - "syn 1.0.107", + "syn 1.0.109", +] + +[[package]] +name = "swc_ecma_loader" +version = "0.43.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe45f1e5dcc1b005544ff78253b787dea5dfd5e2f712b133964cdc3545c954a4" +dependencies = [ + "ahash 0.7.6", + "anyhow", + "pathdiff", + "serde", + "swc_common", + "tracing", ] [[package]] name = "swc_ecma_parser" -version = "0.104.2" +version = "0.134.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5fea08aeb2eb1469928ac7ca2d208fe7816871787e4d93e34924495e724bb25" +checksum = "f0a3fcfe3d83dd445cbd9321882e47b467594433d9a21c4d6c37a27f534bb89e" dependencies = [ "either", - "enum_kind", "lexical", "num-bigint", "serde", "smallvec", + "smartstring", + "stacker", "swc_atoms", "swc_common", "swc_ecma_ast", @@ -4880,30 +5044,15 @@ dependencies = [ "typed-arena", ] -[[package]] -name = "swc_ecma_transforms" -version = "0.154.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bce21d9e8ff785aaf9b4ac11375d9f5767630fcaf882f72e6af0516224085a6" -dependencies = [ - "swc_atoms", - "swc_common", - "swc_ecma_ast", - "swc_ecma_transforms_base", - "swc_ecma_transforms_proposal", - "swc_ecma_transforms_react", - "swc_ecma_transforms_typescript", - "swc_ecma_utils", - "swc_ecma_visit", -] - [[package]] name = "swc_ecma_transforms_base" -version = "0.85.4" +version = "0.127.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "528c99be91500ed393e04e5cfc37763b4b68b71bc4f9b54ff0cd21d714920130" +checksum = "f9c33ec5369178f3a0580ab86cfe89ffb9c3fbd122aed379cfb71d469d9d61c1" dependencies = [ "better_scoped_tls", + "bitflags 2.3.3", + "indexmap 1.9.3", "once_cell", "phf", "rustc-hash", @@ -4920,9 +5069,9 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_classes" -version = "0.73.0" +version = "0.116.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e74a27c29def9db5ff03db4d3ab3d37701fb6d100951162223b71132908451eb" +checksum = "6e3b0d5f362f0da97be1f1b06d7b0d8667ea70b4adeabff0dcaecb6259c09525" dependencies = [ "swc_atoms", "swc_common", @@ -4934,24 +5083,25 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_macros" -version = "0.3.0" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18712e4aab969c6508dff3540ade6358f1e013464aa58b3d30da2ab2d9fcbbed" +checksum = "984d5ac69b681fc5438f9abf82b0fda34fe04e119bc75f8213b7e01128c7c9a2" dependencies = [ "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "swc_macros_common", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] name = "swc_ecma_transforms_proposal" -version = "0.107.0" +version = "0.161.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47fc0f3b336764f89adf1899830321c3f5a7e845ede3ad5949eeb7468aa260ab" +checksum = "0cdce42d44ef775bc29f5ada3678a80ff72fa17a0ef705e14f63cfd0e0155e0e" dependencies = [ "either", + "rustc-hash", "serde", "smallvec", "swc_atoms", @@ -4966,16 +5116,15 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_react" -version = "0.114.1" +version = "0.173.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fbfcd197ebeb0547b59dee39a164633bcf4fb0edbae886f8046e471e6a10502" +checksum = "5fb9481ad4e2acba34c6fbb6d4ccc64efe9f1821675e883dcfa732d7220f4b1e" dependencies = [ - "ahash", + "ahash 0.7.6", "base64 0.13.1", "dashmap", - "indexmap", + "indexmap 1.9.3", "once_cell", - "regex", "serde", "sha-1", "string_enum", @@ -4992,9 +5141,9 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_typescript" -version = "0.117.2" +version = "0.177.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96bf410ffcf91d85dc1f8f1bb969fa2637f9430a6917f2174ad76458c776cb89" +checksum = "1fe2eea4f5b8a25c93cdaa29fb1ce4108893da88a11e61e04b7f5295b5468829" dependencies = [ "serde", "swc_atoms", @@ -5008,24 +5157,27 @@ dependencies = [ [[package]] name = "swc_ecma_utils" -version = "0.85.1" +version = "0.117.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "031ac49cf598f00f048fecd87b3bda5e14b86f6ccd561ada7fce461e0a3ea8d1" +checksum = "ad791bbfdafcebd878584021e050964c8ab68aba7eeac9d0ee4afba4c284a629" dependencies = [ - "indexmap", + "indexmap 1.9.3", + "num_cpus", "once_cell", + "rustc-hash", "swc_atoms", "swc_common", "swc_ecma_ast", "swc_ecma_visit", "tracing", + "unicode-id", ] [[package]] name = "swc_ecma_visit" -version = "0.64.0" +version = "0.90.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2d3783a0dd1e301ae2945ab1241405f913427f9512ec62756d3d2072f7c21bb" +checksum = "6ce3ac941ae1d6c7e683aa375fc71fbf58df58b441f614d757fbb10554936ca2" dependencies = [ "num-bigint", "swc_atoms", @@ -5035,49 +5187,35 @@ dependencies = [ "tracing", ] -[[package]] -name = "swc_ecmascript" -version = "0.157.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd35679e1dc392f776b691b125692d90a7bebd5d23ec96699cfe37d8ae8633b1" -dependencies = [ - "swc_ecma_ast", - "swc_ecma_codegen", - "swc_ecma_parser", - "swc_ecma_transforms", - "swc_ecma_utils", - "swc_ecma_visit", -] - [[package]] name = "swc_eq_ignore_macros" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c8f200a2eaed938e7c1a685faaa66e6d42fa9e17da5f62572d3cbc335898f5e" +checksum = "0c20468634668c2bbab581947bb8c75c97158d5a6959f4ba33df20983b20b4f6" dependencies = [ "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] name = "swc_macros_common" -version = "0.3.5" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5dca3f08d02da4684c3373150f7c045128f81ea00f0c434b1b012bc65a6cce3" +checksum = "3e582c3e3c2269238524923781df5be49e011dbe29cf7683a2215d600a562ea6" dependencies = [ "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] name = "swc_visit" -version = "0.3.0" +version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c639379dd2a8a0221fa1e12fafbdd594ba53a0cace6560054da52409dfcc1a" +checksum = "5f412dd4fbc58f509a04e64f5c8038333142fc139e8232f01b883db0094b3b51" dependencies = [ "either", "swc_visit_macros", @@ -5085,16 +5223,16 @@ dependencies = [ [[package]] name = "swc_visit_macros" -version = "0.3.1" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3b9b72892df873972549838bf84d6c56234c7502148a7e23b5a3da6e0fedfb8" +checksum = "4cfc226380ba54a5feed2c12f3ccd33f1ae8e959160290e5d2d9b4e918b6472a" dependencies = [ "Inflector", "pmutil", - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "swc_macros_common", - "syn 1.0.107", + "syn 1.0.109", ] [[package]] @@ -5110,25 +5248,24 @@ dependencies = [ [[package]] name = "syn" -version = "1.0.107" +version = "1.0.109" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f4064b5b16e03ae50984a5a8ed5d4f8803e6bc1fd170a3cda91a1be4b18e3f5" +checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", + "proc-macro2 1.0.66", + "quote 1.0.31", "unicode-ident", ] [[package]] -name = "synstructure" -version = "0.12.6" +name = "syn" +version = "2.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f" +checksum = "32d41677bcbe24c20c52e7c70b0d8db04134c5d1066bf98662e2871ad200ea3e" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", - "unicode-xid 0.2.4", + "proc-macro2 1.0.66", + "quote 1.0.31", + "unicode-ident", ] [[package]] @@ -5139,9 +5276,9 @@ checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" [[package]] name = "tar" -version = "0.4.38" +version = "0.4.39" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4b55807c0344e1e6c04d7c965f5289c39a8d94ae23ed5c0b57aabac549f871c6" +checksum = "ec96d2ffad078296368d46ff1cb309be1c23c513b4ab0e22a45de0185275ac96" dependencies = [ "filetime", "libc", @@ -5150,16 +5287,16 @@ dependencies = [ [[package]] name = "tempfile" -version = "3.3.0" +version = "3.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cdb1ef4eaeeaddc8fbd371e5017057064af0911902ef36b39801f67cc6d79e4" +checksum = "31c0432476357e58790aaa47a8efb0c5138f137343f3b5f23bd36a27e3b0a6d6" dependencies = [ + "autocfg", "cfg-if 1.0.0", "fastrand", - "libc", - "redox_syscall 0.2.16", - "remove_dir_all", - "winapi", + "redox_syscall 0.3.5", + "rustix 0.37.23", + "windows-sys 0.48.0", ] [[package]] @@ -5184,9 +5321,9 @@ dependencies = [ [[package]] name = "text_lines" -version = "0.4.1" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e49e3c53dd04de8b8e8390bc4fab57f6db7af7d33b086fe411803e6351c9f9f9" +checksum = "7fd5828de7deaa782e1dd713006ae96b3bee32d3279b79eb67ecf8072c059bcf" dependencies = [ "serde", ] @@ -5208,22 +5345,22 @@ checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" [[package]] name = "thiserror" -version = "1.0.38" +version = "1.0.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a9cd18aa97d5c45c6603caea1da6628790b37f7a34b6ca89522331c5180fed0" +checksum = "978c9a314bd8dc99be594bc3c175faaa9794be04a5a5e153caba6915336cebac" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.38" +version = "1.0.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fb327af4685e4d03fa8cbcf1716380da910eeb2bb8be417e7f9fd3fb164f36f" +checksum = "f9456a42c5b0d803c8cd86e73dd7cc9edd429499f37a3550d286d5e86720569f" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] @@ -5260,11 +5397,11 @@ dependencies = [ [[package]] name = "time" -version = "0.3.17" +version = "0.3.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a561bf4617eebd33bca6434b988f39ed798e527f51a1e797d0ee4f61c0a38376" +checksum = "59e399c068f43a5d116fedaf73b203fa4f9c519f17e2b34f63221d3792f81446" dependencies = [ - "itoa 1.0.5", + "itoa", "serde", "time-core", "time-macros", @@ -5272,15 +5409,15 @@ dependencies = [ [[package]] name = "time-core" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2e153e1f1acaef8acc537e68b44906d2db6436e2b35ac2c6b42640fff91f00fd" +checksum = "7300fbefb4dadc1af235a9cef3737cea692a9d97e1b9cbcd4ebdae6f8868e6fb" [[package]] name = "time-macros" -version = "0.2.6" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d967f99f534ca7e495c575c62638eebc2898a8c84c119b89e250477bc4ba16b2" +checksum = "96ba15a897f3c86766b757e5ac7221554c6750054d74d5b28844fce5fb36a6c4" dependencies = [ "time-core", ] @@ -5311,14 +5448,14 @@ checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.25.0" +version = "1.29.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c8e00990ebabbe4c14c08aca901caed183ecd5c09562a12c824bb53d3c3fd3af" +checksum = "532826ff75199d5833b9d2c5fe410f29235e25704ee5f0ef599fb51c21f4a4da" dependencies = [ "autocfg", + "backtrace", "bytes", "libc", - "memchr", "mio", "num_cpus", "parking_lot 0.12.1", @@ -5326,18 +5463,18 @@ dependencies = [ "signal-hook-registry", "socket2", "tokio-macros", - "windows-sys 0.42.0", + "windows-sys 0.48.0", ] [[package]] name = "tokio-macros" -version = "1.8.2" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d266c00fde287f55d3f1c3e96c500c362a2b8c695076ec180f27918820bc6df8" +checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] @@ -5375,9 +5512,9 @@ dependencies = [ [[package]] name = "tokio-stream" -version = "0.1.11" +version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d660770404473ccd7bc9f8b28494a811bc18542b915c0855c51e8f419d5223ce" +checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" dependencies = [ "futures-core", "pin-project-lite", @@ -5415,9 +5552,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.7" +version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5427d89453009325de0d8f342c9490009f76e999cb7672d77e46267448f7e6b2" +checksum = "806fe8c2c87eccc8b3267cbae29ed3ab2d0bd37fca70ab622e46aaa9375ddb7d" dependencies = [ "bytes", "futures-core", @@ -5438,19 +5575,19 @@ dependencies = [ [[package]] name = "toml_datetime" -version = "0.5.1" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4553f467ac8e3d374bc9a177a26801e5d0f9b211aa1673fb137a403afd1c9cf5" +checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" [[package]] name = "toml_edit" -version = "0.18.1" +version = "0.19.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "56c59d8dd7d0dcbc6428bf7aa2f0e823e26e43b3c9aca15bbc9475d23e5fa12b" +checksum = "f8123f27e969974a3dfba720fdb560be359f57b44302d280ba72e76a74480e8a" dependencies = [ - "indexmap", - "nom8", + "indexmap 2.0.0", "toml_datetime", + "winnow", ] [[package]] @@ -5493,20 +5630,20 @@ dependencies = [ [[package]] name = "tracing-attributes" -version = "0.1.23" +version = "0.1.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" +checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] [[package]] name = "tracing-core" -version = "0.1.30" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" +checksum = "0955b8137a1df6f1a2e9a37d8a6656291ff0297c1a97c24e0d8425fe2312f79a" dependencies = [ "once_cell", "valuable", @@ -5529,7 +5666,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d686ec1c0f384b1277f097b2f279a2ecc11afe8c133c1aabf036a27cb4cd206e" dependencies = [ "tracing", - "tracing-subscriber 0.3.16", + "tracing-subscriber 0.3.17", ] [[package]] @@ -5566,9 +5703,9 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.16" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6176eae26dd70d0c919749377897b54a9276bd7061339665dd68777926b5a70" +checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" dependencies = [ "matchers", "nu-ansi-term", @@ -5591,6 +5728,16 @@ dependencies = [ "serde_json", ] +[[package]] +name = "triomphe" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0eee8098afad3fb0c54a9007aab6804558410503ad676d4633f9c2559a00ac0f" +dependencies = [ + "serde", + "stable_deref_trait", +] + [[package]] name = "trust-dns-client" version = "0.22.0" @@ -5605,7 +5752,7 @@ dependencies = [ "radix_trie", "rand 0.8.5", "thiserror", - "time 0.3.17", + "time 0.3.23", "tokio", "tracing", "trust-dns-proto", @@ -5638,9 +5785,9 @@ dependencies = [ [[package]] name = "trust-dns-server" -version = "0.22.0" +version = "0.22.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1583cf9f8a359c9f16fdf760b79cb2be3f261b98db8027f81959c7a4f6645e2c" +checksum = "99022f9befa6daec2a860be68ac28b1f0d9d7ccf441d8c5a695e35a58d88840d" dependencies = [ "async-trait", "bytes", @@ -5650,7 +5797,7 @@ dependencies = [ "futures-util", "serde", "thiserror", - "time 0.3.17", + "time 0.3.23", "tokio", "toml", "tracing", @@ -5696,9 +5843,9 @@ version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "89851716b67b937e393b3daa8423e67ddfc4bbbf1654bcf05488e95e0828db0c" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 1.0.109", ] [[package]] @@ -5714,10 +5861,19 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "eaea85b334db583fe3274d12b4cd1880032beab409c0d774be044d4480ab9a94" [[package]] -name = "unicode-bidi" -version = "0.3.10" +name = "unicase" +version = "2.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d54675592c1dbefd78cbd98db9bacd89886e1ca50692a0692baefffdeb92dd58" +checksum = "50f37be617794602aabbeee0be4f259dc1778fabe05e2d67ee8f79326d5cb4f6" +dependencies = [ + "version_check", +] + +[[package]] +name = "unicode-bidi" +version = "0.3.13" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" [[package]] name = "unicode-id" @@ -5727,9 +5883,9 @@ checksum = "d70b6494226b36008c8366c288d77190b3fad2eb4c10533139c1c1f461127f1a" [[package]] name = "unicode-ident" -version = "1.0.6" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84a22b9f218b40614adcb3f4ff08b703773ad44fa9423e4e0d346d5db86e4ebc" +checksum = "301abaae475aa91687eb82514b328ab47a211a533026cb25fc3e519b86adfc3c" [[package]] name = "unicode-normalization" @@ -5770,20 +5926,11 @@ version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e" -[[package]] -name = "unreachable" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f2ae5ddb18e1c92664717616dd9549dde73f539f01bd7b77c2edb2446bdff91" -dependencies = [ - "void", -] - [[package]] name = "unsafe-libyaml" -version = "0.2.5" +version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc7ed8ba44ca06be78ea1ad2c3682a43349126c8818054231ee6f4748012aed2" +checksum = "f28467d3e1d3c6586d8f25fa243f544f5800fec42d97032474e17222c2b75cfa" [[package]] name = "untrusted" @@ -5793,12 +5940,12 @@ checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" [[package]] name = "url" -version = "2.3.1" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" +checksum = "50bff7831e19200a85b17131d085c25d7811bc4e186efdaf54bbd132994a88cb" dependencies = [ "form_urlencoded", - "idna 0.3.0", + "idna 0.4.0", "percent-encoding", "serde", ] @@ -5811,32 +5958,22 @@ checksum = "09cc8ee72d2a9becf2f2febe0205bbed8fc6615b7cb429ad062dc7b7ddd036a9" [[package]] name = "uuid" -version = "0.8.2" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc5cf98d8186244414c848017f0e2676b3fcb46807f6668a97dfe67359a3c4b7" +checksum = "79daa5ed5740825c40b389c5e50312b9c86df53fccd33f281df655642b43869d" dependencies = [ - "getrandom 0.2.8", -] - -[[package]] -name = "uuid" -version = "1.3.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1674845326ee10d37ca60470760d4288a6f80f304007d92e5c53bab78c9cfd79" -dependencies = [ - "getrandom 0.2.8", + "getrandom 0.2.10", ] [[package]] name = "v8" -version = "0.43.1" +version = "0.74.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c87ec36fec9ea2cd5a368ae9d0a662a7c5e8caa8768ec1fcc02bea623681b98" +checksum = "7568bf38565bd5b350d96abbf3d09417e8c9dd74fbb38860e91b759e46f9009c" dependencies = [ - "bitflags", + "bitflags 1.3.2", "fslock", - "lazy_static", - "libc", + "once_cell", "which 4.4.0", ] @@ -5864,12 +6001,6 @@ version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" -[[package]] -name = "void" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" - [[package]] name = "wait-timeout" version = "0.2.0" @@ -5881,11 +6012,10 @@ dependencies = [ [[package]] name = "want" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" dependencies = [ - "log", "try-lock", ] @@ -5909,9 +6039,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "31f8dcbc21f30d9b8f2ea926ecb58f6b91192c17e9d33594b3df58b2007ca53b" +checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" dependencies = [ "cfg-if 1.0.0", "wasm-bindgen-macro", @@ -5919,24 +6049,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95ce90fd5bcc06af55a641a86428ee4229e44e07033963a2290a8e241607ccb9" +checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" dependencies = [ "bumpalo", "log", "once_cell", - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.34" +version = "0.4.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f219e0d211ba40266969f6dbdd90636da12f75bee4fc9d6c23d1260dadb51454" +checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" dependencies = [ "cfg-if 1.0.0", "js-sys", @@ -5946,32 +6076,32 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c21f77c0bedc37fd5dc21f897894a5ca01e7bb159884559461862ae90c0b4c5" +checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" dependencies = [ - "quote 1.0.23", + "quote 1.0.31", "wasm-bindgen-macro-support", ] [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2aff81306fcac3c7515ad4e177f521b5c9a15f2b08f4e32d823066102f35a5f6" +checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.84" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0046fef7e28c3804e5e38bfa31ea2a0f73905319b677e57ebe37e49358989b5d" +checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" [[package]] name = "wasm-streams" @@ -5988,9 +6118,9 @@ dependencies = [ [[package]] name = "web-sys" -version = "0.3.61" +version = "0.3.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e33b99f4b23ba3eec1a53ac264e35a755f00e966e0065077d6027c0f575b0b97" +checksum = "9b85cbef8c220a6abc02aefd892dfc0fc23afb1c6a426316ec33253a3877249b" dependencies = [ "js-sys", "wasm-bindgen", @@ -6037,9 +6167,9 @@ dependencies = [ [[package]] name = "whoami" -version = "1.3.0" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45dbc71f0cdca27dc261a9bd37ddec174e4a0af2b900b890f378460f745426e3" +checksum = "22fc3756b8a9133049b26c7f61ab35416c130e8c09b660f5b3958b446f52cc50" dependencies = [ "wasm-bindgen", "web-sys", @@ -6077,18 +6207,12 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] -name = "windows-sys" -version = "0.42.0" +name = "windows" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" +checksum = "e686886bc078bc1b0b600cac0147aadb815089b6e4da64016cbd754b6342700f" dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc", - "windows_i686_gnu", - "windows_i686_msvc", - "windows_x86_64_gnu", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc", + "windows-targets 0.48.1", ] [[package]] @@ -6097,65 +6221,140 @@ version = "0.45.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" dependencies = [ - "windows-targets", + "windows-targets 0.42.2", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.1", ] [[package]] name = "windows-targets" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8e2522491fbfcd58cc84d47aeb2958948c4b8982e9a2d8a2a35bbaed431390e7" +checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc", - "windows_i686_gnu", - "windows_i686_msvc", - "windows_x86_64_gnu", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc", + "windows_aarch64_gnullvm 0.42.2", + "windows_aarch64_msvc 0.42.2", + "windows_i686_gnu 0.42.2", + "windows_i686_msvc 0.42.2", + "windows_x86_64_gnu 0.42.2", + "windows_x86_64_gnullvm 0.42.2", + "windows_x86_64_msvc 0.42.2", +] + +[[package]] +name = "windows-targets" +version = "0.48.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05d4b17490f70499f20b9e791dcf6a299785ce8af4d709018206dc5b4953e95f" +dependencies = [ + "windows_aarch64_gnullvm 0.48.0", + "windows_aarch64_msvc 0.48.0", + "windows_i686_gnu 0.48.0", + "windows_i686_msvc 0.48.0", + "windows_x86_64_gnu 0.48.0", + "windows_x86_64_gnullvm 0.48.0", + "windows_x86_64_msvc 0.48.0", ] [[package]] name = "windows_aarch64_gnullvm" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c9864e83243fdec7fc9c5444389dcbbfd258f745e7853198f365e3c4968a608" +checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" [[package]] name = "windows_aarch64_msvc" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8b1b673ffc16c47a9ff48570a9d85e25d265735c503681332589af6253c6c7" +checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" [[package]] name = "windows_i686_gnu" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3887528ad530ba7bdbb1faa8275ec7a1155a45ffa57c37993960277145d640" +checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" [[package]] name = "windows_i686_msvc" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf4d1122317eddd6ff351aa852118a2418ad4214e6613a50e0191f7004372605" +checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" [[package]] name = "windows_x86_64_gnu" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1040f221285e17ebccbc2591ffdc2d44ee1f9186324dd3e84e99ac68d699c45" +checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" [[package]] name = "windows_x86_64_gnullvm" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "628bfdf232daa22b0d64fdb62b09fcc36bb01f05a3939e20ab73aaf9470d0463" +checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" [[package]] name = "windows_x86_64_msvc" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "447660ad36a13288b1db4d4248e857b510e8c3a225c822ba4fb748c0aafecffd" +checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" + +[[package]] +name = "winnow" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81fac9742fd1ad1bd9643b991319f72dd031016d44b77039a26977eb667141e7" +dependencies = [ + "memchr", +] [[package]] name = "winreg" @@ -6209,21 +6408,20 @@ dependencies = [ [[package]] name = "zeroize" -version = "1.5.7" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c394b5bd0c6f669e7275d9c20aa90ae064cb22e75a1cad54e1b34088034b149f" +checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" dependencies = [ "zeroize_derive", ] [[package]] name = "zeroize_derive" -version = "1.3.3" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44bf07cb3e50ea2003396695d58bf46bc9887a1f362260446fad6bc4e79bd36c" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ - "proc-macro2 1.0.51", - "quote 1.0.23", - "syn 1.0.107", - "synstructure", + "proc-macro2 1.0.66", + "quote 1.0.31", + "syn 2.0.18", ] diff --git a/backend/Cargo.toml b/backend/Cargo.toml index ad9db62e9..bd30771f5 100644 --- a/backend/Cargo.toml +++ b/backend/Cargo.toml @@ -1,7 +1,7 @@ [package] authors = ["Aiden McClelland "] description = "The core of StartOS" -documentation = "https://docs.rs/embassy-os" +documentation = "https://docs.rs/start-os" edition = "2021" keywords = [ "self-hosted", @@ -11,40 +11,28 @@ keywords = [ "full-node", "lightning", ] -name = "embassy-os" +name = "start-os" readme = "README.md" repository = "https://github.com/Start9Labs/start-os" -version = "0.3.4-rev.3" +version = "0.3.4-rev.4" [lib] -name = "embassy" +name = "startos" path = "src/lib.rs" [[bin]] -name = "embassyd" -path = "src/bin/embassyd.rs" - -[[bin]] -name = "embassy-init" -path = "src/bin/embassy-init.rs" - -[[bin]] -name = "embassy-sdk" -path = "src/bin/embassy-sdk.rs" - -[[bin]] -name = "embassy-cli" -path = "src/bin/embassy-cli.rs" - -[[bin]] -name = "avahi-alias" -path = "src/bin/avahi-alias.rs" +name = "startbox" +path = "src/main.rs" [features] avahi = ["avahi-sys"] -default = ["avahi", "js_engine"] +default = ["avahi-alias", "cli", "sdk", "daemon", "js_engine"] dev = [] unstable = ["patch-db/unstable"] +avahi-alias = ["avahi"] +cli = [] +sdk = [] +daemon = [] [dependencies] aes = { version = "0.7.5", features = ["ctr"] } @@ -95,11 +83,14 @@ id-pool = { version = "0.2.2", features = [ "serde", ], default-features = false } imbl = "2.0.0" +include_dir = "0.7.3" indexmap = { version = "1.9.1", features = ["serde"] } ipnet = { version = "2.7.1", features = ["serde"] } iprange = { version = "0.6.7", features = ["serde"] } isocountry = "0.3.2" itertools = "0.10.3" +jaq-core = "0.10.0" +jaq-std = "0.10.0" josekit = "0.8.1" js_engine = { path = '../libs/js_engine', optional = true } jsonpath_lib = "0.3.0" @@ -108,6 +99,7 @@ libc = "0.2.126" log = "0.4.17" mbrman = "0.5.0" models = { version = "*", path = "../libs/models" } +new_mime_guess = "4" nix = "0.25.0" nom = "7.1.1" num = "0.4.0" diff --git a/backend/README.md b/backend/README.md index 8734e6f70..986972efd 100644 --- a/backend/README.md +++ b/backend/README.md @@ -12,18 +12,17 @@ ## Structure -The StartOS backend is broken up into 4 different binaries: +The StartOS backend is packed into a single binary `startbox` that is symlinked under +several different names for different behaviour: -- embassyd: This is the main workhorse of StartOS - any new functionality you +- startd: This is the main workhorse of StartOS - any new functionality you want will likely go here -- embassy-init: This is the component responsible for allowing you to set up - your device, and handles system initialization on startup -- embassy-cli: This is a CLI tool that will allow you to issue commands to - embassyd and control it similarly to the UI -- embassy-sdk: This is a CLI tool that aids in building and packaging services +- start-cli: This is a CLI tool that will allow you to issue commands to + startd and control it similarly to the UI +- start-sdk: This is a CLI tool that aids in building and packaging services you wish to deploy to StartOS -Finally there is a library `embassy` that supports all four of these tools. +Finally there is a library `startos` that supports all of these tools. See [here](/backend/Cargo.toml) for details. diff --git a/backend/build-dev.sh b/backend/build-dev.sh deleted file mode 100755 index 80bfb44c0..000000000 --- a/backend/build-dev.sh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/bash - -set -e -shopt -s expand_aliases - -if [ "$0" != "./build-dev.sh" ]; then - >&2 echo "Must be run from backend directory" - exit 1 -fi - -USE_TTY= -if tty -s; then - USE_TTY="-it" -fi - -alias 'rust-arm64-builder'='docker run $USE_TTY --rm -v "$HOME/.cargo/registry":/root/.cargo/registry -v "$(pwd)":/home/rust/src start9/rust-arm-cross:aarch64' - -cd .. -rust-arm64-builder sh -c "(cd backend && cargo build --locked)" -cd backend - -sudo chown -R $USER target -sudo chown -R $USER ~/.cargo -#rust-arm64-builder aarch64-linux-gnu-strip target/aarch64-unknown-linux-gnu/release/embassyd diff --git a/backend/build-portable-dev.sh b/backend/build-portable-dev.sh deleted file mode 100755 index cdeb2b6d3..000000000 --- a/backend/build-portable-dev.sh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/bash - -set -e -shopt -s expand_aliases - -if [ "$0" != "./build-portable-dev.sh" ]; then - >&2 echo "Must be run from backend directory" - exit 1 -fi - -USE_TTY= -if tty -s; then - USE_TTY="-it" -fi - -alias 'rust-musl-builder'='docker run $USE_TTY --rm -v "$HOME"/.cargo/registry:/root/.cargo/registry -v "$(pwd)":/home/rust/src start9/rust-musl-cross:x86_64-musl' - -cd .. -rust-musl-builder sh -c "(cd backend && cargo +beta build --target=x86_64-unknown-linux-musl --no-default-features --locked)" -cd backend - -sudo chown -R $USER target -sudo chown -R $USER ~/.cargo \ No newline at end of file diff --git a/backend/build-prod.sh b/backend/build-prod.sh index 4f16ee558..db2331eb4 100755 --- a/backend/build-prod.sh +++ b/backend/build-prod.sh @@ -72,5 +72,3 @@ sudo chown -R $USER ../libs/target if [ -n "$fail" ]; then exit 1 fi - -#rust-arm64-builder aarch64-linux-gnu-strip target/aarch64-unknown-linux-gnu/release/embassyd diff --git a/backend/embassy-init.service b/backend/embassy-init.service deleted file mode 100644 index 416791d58..000000000 --- a/backend/embassy-init.service +++ /dev/null @@ -1,15 +0,0 @@ -[Unit] -Description=Embassy Init -After=network-online.target -Requires=network-online.target -Wants=avahi-daemon.service - -[Service] -Type=oneshot -Environment=RUST_LOG=embassy_init=debug,embassy=debug,js_engine=debug,patch_db=warn -ExecStart=/usr/bin/embassy-init -RemainAfterExit=true -StandardOutput=append:/var/log/embassy-init.log - -[Install] -WantedBy=embassyd.service diff --git a/backend/embassyd.service b/backend/embassyd.service deleted file mode 100644 index f9bec7a7f..000000000 --- a/backend/embassyd.service +++ /dev/null @@ -1,17 +0,0 @@ -[Unit] -Description=Embassy Daemon -After=embassy-init.service -Requires=embassy-init.service - -[Service] -Type=simple -Environment=RUST_LOG=embassyd=debug,embassy=debug,js_engine=debug,patch_db=warn -ExecStart=/usr/bin/embassyd -Restart=always -RestartSec=3 -ManagedOOMPreference=avoid -CPUAccounting=true -CPUWeight=1000 - -[Install] -WantedBy=multi-user.target diff --git a/backend/install-sdk.sh b/backend/install-sdk.sh index 10388c5a3..2f5177a8d 100755 --- a/backend/install-sdk.sh +++ b/backend/install-sdk.sh @@ -9,7 +9,10 @@ if [ "$0" != "./install-sdk.sh" ]; then fi if [ -z "$OS_ARCH" ]; then - OS_ARCH=$(uname -m) + export OS_ARCH=$(uname -m) fi -cargo install --bin=embassy-sdk --bin=embassy-cli --path=. --no-default-features --features=js_engine --locked +cargo install --path=. --no-default-features --features=js_engine,sdk,cli --locked +startbox_loc=$(which startbox) +ln -sf $startbox_loc $(dirname $startbox_loc)/start-cli +ln -sf $startbox_loc $(dirname $startbox_loc)/start-sdk \ No newline at end of file diff --git a/backend/src/backup/backup_bulk.rs b/backend/src/backup/backup_bulk.rs index 3ee638b91..d0ae26f52 100644 --- a/backend/src/backup/backup_bulk.rs +++ b/backend/src/backup/backup_bulk.rs @@ -334,7 +334,7 @@ async fn perform_backup( } let luks_folder = Path::new("/media/embassy/config/luks"); if tokio::fs::metadata(&luks_folder).await.is_ok() { - dir_copy(&luks_folder, &luks_folder_bak).await?; + dir_copy(&luks_folder, &luks_folder_bak, None).await?; } let timestamp = Some(Utc::now()); diff --git a/backend/src/backup/restore.rs b/backend/src/backup/restore.rs index 4e9d8247d..2e2bad1f5 100644 --- a/backend/src/backup/restore.rs +++ b/backend/src/backup/restore.rs @@ -109,7 +109,7 @@ async fn approximate_progress( if tokio::fs::metadata(&dir).await.is_err() { *size = 0; } else { - *size = dir_size(&dir).await?; + *size = dir_size(&dir, None).await?; } } Ok(()) @@ -285,7 +285,7 @@ async fn restore_packages( progress_info.package_installs.insert(id.clone(), progress); progress_info .src_volume_size - .insert(id.clone(), dir_size(backup_dir(&id)).await?); + .insert(id.clone(), dir_size(backup_dir(&id), None).await?); progress_info.target_volume_size.insert(id.clone(), 0); let package_id = id.clone(); tasks.push( diff --git a/backend/src/bin/avahi-alias.rs b/backend/src/bins/avahi_alias.rs similarity index 99% rename from backend/src/bin/avahi-alias.rs rename to backend/src/bins/avahi_alias.rs index 22349a927..3c4a4fe7e 100644 --- a/backend/src/bin/avahi-alias.rs +++ b/backend/src/bins/avahi_alias.rs @@ -14,7 +14,7 @@ fn log_str_error(action: &str, e: i32) { } } -fn main() { +pub fn main() { let aliases: Vec<_> = std::env::args().skip(1).collect(); unsafe { let simple_poll = avahi_sys::avahi_simple_poll_new(); diff --git a/backend/src/bins/deprecated.rs b/backend/src/bins/deprecated.rs new file mode 100644 index 000000000..13e0290db --- /dev/null +++ b/backend/src/bins/deprecated.rs @@ -0,0 +1,9 @@ +pub fn renamed(old: &str, new: &str) -> ! { + eprintln!("{old} has been renamed to {new}"); + std::process::exit(1) +} + +pub fn removed(name: &str) -> ! { + eprintln!("{name} has been removed"); + std::process::exit(1) +} diff --git a/backend/src/bins/mod.rs b/backend/src/bins/mod.rs new file mode 100644 index 000000000..76329e094 --- /dev/null +++ b/backend/src/bins/mod.rs @@ -0,0 +1,55 @@ +use std::path::Path; + +#[cfg(feature = "avahi-alias")] +pub mod avahi_alias; +pub mod deprecated; +#[cfg(feature = "cli")] +pub mod start_cli; +#[cfg(feature = "daemon")] +pub mod start_init; +#[cfg(feature = "sdk")] +pub mod start_sdk; +#[cfg(feature = "daemon")] +pub mod startd; + +fn select_executable(name: &str) -> Option { + match name { + #[cfg(feature = "avahi-alias")] + "avahi-alias" => Some(avahi_alias::main), + #[cfg(feature = "cli")] + "start-cli" => Some(start_cli::main), + #[cfg(feature = "sdk")] + "start-sdk" => Some(start_sdk::main), + #[cfg(feature = "daemon")] + "startd" => Some(startd::main), + "embassy-cli" => Some(|| deprecated::renamed("embassy-cli", "start-cli")), + "embassy-sdk" => Some(|| deprecated::renamed("embassy-sdk", "start-sdk")), + "embassyd" => Some(|| deprecated::renamed("embassyd", "startd")), + "embassy-init" => Some(|| deprecated::removed("embassy-init")), + _ => None, + } +} + +pub fn startbox() { + let args = std::env::args().take(2).collect::>(); + if let Some(x) = args + .get(0) + .and_then(|s| Path::new(&*s).file_name()) + .and_then(|s| s.to_str()) + .and_then(|s| select_executable(&s)) + { + x() + } else if let Some(x) = args.get(1).and_then(|s| select_executable(&s)) { + x() + } else { + eprintln!( + "unknown executable: {}", + args.get(0) + .filter(|x| &**x != "startbox") + .or_else(|| args.get(1)) + .map(|s| s.as_str()) + .unwrap_or("N/A") + ); + std::process::exit(1); + } +} diff --git a/backend/src/bin/embassy-cli.rs b/backend/src/bins/start_cli.rs similarity index 88% rename from backend/src/bin/embassy-cli.rs rename to backend/src/bins/start_cli.rs index 2cfd0dde8..3ef64096e 100644 --- a/backend/src/bin/embassy-cli.rs +++ b/backend/src/bins/start_cli.rs @@ -1,21 +1,22 @@ use clap::Arg; -use embassy::context::CliContext; -use embassy::util::logger::EmbassyLogger; -use embassy::version::{Current, VersionT}; -use embassy::Error; use rpc_toolkit::run_cli; use rpc_toolkit::yajrc::RpcError; use serde_json::Value; +use crate::context::CliContext; +use crate::util::logger::EmbassyLogger; +use crate::version::{Current, VersionT}; +use crate::Error; + lazy_static::lazy_static! { static ref VERSION_STRING: String = Current::new().semver().to_string(); } fn inner_main() -> Result<(), Error> { run_cli!({ - command: embassy::main_api, + command: crate::main_api, app: app => app - .name("Embassy CLI") + .name("StartOS CLI") .version(&**VERSION_STRING) .arg( clap::Arg::with_name("config") @@ -48,7 +49,7 @@ fn inner_main() -> Result<(), Error> { Ok(()) } -fn main() { +pub fn main() { match inner_main() { Ok(_) => (), Err(e) => { diff --git a/backend/src/bin/embassy-init.rs b/backend/src/bins/start_init.rs similarity index 85% rename from backend/src/bin/embassy-init.rs rename to backend/src/bins/start_init.rs index 2f680de05..485d8e323 100644 --- a/backend/src/bin/embassy-init.rs +++ b/backend/src/bins/start_init.rs @@ -3,21 +3,22 @@ use std::path::{Path, PathBuf}; use std::sync::Arc; use std::time::Duration; -use embassy::context::rpc::RpcContextConfig; -use embassy::context::{DiagnosticContext, InstallContext, SetupContext}; -use embassy::disk::fsck::RepairStrategy; -use embassy::disk::main::DEFAULT_PASSWORD; -use embassy::disk::REPAIR_DISK_PATH; -use embassy::init::STANDBY_MODE_PATH; -use embassy::net::web_server::WebServer; -use embassy::shutdown::Shutdown; -use embassy::sound::CHIME; -use embassy::util::logger::EmbassyLogger; -use embassy::util::Invoke; -use embassy::{Error, ErrorKind, ResultExt, OS_ARCH}; use tokio::process::Command; use tracing::instrument; +use crate::context::rpc::RpcContextConfig; +use crate::context::{DiagnosticContext, InstallContext, SetupContext}; +use crate::disk::fsck::RepairStrategy; +use crate::disk::main::DEFAULT_PASSWORD; +use crate::disk::REPAIR_DISK_PATH; +use crate::init::STANDBY_MODE_PATH; +use crate::net::web_server::WebServer; +use crate::shutdown::Shutdown; +use crate::sound::CHIME; +use crate::util::logger::EmbassyLogger; +use crate::util::Invoke; +use crate::{Error, ErrorKind, ResultExt, OS_ARCH}; + #[instrument(skip_all)] async fn setup_or_init(cfg_path: Option) -> Result<(), Error> { Command::new("ln") @@ -78,7 +79,7 @@ async fn setup_or_init(cfg_path: Option) -> Result<(), Error> { server.shutdown().await; Command::new("reboot") - .invoke(embassy::ErrorKind::Unknown) + .invoke(crate::ErrorKind::Unknown) .await?; } else if tokio::fs::metadata("/media/embassy/config/disk.guid") .await @@ -116,7 +117,7 @@ async fn setup_or_init(cfg_path: Option) -> Result<(), Error> { let guid_string = tokio::fs::read_to_string("/media/embassy/config/disk.guid") // unique identifier for volume group - keeps track of the disk that goes with your embassy .await?; let guid = guid_string.trim(); - let requires_reboot = embassy::disk::main::import( + let requires_reboot = crate::disk::main::import( guid, cfg.datadir(), if tokio::fs::metadata(REPAIR_DISK_PATH).await.is_ok() { @@ -124,22 +125,26 @@ async fn setup_or_init(cfg_path: Option) -> Result<(), Error> { } else { RepairStrategy::Preen }, - DEFAULT_PASSWORD, + if guid.ends_with("_UNENC") { + None + } else { + Some(DEFAULT_PASSWORD) + }, ) .await?; if tokio::fs::metadata(REPAIR_DISK_PATH).await.is_ok() { tokio::fs::remove_file(REPAIR_DISK_PATH) .await - .with_ctx(|_| (embassy::ErrorKind::Filesystem, REPAIR_DISK_PATH))?; + .with_ctx(|_| (crate::ErrorKind::Filesystem, REPAIR_DISK_PATH))?; } if requires_reboot.0 { - embassy::disk::main::export(guid, cfg.datadir()).await?; + crate::disk::main::export(guid, cfg.datadir()).await?; Command::new("reboot") - .invoke(embassy::ErrorKind::Unknown) + .invoke(crate::ErrorKind::Unknown) .await?; } tracing::info!("Loaded Disk"); - embassy::init::init(&cfg).await?; + crate::init::init(&cfg).await?; } Ok(()) @@ -168,11 +173,11 @@ async fn inner_main(cfg_path: Option) -> Result, Error if OS_ARCH == "raspberrypi" && tokio::fs::metadata(STANDBY_MODE_PATH).await.is_ok() { tokio::fs::remove_file(STANDBY_MODE_PATH).await?; Command::new("sync").invoke(ErrorKind::Filesystem).await?; - embassy::sound::SHUTDOWN.play().await?; + crate::sound::SHUTDOWN.play().await?; futures::future::pending::<()>().await; } - embassy::sound::BEP.play().await?; + crate::sound::BEP.play().await?; run_script_if_exists("/media/embassy/config/preinit.sh").await; @@ -180,7 +185,7 @@ async fn inner_main(cfg_path: Option) -> Result, Error async move { tracing::error!("{}", e.source); tracing::debug!("{}", e.source); - embassy::sound::BEETHOVEN.play().await?; + crate::sound::BEETHOVEN.play().await?; let ctx = DiagnosticContext::init( cfg_path, @@ -223,8 +228,8 @@ async fn inner_main(cfg_path: Option) -> Result, Error res } -fn main() { - let matches = clap::App::new("embassy-init") +pub fn main() { + let matches = clap::App::new("start-init") .arg( clap::Arg::with_name("config") .short('c') @@ -233,8 +238,6 @@ fn main() { ) .get_matches(); - EmbassyLogger::init(); - let cfg_path = matches.value_of("config").map(|p| Path::new(p).to_owned()); let res = { let rt = tokio::runtime::Builder::new_multi_thread() diff --git a/backend/src/bin/embassy-sdk.rs b/backend/src/bins/start_sdk.rs similarity index 88% rename from backend/src/bin/embassy-sdk.rs rename to backend/src/bins/start_sdk.rs index 56c462f53..10219c485 100644 --- a/backend/src/bin/embassy-sdk.rs +++ b/backend/src/bins/start_sdk.rs @@ -1,20 +1,21 @@ -use embassy::context::SdkContext; -use embassy::util::logger::EmbassyLogger; -use embassy::version::{Current, VersionT}; -use embassy::Error; use rpc_toolkit::run_cli; use rpc_toolkit::yajrc::RpcError; use serde_json::Value; +use crate::context::SdkContext; +use crate::util::logger::EmbassyLogger; +use crate::version::{Current, VersionT}; +use crate::Error; + lazy_static::lazy_static! { static ref VERSION_STRING: String = Current::new().semver().to_string(); } fn inner_main() -> Result<(), Error> { run_cli!({ - command: embassy::portable_api, + command: crate::portable_api, app: app => app - .name("Embassy SDK") + .name("StartOS SDK") .version(&**VERSION_STRING) .arg( clap::Arg::with_name("config") @@ -47,7 +48,7 @@ fn inner_main() -> Result<(), Error> { Ok(()) } -fn main() { +pub fn main() { match inner_main() { Ok(_) => (), Err(e) => { diff --git a/backend/src/bin/embassyd.rs b/backend/src/bins/startd.rs similarity index 89% rename from backend/src/bin/embassyd.rs rename to backend/src/bins/startd.rs index 7bfffe717..e6c272803 100644 --- a/backend/src/bin/embassyd.rs +++ b/backend/src/bins/startd.rs @@ -3,16 +3,17 @@ use std::path::{Path, PathBuf}; use std::sync::Arc; use color_eyre::eyre::eyre; -use embassy::context::{DiagnosticContext, RpcContext}; -use embassy::net::web_server::WebServer; -use embassy::shutdown::Shutdown; -use embassy::system::launch_metrics_task; -use embassy::util::logger::EmbassyLogger; -use embassy::{Error, ErrorKind, ResultExt}; use futures::{FutureExt, TryFutureExt}; use tokio::signal::unix::signal; use tracing::instrument; +use crate::context::{DiagnosticContext, RpcContext}; +use crate::net::web_server::WebServer; +use crate::shutdown::Shutdown; +use crate::system::launch_metrics_task; +use crate::util::logger::EmbassyLogger; +use crate::{Error, ErrorKind, ResultExt}; + #[instrument(skip_all)] async fn inner_main(cfg_path: Option) -> Result, Error> { let (rpc_ctx, server, shutdown) = { @@ -26,7 +27,7 @@ async fn inner_main(cfg_path: Option) -> Result, Error ), ) .await?; - embassy::hostname::sync_hostname(&rpc_ctx.account.read().await.hostname).await?; + crate::hostname::sync_hostname(&rpc_ctx.account.read().await.hostname).await?; let server = WebServer::main( SocketAddr::new(Ipv6Addr::UNSPECIFIED.into(), 80), rpc_ctx.clone(), @@ -71,7 +72,7 @@ async fn inner_main(cfg_path: Option) -> Result, Error .await }); - embassy::sound::CHIME.play().await?; + crate::sound::CHIME.play().await?; metrics_task .map_err(|e| { @@ -100,8 +101,15 @@ async fn inner_main(cfg_path: Option) -> Result, Error Ok(shutdown) } -fn main() { - let matches = clap::App::new("embassyd") +pub fn main() { + EmbassyLogger::init(); + + if !Path::new("/run/embassy/initialized").exists() { + super::start_init::main(); + std::fs::write("/run/embassy/initialized", "").unwrap(); + } + + let matches = clap::App::new("startd") .arg( clap::Arg::with_name("config") .short('c') @@ -110,8 +118,6 @@ fn main() { ) .get_matches(); - EmbassyLogger::init(); - let cfg_path = matches.value_of("config").map(|p| Path::new(p).to_owned()); let res = { @@ -126,7 +132,7 @@ fn main() { async { tracing::error!("{}", e.source); tracing::debug!("{:?}", e.source); - embassy::sound::BEETHOVEN.play().await?; + crate::sound::BEETHOVEN.play().await?; let ctx = DiagnosticContext::init( cfg_path, if tokio::fs::metadata("/media/embassy/config/disk.guid") diff --git a/backend/src/context/rpc.rs b/backend/src/context/rpc.rs index 3f983ef86..d453cd26e 100644 --- a/backend/src/context/rpc.rs +++ b/backend/src/context/rpc.rs @@ -269,6 +269,45 @@ impl RpcContext { pub async fn cleanup(&self) -> Result<(), Error> { let mut db = self.db.handle(); let receipts = RpcCleanReceipts::new(&mut db).await?; + let packages = receipts.packages.get(&mut db).await?.0; + let mut current_dependents = packages + .keys() + .map(|k| (k.clone(), BTreeMap::new())) + .collect::>(); + for (package_id, package) in packages { + for (k, v) in package + .into_installed() + .into_iter() + .flat_map(|i| i.current_dependencies.0) + { + let mut entry: BTreeMap<_, _> = current_dependents.remove(&k).unwrap_or_default(); + entry.insert(package_id.clone(), v); + current_dependents.insert(k, entry); + } + } + for (package_id, current_dependents) in current_dependents { + if let Some(deps) = crate::db::DatabaseModel::new() + .package_data() + .idx_model(&package_id) + .and_then(|pde| pde.installed()) + .map::<_, CurrentDependents>(|i| i.current_dependents()) + .check(&mut db) + .await? + { + deps.put(&mut db, &CurrentDependents(current_dependents)) + .await?; + } else if let Some(deps) = crate::db::DatabaseModel::new() + .package_data() + .idx_model(&package_id) + .and_then(|pde| pde.removing()) + .map::<_, CurrentDependents>(|i| i.current_dependents()) + .check(&mut db) + .await? + { + deps.put(&mut db, &CurrentDependents(current_dependents)) + .await?; + } + } for (package_id, package) in receipts.packages.get(&mut db).await?.0 { if let Err(e) = async { match package { @@ -338,31 +377,6 @@ impl RpcContext { tracing::debug!("{:?}", e); } } - let mut current_dependents = BTreeMap::new(); - for (package_id, package) in receipts.packages.get(&mut db).await?.0 { - for (k, v) in package - .into_installed() - .into_iter() - .flat_map(|i| i.current_dependencies.0) - { - let mut entry: BTreeMap<_, _> = current_dependents.remove(&k).unwrap_or_default(); - entry.insert(package_id.clone(), v); - current_dependents.insert(k, entry); - } - } - for (package_id, current_dependents) in current_dependents { - if let Some(deps) = crate::db::DatabaseModel::new() - .package_data() - .idx_model(&package_id) - .and_then(|pde| pde.installed()) - .map::<_, CurrentDependents>(|i| i.current_dependents()) - .check(&mut db) - .await? - { - deps.put(&mut db, &CurrentDependents(current_dependents)) - .await?; - } - } Ok(()) } diff --git a/backend/src/context/setup.rs b/backend/src/context/setup.rs index 8e516d719..7ae161b01 100644 --- a/backend/src/context/setup.rs +++ b/backend/src/context/setup.rs @@ -45,6 +45,8 @@ pub struct SetupContextConfig { pub migration_batch_rows: Option, pub migration_prefetch_rows: Option, pub datadir: Option, + #[serde(default)] + pub disable_encryption: bool, } impl SetupContextConfig { #[instrument(skip_all)] @@ -75,6 +77,7 @@ pub struct SetupContextSeed { pub config_path: Option, pub migration_batch_rows: usize, pub migration_prefetch_rows: usize, + pub disable_encryption: bool, pub shutdown: Sender<()>, pub datadir: PathBuf, pub selected_v2_drive: RwLock>, @@ -102,6 +105,7 @@ impl SetupContext { config_path: path.as_ref().map(|p| p.as_ref().to_owned()), migration_batch_rows: cfg.migration_batch_rows.unwrap_or(25000), migration_prefetch_rows: cfg.migration_prefetch_rows.unwrap_or(100_000), + disable_encryption: cfg.disable_encryption, shutdown, datadir, selected_v2_drive: RwLock::new(None), diff --git a/backend/src/db/mod.rs b/backend/src/db/mod.rs index f51c8d156..a8cc11d1f 100644 --- a/backend/src/db/mod.rs +++ b/backend/src/db/mod.rs @@ -4,9 +4,10 @@ pub mod package; use std::future::Future; use std::sync::Arc; +use color_eyre::eyre::eyre; use futures::{FutureExt, SinkExt, StreamExt}; use patch_db::json_ptr::JsonPointer; -use patch_db::{Dump, Revision}; +use patch_db::{DbHandle, Dump, LockType, Revision}; use rpc_toolkit::command; use rpc_toolkit::hyper::upgrade::Upgraded; use rpc_toolkit::hyper::{Body, Error as HyperError, Request, Response}; @@ -24,6 +25,7 @@ use tracing::instrument; pub use self::model::DatabaseModel; use crate::context::RpcContext; use crate::middleware::auth::{HasValidSession, HashSessionToken}; +use crate::util::display_none; use crate::util::serde::{display_serializable, IoFormat}; use crate::{Error, ResultExt}; @@ -163,7 +165,7 @@ pub async fn subscribe(ctx: RpcContext, req: Request) -> Result Result<(), RpcError> { Ok(()) } @@ -199,6 +201,85 @@ pub async fn dump( Ok(ctx.db.dump().await?) } +fn apply_expr(input: jaq_core::Val, expr: &str) -> Result { + let (expr, errs) = jaq_core::parse::parse(expr, jaq_core::parse::main()); + + let Some(expr) = expr else { + return Err(Error::new( + eyre!("Failed to parse expression: {:?}", errs), + crate::ErrorKind::InvalidRequest, + )); + }; + + let mut errs = Vec::new(); + + let mut defs = jaq_core::Definitions::core(); + for def in jaq_std::std() { + defs.insert(def, &mut errs); + } + + let filter = defs.finish(expr, Vec::new(), &mut errs); + + if !errs.is_empty() { + return Err(Error::new( + eyre!("Failed to compile expression: {:?}", errs), + crate::ErrorKind::InvalidRequest, + )); + }; + + let inputs = jaq_core::RcIter::new(std::iter::empty()); + let mut res_iter = filter.run(jaq_core::Ctx::new([], &inputs), input); + + let Some(res) = res_iter + .next() + .transpose() + .map_err(|e| eyre!("{e}")) + .with_kind(crate::ErrorKind::Deserialization)? + else { + return Err(Error::new( + eyre!("expr returned no results"), + crate::ErrorKind::InvalidRequest, + )); + }; + + if res_iter.next().is_some() { + return Err(Error::new( + eyre!("expr returned too many results"), + crate::ErrorKind::InvalidRequest, + )); + } + + Ok(res) +} + +#[command(display(display_none))] +pub async fn apply(#[context] ctx: RpcContext, #[arg] expr: String) -> Result<(), Error> { + let mut db = ctx.db.handle(); + + DatabaseModel::new().lock(&mut db, LockType::Write).await?; + + let root_ptr = JsonPointer::::default(); + + let input = db.get_value(&root_ptr, None).await?; + + let res = (|| { + let res = apply_expr(input.into(), &expr)?; + + serde_json::from_value::(res.clone().into()).with_ctx(|_| { + ( + crate::ErrorKind::Deserialization, + "result does not match database model", + ) + })?; + + Ok::(res.into()) + })()?; + + db.put_value(&root_ptr, &res).await?; + + Ok(()) +} + #[command(subcommands(ui))] pub fn put() -> Result<(), RpcError> { Ok(()) diff --git a/backend/src/db/model.rs b/backend/src/db/model.rs index c89c8c854..6aa1e07cc 100644 --- a/backend/src/db/model.rs +++ b/backend/src/db/model.rs @@ -51,7 +51,7 @@ impl Database { last_wifi_region: None, eos_version_compat: Current::new().compat().clone(), lan_address, - tor_address: format!("http://{}", account.key.tor_address()) + tor_address: format!("https://{}", account.key.tor_address()) .parse() .unwrap(), ip_info: BTreeMap::new(), @@ -110,6 +110,7 @@ pub struct ServerInfo { pub lan_address: Url, pub tor_address: Url, #[model] + #[serde(default)] pub ip_info: BTreeMap, #[model] #[serde(default)] diff --git a/backend/src/diagnostic.rs b/backend/src/diagnostic.rs index c4c8adbfb..1d4c3bcf5 100644 --- a/backend/src/diagnostic.rs +++ b/backend/src/diagnostic.rs @@ -9,11 +9,10 @@ use crate::disk::repair; use crate::init::SYSTEM_REBUILD_PATH; use crate::logs::{fetch_logs, LogResponse, LogSource}; use crate::shutdown::Shutdown; +use crate::system::SYSTEMD_UNIT; use crate::util::display_none; use crate::Error; -pub const SYSTEMD_UNIT: &'static str = "embassy-init"; - #[command(subcommands(error, logs, exit, restart, forget_disk, disk, rebuild))] pub fn diagnostic() -> Result<(), Error> { Ok(()) diff --git a/backend/src/disk/main.rs b/backend/src/disk/main.rs index 7d7247984..48b392236 100644 --- a/backend/src/disk/main.rs +++ b/backend/src/disk/main.rs @@ -13,7 +13,7 @@ use crate::disk::mount::util::unmount; use crate::util::Invoke; use crate::{Error, ErrorKind, ResultExt}; -pub const PASSWORD_PATH: &'static str = "/etc/embassy/password"; +pub const PASSWORD_PATH: &'static str = "/run/embassy/password"; pub const DEFAULT_PASSWORD: &'static str = "password"; pub const MAIN_FS_SIZE: FsSize = FsSize::Gigabytes(8); @@ -22,13 +22,13 @@ pub async fn create( disks: &I, pvscan: &BTreeMap>, datadir: impl AsRef, - password: &str, + password: Option<&str>, ) -> Result where for<'a> &'a I: IntoIterator, P: AsRef, { - let guid = create_pool(disks, pvscan).await?; + let guid = create_pool(disks, pvscan, password.is_some()).await?; create_all_fs(&guid, &datadir, password).await?; export(&guid, datadir).await?; Ok(guid) @@ -38,6 +38,7 @@ where pub async fn create_pool( disks: &I, pvscan: &BTreeMap>, + encrypted: bool, ) -> Result where for<'a> &'a I: IntoIterator, @@ -62,13 +63,16 @@ where .invoke(crate::ErrorKind::DiskManagement) .await?; } - let guid = format!( + let mut guid = format!( "EMBASSY_{}", base32::encode( base32::Alphabet::RFC4648 { padding: false }, &rand::random::<[u8; 32]>(), ) ); + if !encrypted { + guid += "_UNENC"; + } let mut cmd = Command::new("vgcreate"); cmd.arg("-y").arg(&guid); for disk in disks { @@ -90,11 +94,8 @@ pub async fn create_fs>( datadir: P, name: &str, size: FsSize, - password: &str, + password: Option<&str>, ) -> Result<(), Error> { - tokio::fs::write(PASSWORD_PATH, password) - .await - .with_ctx(|_| (crate::ErrorKind::Filesystem, PASSWORD_PATH))?; let mut cmd = Command::new("lvcreate"); match size { FsSize::Gigabytes(a) => cmd.arg("-L").arg(format!("{}G", a)), @@ -106,37 +107,41 @@ pub async fn create_fs>( .arg(guid) .invoke(crate::ErrorKind::DiskManagement) .await?; - let crypt_path = Path::new("/dev").join(guid).join(name); - Command::new("cryptsetup") - .arg("-q") - .arg("luksFormat") - .arg(format!("--key-file={}", PASSWORD_PATH)) - .arg(format!("--keyfile-size={}", password.len())) - .arg(&crypt_path) - .invoke(crate::ErrorKind::DiskManagement) - .await?; - Command::new("cryptsetup") - .arg("-q") - .arg("luksOpen") - .arg(format!("--key-file={}", PASSWORD_PATH)) - .arg(format!("--keyfile-size={}", password.len())) - .arg(&crypt_path) - .arg(format!("{}_{}", guid, name)) - .invoke(crate::ErrorKind::DiskManagement) - .await?; + let mut blockdev_path = Path::new("/dev").join(guid).join(name); + if let Some(password) = password { + if let Some(parent) = Path::new(PASSWORD_PATH).parent() { + tokio::fs::create_dir_all(parent).await?; + } + tokio::fs::write(PASSWORD_PATH, password) + .await + .with_ctx(|_| (crate::ErrorKind::Filesystem, PASSWORD_PATH))?; + Command::new("cryptsetup") + .arg("-q") + .arg("luksFormat") + .arg(format!("--key-file={}", PASSWORD_PATH)) + .arg(format!("--keyfile-size={}", password.len())) + .arg(&blockdev_path) + .invoke(crate::ErrorKind::DiskManagement) + .await?; + Command::new("cryptsetup") + .arg("-q") + .arg("luksOpen") + .arg(format!("--key-file={}", PASSWORD_PATH)) + .arg(format!("--keyfile-size={}", password.len())) + .arg(&blockdev_path) + .arg(format!("{}_{}", guid, name)) + .invoke(crate::ErrorKind::DiskManagement) + .await?; + tokio::fs::remove_file(PASSWORD_PATH) + .await + .with_ctx(|_| (crate::ErrorKind::Filesystem, PASSWORD_PATH))?; + blockdev_path = Path::new("/dev/mapper").join(format!("{}_{}", guid, name)); + } Command::new("mkfs.btrfs") - .arg(Path::new("/dev/mapper").join(format!("{}_{}", guid, name))) + .arg(&blockdev_path) .invoke(crate::ErrorKind::DiskManagement) .await?; - mount( - Path::new("/dev/mapper").join(format!("{}_{}", guid, name)), - datadir.as_ref().join(name), - ReadWrite, - ) - .await?; - tokio::fs::remove_file(PASSWORD_PATH) - .await - .with_ctx(|_| (crate::ErrorKind::Filesystem, PASSWORD_PATH))?; + mount(&blockdev_path, datadir.as_ref().join(name), ReadWrite).await?; Ok(()) } @@ -144,7 +149,7 @@ pub async fn create_fs>( pub async fn create_all_fs>( guid: &str, datadir: P, - password: &str, + password: Option<&str>, ) -> Result<(), Error> { create_fs(guid, &datadir, "main", MAIN_FS_SIZE, password).await?; create_fs( @@ -161,12 +166,14 @@ pub async fn create_all_fs>( #[instrument(skip_all)] pub async fn unmount_fs>(guid: &str, datadir: P, name: &str) -> Result<(), Error> { unmount(datadir.as_ref().join(name)).await?; - Command::new("cryptsetup") - .arg("-q") - .arg("luksClose") - .arg(format!("{}_{}", guid, name)) - .invoke(crate::ErrorKind::DiskManagement) - .await?; + if !guid.ends_with("_UNENC") { + Command::new("cryptsetup") + .arg("-q") + .arg("luksClose") + .arg(format!("{}_{}", guid, name)) + .invoke(crate::ErrorKind::DiskManagement) + .await?; + } Ok(()) } @@ -203,7 +210,7 @@ pub async fn import>( guid: &str, datadir: P, repair: RepairStrategy, - password: &str, + password: Option<&str>, ) -> Result { let scan = pvscan().await?; if scan @@ -261,46 +268,56 @@ pub async fn mount_fs>( datadir: P, name: &str, repair: RepairStrategy, - password: &str, + password: Option<&str>, ) -> Result { - tokio::fs::write(PASSWORD_PATH, password) - .await - .with_ctx(|_| (crate::ErrorKind::Filesystem, PASSWORD_PATH))?; - let crypt_path = Path::new("/dev").join(guid).join(name); + let orig_path = Path::new("/dev").join(guid).join(name); + let mut blockdev_path = orig_path.clone(); let full_name = format!("{}_{}", guid, name); - Command::new("cryptsetup") - .arg("-q") - .arg("luksOpen") - .arg(format!("--key-file={}", PASSWORD_PATH)) - .arg(format!("--keyfile-size={}", password.len())) - .arg(&crypt_path) - .arg(&full_name) - .invoke(crate::ErrorKind::DiskManagement) - .await?; - let mapper_path = Path::new("/dev/mapper").join(&full_name); - let reboot = repair.fsck(&mapper_path).await?; - // Backup LUKS header if e2fsck succeeded - let luks_folder = Path::new("/media/embassy/config/luks"); - tokio::fs::create_dir_all(luks_folder).await?; - let tmp_luks_bak = luks_folder.join(format!(".{full_name}.luks.bak.tmp")); - if tokio::fs::metadata(&tmp_luks_bak).await.is_ok() { - tokio::fs::remove_file(&tmp_luks_bak).await?; + if !guid.ends_with("_UNENC") { + let password = password.unwrap_or(DEFAULT_PASSWORD); + if let Some(parent) = Path::new(PASSWORD_PATH).parent() { + tokio::fs::create_dir_all(parent).await?; + } + tokio::fs::write(PASSWORD_PATH, password) + .await + .with_ctx(|_| (crate::ErrorKind::Filesystem, PASSWORD_PATH))?; + Command::new("cryptsetup") + .arg("-q") + .arg("luksOpen") + .arg(format!("--key-file={}", PASSWORD_PATH)) + .arg(format!("--keyfile-size={}", password.len())) + .arg(&blockdev_path) + .arg(&full_name) + .invoke(crate::ErrorKind::DiskManagement) + .await?; + tokio::fs::remove_file(PASSWORD_PATH) + .await + .with_ctx(|_| (crate::ErrorKind::Filesystem, PASSWORD_PATH))?; + blockdev_path = Path::new("/dev/mapper").join(&full_name); } - let luks_bak = luks_folder.join(format!("{full_name}.luks.bak")); - Command::new("cryptsetup") - .arg("-q") - .arg("luksHeaderBackup") - .arg("--header-backup-file") - .arg(&tmp_luks_bak) - .arg(&crypt_path) - .invoke(crate::ErrorKind::DiskManagement) - .await?; - tokio::fs::rename(&tmp_luks_bak, &luks_bak).await?; - mount(&mapper_path, datadir.as_ref().join(name), ReadWrite).await?; + let reboot = repair.fsck(&blockdev_path).await?; - tokio::fs::remove_file(PASSWORD_PATH) - .await - .with_ctx(|_| (crate::ErrorKind::Filesystem, PASSWORD_PATH))?; + if !guid.ends_with("_UNENC") { + // Backup LUKS header if e2fsck succeeded + let luks_folder = Path::new("/media/embassy/config/luks"); + tokio::fs::create_dir_all(luks_folder).await?; + let tmp_luks_bak = luks_folder.join(format!(".{full_name}.luks.bak.tmp")); + if tokio::fs::metadata(&tmp_luks_bak).await.is_ok() { + tokio::fs::remove_file(&tmp_luks_bak).await?; + } + let luks_bak = luks_folder.join(format!("{full_name}.luks.bak")); + Command::new("cryptsetup") + .arg("-q") + .arg("luksHeaderBackup") + .arg("--header-backup-file") + .arg(&tmp_luks_bak) + .arg(&orig_path) + .invoke(crate::ErrorKind::DiskManagement) + .await?; + tokio::fs::rename(&tmp_luks_bak, &luks_bak).await?; + } + + mount(&blockdev_path, datadir.as_ref().join(name), ReadWrite).await?; Ok(reboot) } @@ -310,7 +327,7 @@ pub async fn mount_all_fs>( guid: &str, datadir: P, repair: RepairStrategy, - password: &str, + password: Option<&str>, ) -> Result { let mut reboot = RequiresReboot(false); reboot |= mount_fs(guid, &datadir, "main", repair, password).await?; diff --git a/backend/src/disk/mount/filesystem/cifs.rs b/backend/src/disk/mount/filesystem/cifs.rs index 7dfcb207d..c456bce63 100644 --- a/backend/src/disk/mount/filesystem/cifs.rs +++ b/backend/src/disk/mount/filesystem/cifs.rs @@ -16,6 +16,9 @@ use crate::util::Invoke; use crate::Error; async fn resolve_hostname(hostname: &str) -> Result { + if let Ok(addr) = hostname.parse() { + return Ok(addr); + } #[cfg(feature = "avahi")] if hostname.ends_with(".local") { return Ok(IpAddr::V4(crate::net::mdns::resolve_mdns(hostname).await?)); diff --git a/backend/src/disk/util.rs b/backend/src/disk/util.rs index 282edc380..27b2bb5f0 100644 --- a/backend/src/disk/util.rs +++ b/backend/src/disk/util.rs @@ -324,11 +324,13 @@ pub async fn list(os: &OsPartitionInfo) -> Result, Error> { if index.internal { for part in index.parts { let mut disk_info = disk_info(disk.clone()).await; - disk_info.logicalname = part; + let part_info = part_info(part).await; + disk_info.logicalname = part_info.logicalname.clone(); + disk_info.capacity = part_info.capacity; if let Some(g) = disk_guids.get(&disk_info.logicalname) { disk_info.guid = g.clone(); } else { - disk_info.partitions = vec![part_info(disk_info.logicalname.clone()).await]; + disk_info.partitions = vec![part_info]; } res.push(disk_info); } diff --git a/backend/src/lib.rs b/backend/src/lib.rs index a5b64164e..4e4b1619a 100644 --- a/backend/src/lib.rs +++ b/backend/src/lib.rs @@ -17,6 +17,7 @@ pub mod account; pub mod action; pub mod auth; pub mod backup; +pub mod bins; pub mod config; pub mod context; pub mod control; diff --git a/backend/src/main.rs b/backend/src/main.rs new file mode 100644 index 000000000..371cd5e7d --- /dev/null +++ b/backend/src/main.rs @@ -0,0 +1,3 @@ +fn main() { + startos::bins::startbox() +} diff --git a/backend/src/manager/mod.rs b/backend/src/manager/mod.rs index 1eef05d2e..f08fc6d67 100644 --- a/backend/src/manager/mod.rs +++ b/backend/src/manager/mod.rs @@ -39,6 +39,7 @@ use crate::disk::mount::backup::BackupMountGuard; use crate::disk::mount::guard::TmpMountGuard; use crate::install::cleanup::remove_from_current_dependents_lists; use crate::net::net_controller::NetService; +use crate::net::vhost::AlpnInfo; use crate::procedure::docker::{DockerContainer, DockerProcedure, LongRunning}; use crate::procedure::{NoOutput, ProcedureName}; use crate::s9pk::manifest::Manifest; @@ -824,8 +825,14 @@ async fn add_network_for_main( let mut tx = secrets.begin().await?; for (id, interface) in &seed.manifest.interfaces.0 { for (external, internal) in interface.lan_config.iter().flatten() { - svc.add_lan(&mut tx, id.clone(), external.0, internal.internal, false) - .await?; + svc.add_lan( + &mut tx, + id.clone(), + external.0, + internal.internal, + Err(AlpnInfo::Specified(vec![])), + ) + .await?; } for (external, internal) in interface.tor_config.iter().flat_map(|t| &t.port_mapping) { svc.add_tor(&mut tx, id.clone(), external.0, internal.0) diff --git a/backend/src/net/net_controller.rs b/backend/src/net/net_controller.rs index 22afbdd6d..32ceaeace 100644 --- a/backend/src/net/net_controller.rs +++ b/backend/src/net/net_controller.rs @@ -17,7 +17,7 @@ use crate::net::keys::Key; use crate::net::mdns::MdnsController; use crate::net::ssl::{export_cert, export_key, SslManager}; use crate::net::tor::TorController; -use crate::net::vhost::VHostController; +use crate::net::vhost::{AlpnInfo, VHostController}; use crate::s9pk::manifest::PackageId; use crate::volume::cert_dir; use crate::{Error, HOST_IP}; @@ -59,6 +59,8 @@ impl NetController { } async fn add_os_bindings(&mut self, hostname: &Hostname, key: &Key) -> Result<(), Error> { + let alpn = Err(AlpnInfo::Specified(vec!["http/1.1".into(), "h2".into()])); + // Internal DNS self.vhost .add( @@ -66,7 +68,7 @@ impl NetController { Some("embassy".into()), 443, ([127, 0, 0, 1], 80).into(), - false, + alpn.clone(), ) .await?; self.os_bindings @@ -75,7 +77,13 @@ impl NetController { // LAN IP self.os_bindings.push( self.vhost - .add(key.clone(), None, 443, ([127, 0, 0, 1], 80).into(), false) + .add( + key.clone(), + None, + 443, + ([127, 0, 0, 1], 80).into(), + alpn.clone(), + ) .await?, ); @@ -87,7 +95,7 @@ impl NetController { Some("localhost".into()), 443, ([127, 0, 0, 1], 80).into(), - false, + alpn.clone(), ) .await?, ); @@ -98,7 +106,7 @@ impl NetController { Some(hostname.no_dot_host_name()), 443, ([127, 0, 0, 1], 80).into(), - false, + alpn.clone(), ) .await?, ); @@ -111,7 +119,7 @@ impl NetController { Some(hostname.local_domain_name()), 443, ([127, 0, 0, 1], 80).into(), - false, + alpn.clone(), ) .await?, ); @@ -131,7 +139,7 @@ impl NetController { Some(key.tor_address().to_string()), 443, ([127, 0, 0, 1], 80).into(), - false, + alpn.clone(), ) .await?, ); @@ -184,7 +192,7 @@ impl NetController { key: Key, external: u16, target: SocketAddr, - connect_ssl: bool, + connect_ssl: Result<(), AlpnInfo>, ) -> Result>, Error> { let mut rcs = Vec::with_capacity(2); rcs.push( @@ -278,8 +286,8 @@ impl NetService { id: InterfaceId, external: u16, internal: u16, - connect_ssl: bool, - ) -> Result + connect_ssl: Result<(), AlpnInfo>, + ) -> Result<(), Error> where for<'a> &'a mut Ex: PgExecutor<'a>, { diff --git a/backend/src/net/static_server.rs b/backend/src/net/static_server.rs index 616cd2f39..e640d49e9 100644 --- a/backend/src/net/static_server.rs +++ b/backend/src/net/static_server.rs @@ -1,16 +1,19 @@ +use std::borrow::Cow; use std::fs::Metadata; -use std::path::Path; +use std::path::{Path, PathBuf}; use std::sync::Arc; use std::time::UNIX_EPOCH; -use async_compression::tokio::bufread::{BrotliEncoder, GzipEncoder}; +use async_compression::tokio::bufread::GzipEncoder; use color_eyre::eyre::eyre; use digest::Digest; use futures::FutureExt; -use http::header::{ACCEPT_ENCODING, CONTENT_ENCODING}; +use http::header::ACCEPT_ENCODING; use http::request::Parts as RequestParts; use http::response::Builder; use hyper::{Body, Method, Request, Response, StatusCode}; +use include_dir::{include_dir, Dir}; +use new_mime_guess::MimeGuess; use openssl::hash::MessageDigest; use openssl::x509::X509; use rpc_toolkit::rpc_handler; @@ -33,10 +36,7 @@ static NOT_FOUND: &[u8] = b"Not Found"; static METHOD_NOT_ALLOWED: &[u8] = b"Method Not Allowed"; static NOT_AUTHORIZED: &[u8] = b"Not Authorized"; -pub const MAIN_UI_WWW_DIR: &str = "/var/www/html/main"; -pub const SETUP_UI_WWW_DIR: &str = "/var/www/html/setup"; -pub const DIAG_UI_WWW_DIR: &str = "/var/www/html/diagnostic"; -pub const INSTALL_UI_WWW_DIR: &str = "/var/www/html/install"; +static EMBEDDED_UIS: Dir<'_> = include_dir!("$CARGO_MANIFEST_DIR/../frontend/dist/static"); fn status_fn(_: i32) -> StatusCode { StatusCode::OK @@ -50,6 +50,17 @@ pub enum UiMode { Main, } +impl UiMode { + fn path(&self, path: &str) -> PathBuf { + match self { + Self::Setup => Path::new("setup-wizard").join(path), + Self::Diag => Path::new("diagnostic-ui").join(path), + Self::Install => Path::new("install-wizard").join(path), + Self::Main => Path::new("ui").join(path), + } + } +} + pub async fn setup_ui_file_router(ctx: SetupContext) -> Result { let handler: HttpHandler = Arc::new(move |req| { let ctx = ctx.clone(); @@ -224,13 +235,6 @@ pub async fn main_ui_server_router(ctx: RpcContext) -> Result, ui_mode: UiMode) -> Result, Error> { - let selected_root_dir = match ui_mode { - UiMode::Setup => SETUP_UI_WWW_DIR, - UiMode::Diag => DIAG_UI_WWW_DIR, - UiMode::Install => INSTALL_UI_WWW_DIR, - UiMode::Main => MAIN_UI_WWW_DIR, - }; - let (request_parts, _body) = req.into_parts(); let accept_encoding = request_parts .headers @@ -243,46 +247,32 @@ async fn alt_ui(req: Request, ui_mode: UiMode) -> Result, E .collect::>(); match &request_parts.method { &Method::GET => { - let uri_path = request_parts - .uri - .path() - .strip_prefix('/') - .unwrap_or(request_parts.uri.path()); + let uri_path = ui_mode.path( + request_parts + .uri + .path() + .strip_prefix('/') + .unwrap_or(request_parts.uri.path()), + ); - let full_path = Path::new(selected_root_dir).join(uri_path); - file_send( - &request_parts, - if tokio::fs::metadata(&full_path) + let file = EMBEDDED_UIS + .get_file(&*uri_path) + .or_else(|| EMBEDDED_UIS.get_file(&*ui_mode.path("index.html"))); + + if let Some(file) = file { + FileData::from_embedded(&request_parts, file) + .into_response(&request_parts) .await - .ok() - .map(|f| f.is_file()) - .unwrap_or(false) - { - full_path - } else { - Path::new(selected_root_dir).join("index.html") - }, - &accept_encoding, - ) - .await + } else { + Ok(not_found()) + } } _ => Ok(method_not_allowed()), } } async fn main_embassy_ui(req: Request, ctx: RpcContext) -> Result, Error> { - let selected_root_dir = MAIN_UI_WWW_DIR; - let (request_parts, _body) = req.into_parts(); - let accept_encoding = request_parts - .headers - .get_all(ACCEPT_ENCODING) - .into_iter() - .filter_map(|h| h.to_str().ok()) - .flat_map(|s| s.split(",")) - .filter_map(|s| s.split(";").next()) - .map(|s| s.trim()) - .collect::>(); match ( &request_parts.method, request_parts @@ -297,11 +287,12 @@ async fn main_embassy_ui(req: Request, ctx: RpcContext) -> Result { let sub_path = Path::new(path); if let Ok(rest) = sub_path.strip_prefix("package-data") { - file_send( + FileData::from_path( &request_parts, - ctx.datadir.join(PKG_PUBLIC_DIR).join(rest), - &accept_encoding, + &ctx.datadir.join(PKG_PUBLIC_DIR).join(rest), ) + .await? + .into_response(&request_parts) .await } else if let Ok(rest) = sub_path.strip_prefix("eos") { match rest.to_str() { @@ -323,28 +314,25 @@ async fn main_embassy_ui(req: Request, ctx: RpcContext) -> Result { - let uri_path = request_parts - .uri - .path() - .strip_prefix('/') - .unwrap_or(request_parts.uri.path()); + let uri_path = UiMode::Main.path( + request_parts + .uri + .path() + .strip_prefix('/') + .unwrap_or(request_parts.uri.path()), + ); - let full_path = Path::new(selected_root_dir).join(uri_path); - file_send( - &request_parts, - if tokio::fs::metadata(&full_path) + let file = EMBEDDED_UIS + .get_file(&*uri_path) + .or_else(|| EMBEDDED_UIS.get_file(&*UiMode::Main.path("index.html"))); + + if let Some(file) = file { + FileData::from_embedded(&request_parts, file) + .into_response(&request_parts) .await - .ok() - .map(|f| f.is_file()) - .unwrap_or(false) - { - full_path - } else { - Path::new(selected_root_dir).join("index.html") - }, - &accept_encoding, - ) - .await + } else { + Ok(not_found()) + } } _ => Ok(method_not_allowed()), } @@ -407,118 +395,163 @@ fn cert_send(cert: &X509) -> Result, Error> { .with_kind(ErrorKind::Network) } -async fn file_send( - req: &RequestParts, - path: impl AsRef, - accept_encoding: &[&str], -) -> Result, Error> { - // Serve a file by asynchronously reading it by chunks using tokio-util crate. +struct FileData { + data: Body, + len: Option, + encoding: Option<&'static str>, + e_tag: String, + mime: Option, +} +impl FileData { + fn from_embedded(req: &RequestParts, file: &'static include_dir::File<'static>) -> Self { + let path = file.path(); + let (encoding, data) = req + .headers + .get_all(ACCEPT_ENCODING) + .into_iter() + .filter_map(|h| h.to_str().ok()) + .flat_map(|s| s.split(",")) + .filter_map(|s| s.split(";").next()) + .map(|s| s.trim()) + .fold((None, file.contents()), |acc, e| { + if let Some(file) = (e == "br") + .then_some(()) + .and_then(|_| EMBEDDED_UIS.get_file(format!("{}.br", path.display()))) + { + (Some("br"), file.contents()) + } else if let Some(file) = (e == "gzip" && acc.0 != Some("br")) + .then_some(()) + .and_then(|_| EMBEDDED_UIS.get_file(format!("{}.gz", path.display()))) + { + (Some("gzip"), file.contents()) + } else { + acc + } + }); - let path = path.as_ref(); - - let file = File::open(path) - .await - .with_ctx(|_| (ErrorKind::Filesystem, path.display().to_string()))?; - let metadata = file - .metadata() - .await - .with_ctx(|_| (ErrorKind::Filesystem, path.display().to_string()))?; - - let e_tag = e_tag(path, &metadata)?; - - let mut builder = Response::builder(); - builder = with_content_type(path, builder); - builder = builder.header(http::header::ETAG, &e_tag); - builder = builder.header( - http::header::CACHE_CONTROL, - "public, max-age=21000000, immutable", - ); - - if req - .headers - .get_all(http::header::CONNECTION) - .iter() - .flat_map(|s| s.to_str().ok()) - .flat_map(|s| s.split(",")) - .any(|s| s.trim() == "keep-alive") - { - builder = builder.header(http::header::CONNECTION, "keep-alive"); + Self { + len: Some(data.len() as u64), + encoding, + data: data.into(), + e_tag: e_tag(path, None), + mime: MimeGuess::from_path(path) + .first() + .map(|m| m.essence_str().to_owned()), + } } - if req - .headers - .get("if-none-match") - .and_then(|h| h.to_str().ok()) - == Some(e_tag.as_str()) - { - builder = builder.status(StatusCode::NOT_MODIFIED); - builder.body(Body::empty()) - } else { - let body = if false && accept_encoding.contains(&"br") && metadata.len() > u16::MAX as u64 { - builder = builder.header(CONTENT_ENCODING, "br"); - Body::wrap_stream(ReaderStream::new(BrotliEncoder::new(BufReader::new(file)))) - } else if accept_encoding.contains(&"gzip") && metadata.len() > u16::MAX as u64 { - builder = builder.header(CONTENT_ENCODING, "gzip"); - Body::wrap_stream(ReaderStream::new(GzipEncoder::new(BufReader::new(file)))) + async fn from_path(req: &RequestParts, path: &Path) -> Result { + let encoding = req + .headers + .get_all(ACCEPT_ENCODING) + .into_iter() + .filter_map(|h| h.to_str().ok()) + .flat_map(|s| s.split(",")) + .filter_map(|s| s.split(";").next()) + .map(|s| s.trim()) + .any(|e| e == "gzip") + .then_some("gzip"); + + let file = File::open(path) + .await + .with_ctx(|_| (ErrorKind::Filesystem, path.display().to_string()))?; + let metadata = file + .metadata() + .await + .with_ctx(|_| (ErrorKind::Filesystem, path.display().to_string()))?; + + let e_tag = e_tag(path, Some(&metadata)); + + let (len, data) = if encoding == Some("gzip") { + ( + None, + Body::wrap_stream(ReaderStream::new(GzipEncoder::new(BufReader::new(file)))), + ) } else { - builder = with_content_length(&metadata, builder); - Body::wrap_stream(ReaderStream::new(file)) + ( + Some(metadata.len()), + Body::wrap_stream(ReaderStream::new(file)), + ) }; - builder.body(body) + + Ok(Self { + data, + len, + encoding, + e_tag, + mime: MimeGuess::from_path(path) + .first() + .map(|m| m.essence_str().to_owned()), + }) + } + + async fn into_response(self, req: &RequestParts) -> Result, Error> { + let mut builder = Response::builder(); + if let Some(mime) = self.mime { + builder = builder.header(http::header::CONTENT_TYPE, &*mime); + } + builder = builder.header(http::header::ETAG, &*self.e_tag); + builder = builder.header( + http::header::CACHE_CONTROL, + "public, max-age=21000000, immutable", + ); + + if req + .headers + .get_all(http::header::CONNECTION) + .iter() + .flat_map(|s| s.to_str().ok()) + .flat_map(|s| s.split(",")) + .any(|s| s.trim() == "keep-alive") + { + builder = builder.header(http::header::CONNECTION, "keep-alive"); + } + + if req + .headers + .get("if-none-match") + .and_then(|h| h.to_str().ok()) + == Some(self.e_tag.as_ref()) + { + builder = builder.status(StatusCode::NOT_MODIFIED); + builder.body(Body::empty()) + } else { + if let Some(len) = self.len { + builder = builder.header(http::header::CONTENT_LENGTH, len); + } + if let Some(encoding) = self.encoding { + builder = builder.header(http::header::CONTENT_ENCODING, encoding); + } + + builder.body(self.data) + } + .with_kind(ErrorKind::Network) } - .with_kind(ErrorKind::Network) } -fn e_tag(path: &Path, metadata: &Metadata) -> Result { - let modified = metadata.modified().with_kind(ErrorKind::Filesystem)?; +fn e_tag(path: &Path, metadata: Option<&Metadata>) -> String { let mut hasher = sha2::Sha256::new(); hasher.update(format!("{:?}", path).as_bytes()); - hasher.update( - format!( - "{}", - modified - .duration_since(UNIX_EPOCH) - .unwrap_or_default() - .as_secs() - ) - .as_bytes(), - ); + if let Some(modified) = metadata.and_then(|m| m.modified().ok()) { + hasher.update( + format!( + "{}", + modified + .duration_since(UNIX_EPOCH) + .unwrap_or_default() + .as_secs() + ) + .as_bytes(), + ); + } let res = hasher.finalize(); - Ok(format!( + format!( "\"{}\"", base32::encode(base32::Alphabet::RFC4648 { padding: false }, res.as_slice()).to_lowercase() - )) + ) } -///https://en.wikipedia.org/wiki/Media_type -fn with_content_type(path: &Path, builder: Builder) -> Builder { - let content_type = match path.extension() { - Some(os_str) => match os_str.to_str() { - Some("apng") => "image/apng", - Some("avif") => "image/avif", - Some("flif") => "image/flif", - Some("gif") => "image/gif", - Some("jpg") | Some("jpeg") | Some("jfif") | Some("pjpeg") | Some("pjp") => "image/jpeg", - Some("jxl") => "image/jxl", - Some("png") => "image/png", - Some("svg") => "image/svg+xml", - Some("webp") => "image/webp", - Some("mng") | Some("x-mng") => "image/x-mng", - Some("css") => "text/css", - Some("csv") => "text/csv", - Some("html") => "text/html", - Some("php") => "text/php", - Some("plain") | Some("md") | Some("txt") => "text/plain", - Some("xml") => "text/xml", - Some("js") => "text/javascript", - Some("wasm") => "application/wasm", - None | Some(_) => "text/plain", - }, - None => "text/plain", - }; - builder.header(http::header::CONTENT_TYPE, content_type) -} - -fn with_content_length(metadata: &Metadata, builder: Builder) -> Builder { - builder.header(http::header::CONTENT_LENGTH, metadata.len()) +#[test] +fn test_packed_html() { + assert!(MainUi::get("index.html").is_some()) } diff --git a/backend/src/net/vhost.rs b/backend/src/net/vhost.rs index 840acafb0..e8e754baf 100644 --- a/backend/src/net/vhost.rs +++ b/backend/src/net/vhost.rs @@ -3,6 +3,7 @@ use std::convert::Infallible; use std::net::{IpAddr, Ipv6Addr, SocketAddr}; use std::str::FromStr; use std::sync::{Arc, Weak}; +use std::time::Duration; use color_eyre::eyre::eyre; use helpers::NonDetachingJoinHandle; @@ -19,7 +20,7 @@ use tokio_rustls::{LazyConfigAcceptor, TlsConnector}; use crate::net::keys::Key; use crate::net::ssl::SslManager; use crate::net::utils::SingleAccept; -use crate::util::io::BackTrackingReader; +use crate::util::io::{BackTrackingReader, TimeoutStream}; use crate::Error; // not allowed: <=1024, >=32768, 5355, 5432, 9050, 6010, 9051, 5353 @@ -41,7 +42,7 @@ impl VHostController { hostname: Option, external: u16, target: SocketAddr, - connect_ssl: bool, + connect_ssl: Result<(), AlpnInfo>, ) -> Result, Error> { let mut writable = self.servers.lock().await; let server = if let Some(server) = writable.remove(&external) { @@ -77,10 +78,16 @@ impl VHostController { #[derive(Clone, PartialEq, Eq, PartialOrd, Ord)] struct TargetInfo { addr: SocketAddr, - connect_ssl: bool, + connect_ssl: Result<(), AlpnInfo>, key: Key, } +#[derive(Clone, PartialEq, Eq, PartialOrd, Ord)] +pub enum AlpnInfo { + Reflect, + Specified(Vec>), +} + struct VHostServer { mapping: Weak, BTreeMap>>>>, _thread: NonDetachingJoinHandle<()>, @@ -98,6 +105,8 @@ impl VHostServer { loop { match listener.accept().await { Ok((stream, _)) => { + let stream = + Box::pin(TimeoutStream::new(stream, Duration::from_secs(300))); let mut stream = BackTrackingReader::new(stream); stream.start_buffering(); let mapping = mapping.clone(); @@ -178,7 +187,7 @@ impl VHostServer { let cfg = ServerConfig::builder() .with_safe_defaults() .with_no_client_auth(); - let cfg = + let mut cfg = if mid.client_hello().signature_schemes().contains( &tokio_rustls::rustls::SignatureScheme::ED25519, ) { @@ -213,49 +222,94 @@ impl VHostServer { .private_key_to_der()?, ), ) - }; - let mut tls_stream = mid - .into_stream(Arc::new( - cfg.with_kind(crate::ErrorKind::OpenSsl)?, - )) - .await?; - tls_stream.get_mut().0.stop_buffering(); - if target.connect_ssl { - tokio::io::copy_bidirectional( - &mut tls_stream, - &mut TlsConnector::from(Arc::new( + } + .with_kind(crate::ErrorKind::OpenSsl)?; + match target.connect_ssl { + Ok(()) => { + let mut client_cfg = tokio_rustls::rustls::ClientConfig::builder() .with_safe_defaults() .with_root_certificates({ let mut store = RootCertStore::empty(); store.add( - &tokio_rustls::rustls::Certificate( - key.root_ca().to_der()?, - ), - ).with_kind(crate::ErrorKind::OpenSsl)?; + &tokio_rustls::rustls::Certificate( + key.root_ca().to_der()?, + ), + ).with_kind(crate::ErrorKind::OpenSsl)?; store }) - .with_no_client_auth(), - )) - .connect( - key.key() - .internal_address() - .as_str() - .try_into() - .with_kind(crate::ErrorKind::OpenSsl)?, - tcp_stream, + .with_no_client_auth(); + client_cfg.alpn_protocols = mid + .client_hello() + .alpn() + .into_iter() + .flatten() + .map(|x| x.to_vec()) + .collect(); + let mut target_stream = + TlsConnector::from(Arc::new(client_cfg)) + .connect_with( + key.key() + .internal_address() + .as_str() + .try_into() + .with_kind( + crate::ErrorKind::OpenSsl, + )?, + tcp_stream, + |conn| { + cfg.alpn_protocols.extend( + conn.alpn_protocol() + .into_iter() + .map(|p| p.to_vec()), + ) + }, + ) + .await + .with_kind(crate::ErrorKind::OpenSsl)?; + let mut tls_stream = + mid.into_stream(Arc::new(cfg)).await?; + tls_stream.get_mut().0.stop_buffering(); + tokio::io::copy_bidirectional( + &mut tls_stream, + &mut target_stream, ) .await - .with_kind(crate::ErrorKind::OpenSsl)?, - ) - .await?; - } else { - tokio::io::copy_bidirectional( - &mut tls_stream, - &mut tcp_stream, - ) - .await?; + } + Err(AlpnInfo::Reflect) => { + for proto in + mid.client_hello().alpn().into_iter().flatten() + { + cfg.alpn_protocols.push(proto.into()); + } + let mut tls_stream = + mid.into_stream(Arc::new(cfg)).await?; + tls_stream.get_mut().0.stop_buffering(); + tokio::io::copy_bidirectional( + &mut tls_stream, + &mut tcp_stream, + ) + .await + } + Err(AlpnInfo::Specified(alpn)) => { + cfg.alpn_protocols = alpn; + let mut tls_stream = + mid.into_stream(Arc::new(cfg)).await?; + tls_stream.get_mut().0.stop_buffering(); + tokio::io::copy_bidirectional( + &mut tls_stream, + &mut tcp_stream, + ) + .await + } } + .map_or_else( + |e| match e.kind() { + std::io::ErrorKind::UnexpectedEof => Ok(()), + _ => Err(e), + }, + |_| Ok(()), + )?; } else { // 503 } diff --git a/backend/src/os_install/mod.rs b/backend/src/os_install/mod.rs index 3edfa2d97..19f320f06 100644 --- a/backend/src/os_install/mod.rs +++ b/backend/src/os_install/mod.rs @@ -149,29 +149,36 @@ pub async fn execute( if !overwrite { if let Ok(guard) = - TmpMountGuard::mount(&BlockDev::new(part_info.root.clone()), MountType::ReadOnly).await + TmpMountGuard::mount(&BlockDev::new(part_info.root.clone()), MountType::ReadWrite).await { if let Err(e) = async { // cp -r ${guard}/config /tmp/config - Command::new("cp") - .arg("-r") - .arg(guard.as_ref().join("config")) - .arg("/tmp/config.bak") - .invoke(crate::ErrorKind::Filesystem) - .await?; if tokio::fs::metadata(guard.as_ref().join("config/upgrade")) .await .is_ok() { tokio::fs::remove_file(guard.as_ref().join("config/upgrade")).await?; } - guard.unmount().await + if tokio::fs::metadata(guard.as_ref().join("config/disk.guid")) + .await + .is_ok() + { + tokio::fs::remove_file(guard.as_ref().join("config/disk.guid")).await?; + } + Command::new("cp") + .arg("-r") + .arg(guard.as_ref().join("config")) + .arg("/tmp/config.bak") + .invoke(crate::ErrorKind::Filesystem) + .await?; + Ok::<_, Error>(()) } .await { tracing::error!("Error recovering previous config: {e}"); tracing::debug!("{e:?}"); } + guard.unmount().await?; } } diff --git a/backend/src/setup.rs b/backend/src/setup.rs index 0ac21cce2..ea825cf63 100644 --- a/backend/src/setup.rs +++ b/backend/src/setup.rs @@ -1,9 +1,9 @@ -use std::path::PathBuf; +use std::path::{Path, PathBuf}; use std::sync::Arc; +use std::time::Duration; use color_eyre::eyre::eyre; use futures::StreamExt; -use helpers::{Rsync, RsyncOptions}; use josekit::jwk::Jwk; use openssl::x509::X509; use patch_db::DbHandle; @@ -13,6 +13,7 @@ use serde::{Deserialize, Serialize}; use sqlx::Connection; use tokio::fs::File; use tokio::io::AsyncWriteExt; +use tokio::try_join; use torut::onion::OnionAddressV3; use tracing::instrument; @@ -32,6 +33,7 @@ use crate::disk::REPAIR_DISK_PATH; use crate::hostname::Hostname; use crate::init::{init, InitResult}; use crate::middleware::encrypt::EncryptedWire; +use crate::util::io::{dir_copy, dir_size, Counter}; use crate::{Error, ErrorKind, ResultExt}; #[command(subcommands(status, disk, attach, execute, cifs, complete, get_pubkey, exit))] @@ -123,7 +125,7 @@ pub async fn attach( } else { RepairStrategy::Preen }, - DEFAULT_PASSWORD, + if guid.ends_with("_UNENC") { None } else { Some(DEFAULT_PASSWORD) }, ) .await?; if tokio::fs::metadata(REPAIR_DISK_PATH).await.is_ok() { @@ -142,7 +144,7 @@ pub async fn attach( } let (hostname, tor_addr, root_ca) = setup_init(&ctx, password).await?; *ctx.setup_result.write().await = Some((guid, SetupResult { - tor_address: format!("http://{}", tor_addr), + tor_address: format!("https://{}", tor_addr), lan_address: hostname.lan_address(), root_ca: String::from_utf8(root_ca.to_pem()?)?, })); @@ -279,7 +281,7 @@ pub async fn execute( *ctx.setup_result.write().await = Some(( guid, SetupResult { - tor_address: format!("http://{}", tor_addr), + tor_address: format!("https://{}", tor_addr), lan_address: hostname.lan_address(), root_ca: String::from_utf8( root_ca.to_pem().expect("failed to serialize root ca"), @@ -335,12 +337,17 @@ pub async fn execute_inner( recovery_source: Option, recovery_password: Option, ) -> Result<(Arc, Hostname, OnionAddressV3, X509), Error> { + let encryption_password = if ctx.disable_encryption { + None + } else { + Some(DEFAULT_PASSWORD) + }; let guid = Arc::new( crate::disk::main::create( &[embassy_logicalname], &pvscan().await?, &ctx.datadir, - DEFAULT_PASSWORD, + encryption_password, ) .await?, ); @@ -348,7 +355,7 @@ pub async fn execute_inner( &*guid, &ctx.datadir, RepairStrategy::Preen, - DEFAULT_PASSWORD, + encryption_password, ) .await?; @@ -416,74 +423,78 @@ async fn migrate( &old_guid, "/media/embassy/migrate", RepairStrategy::Preen, - DEFAULT_PASSWORD, - ) - .await?; - - let mut main_transfer = Rsync::new( - "/media/embassy/migrate/main/", - "/embassy-data/main/", - RsyncOptions { - delete: true, - force: true, - ignore_existing: false, - exclude: Vec::new(), - no_permissions: false, - no_owner: false, + if guid.ends_with("_UNENC") { + None + } else { + Some(DEFAULT_PASSWORD) }, ) .await?; - let mut package_data_transfer = Rsync::new( + + let main_transfer_args = ("/media/embassy/migrate/main/", "/embassy-data/main/"); + let package_data_transfer_args = ( "/media/embassy/migrate/package-data/", "/embassy-data/package-data/", - RsyncOptions { - delete: true, - force: true, - ignore_existing: false, - exclude: vec!["tmp".to_owned()], - no_permissions: false, - no_owner: false, - }, - ) - .await?; + ); - let mut main_prog = 0.0; - let mut main_complete = false; - let mut pkg_prog = 0.0; - let mut pkg_complete = false; - loop { - tokio::select! { - p = main_transfer.progress.next() => { - if let Some(p) = p { - main_prog = p; - } else { - main_prog = 1.0; - main_complete = true; - } - } - p = package_data_transfer.progress.next() => { - if let Some(p) = p { - pkg_prog = p; - } else { - pkg_prog = 1.0; - pkg_complete = true; - } - } - } - if main_prog > 0.0 && pkg_prog > 0.0 { - *ctx.setup_status.write().await = Some(Ok(SetupStatus { - bytes_transferred: ((main_prog * 50.0) + (pkg_prog * 950.0)) as u64, - total_bytes: Some(1000), - complete: false, - })); - } - if main_complete && pkg_complete { - break; - } + let tmpdir = Path::new(package_data_transfer_args.0).join("tmp"); + if tokio::fs::metadata(&tmpdir).await.is_ok() { + tokio::fs::remove_dir_all(&tmpdir).await?; } - main_transfer.wait().await?; - package_data_transfer.wait().await?; + let ordering = std::sync::atomic::Ordering::Relaxed; + + let main_transfer_size = Counter::new(0, ordering); + let package_data_transfer_size = Counter::new(0, ordering); + + let size = tokio::select! { + res = async { + let (main_size, package_data_size) = try_join!( + dir_size(main_transfer_args.0, Some(&main_transfer_size)), + dir_size(package_data_transfer_args.0, Some(&package_data_transfer_size)) + )?; + Ok::<_, Error>(main_size + package_data_size) + } => { res? }, + res = async { + loop { + tokio::time::sleep(Duration::from_secs(1)).await; + *ctx.setup_status.write().await = Some(Ok(SetupStatus { + bytes_transferred: 0, + total_bytes: Some(main_transfer_size.load() + package_data_transfer_size.load()), + complete: false, + })); + } + } => res, + }; + + *ctx.setup_status.write().await = Some(Ok(SetupStatus { + bytes_transferred: 0, + total_bytes: Some(size), + complete: false, + })); + + let main_transfer_progress = Counter::new(0, ordering); + let package_data_transfer_progress = Counter::new(0, ordering); + + tokio::select! { + res = async { + try_join!( + dir_copy(main_transfer_args.0, main_transfer_args.1, Some(&main_transfer_progress)), + dir_copy(package_data_transfer_args.0, package_data_transfer_args.1, Some(&package_data_transfer_progress)) + )?; + Ok::<_, Error>(()) + } => { res? }, + res = async { + loop { + tokio::time::sleep(Duration::from_secs(1)).await; + *ctx.setup_status.write().await = Some(Ok(SetupStatus { + bytes_transferred: main_transfer_progress.load() + package_data_transfer_progress.load(), + total_bytes: Some(size), + complete: false, + })); + } + } => res, + } let (hostname, tor_addr, root_ca) = setup_init(&ctx, Some(embassy_password)).await?; diff --git a/backend/src/system.rs b/backend/src/system.rs index c52eeb038..138e01fea 100644 --- a/backend/src/system.rs +++ b/backend/src/system.rs @@ -22,7 +22,7 @@ use crate::util::serde::{display_serializable, IoFormat}; use crate::util::{display_none, Invoke}; use crate::{Error, ErrorKind, ResultExt}; -pub const SYSTEMD_UNIT: &'static str = "embassyd"; +pub const SYSTEMD_UNIT: &'static str = "startd"; #[command(subcommands(zram))] pub async fn experimental() -> Result<(), Error> { diff --git a/backend/src/util/io.rs b/backend/src/util/io.rs index f96d7731a..ad831d14f 100644 --- a/backend/src/util/io.rs +++ b/backend/src/util/io.rs @@ -2,7 +2,9 @@ use std::future::Future; use std::io::Cursor; use std::os::unix::prelude::MetadataExt; use std::path::Path; +use std::sync::atomic::AtomicU64; use std::task::Poll; +use std::time::Duration; use futures::future::{BoxFuture, Fuse}; use futures::{AsyncSeek, FutureExt, TryStreamExt}; @@ -11,6 +13,8 @@ use nix::unistd::{Gid, Uid}; use tokio::io::{ duplex, AsyncRead, AsyncReadExt, AsyncWrite, AsyncWriteExt, DuplexStream, ReadBuf, WriteHalf, }; +use tokio::net::TcpStream; +use tokio::time::{Instant, Sleep}; use crate::ResultExt; @@ -224,6 +228,7 @@ pub async fn copy_and_shutdown( pub fn dir_size<'a, P: AsRef + 'a + Send + Sync>( path: P, + ctr: Option<&'a Counter>, ) -> BoxFuture<'a, Result> { async move { tokio_stream::wrappers::ReadDirStream::new(tokio::fs::read_dir(path.as_ref()).await?) @@ -231,9 +236,12 @@ pub fn dir_size<'a, P: AsRef + 'a + Send + Sync>( let m = e.metadata().await?; Ok(acc + if m.is_file() { + if let Some(ctr) = ctr { + ctr.add(m.len()); + } m.len() } else if m.is_dir() { - dir_size(e.path()).await? + dir_size(e.path(), ctr).await? } else { 0 }) @@ -419,9 +427,60 @@ impl AsyncWrite for BackTrackingReader { } } +pub struct Counter { + atomic: AtomicU64, + ordering: std::sync::atomic::Ordering, +} +impl Counter { + pub fn new(init: u64, ordering: std::sync::atomic::Ordering) -> Self { + Self { + atomic: AtomicU64::new(init), + ordering, + } + } + pub fn load(&self) -> u64 { + self.atomic.load(self.ordering) + } + pub fn add(&self, value: u64) { + self.atomic.fetch_add(value, self.ordering); + } +} + +#[pin_project::pin_project] +pub struct CountingReader<'a, R> { + ctr: &'a Counter, + #[pin] + rdr: R, +} +impl<'a, R> CountingReader<'a, R> { + pub fn new(rdr: R, ctr: &'a Counter) -> Self { + Self { ctr, rdr } + } + pub fn into_inner(self) -> R { + self.rdr + } +} +impl<'a, R: AsyncRead> AsyncRead for CountingReader<'a, R> { + fn poll_read( + self: std::pin::Pin<&mut Self>, + cx: &mut std::task::Context<'_>, + buf: &mut ReadBuf<'_>, + ) -> Poll> { + let this = self.project(); + let start = buf.filled().len(); + let res = this.rdr.poll_read(cx, buf); + let len = buf.filled().len() - start; + if len > 0 { + this.ctr.add(len as u64); + } + res + } +} + pub fn dir_copy<'a, P0: AsRef + 'a + Send + Sync, P1: AsRef + 'a + Send + Sync>( src: P0, dst: P1, + ctr: Option<&'a Counter>, ) -> BoxFuture<'a, Result<(), crate::Error>> { async move { let m = tokio::fs::metadata(&src).await?; @@ -464,23 +523,23 @@ pub fn dir_copy<'a, P0: AsRef + 'a + Send + Sync, P1: AsRef + 'a + S let dst_path = dst_path.join(e.file_name()); if m.is_file() { let len = m.len(); - let mut dst_file = - &mut tokio::fs::File::create(&dst_path).await.with_ctx(|_| { - ( - crate::ErrorKind::Filesystem, - format!("create {}", dst_path.display()), - ) - })?; - tokio::io::copy( - &mut tokio::fs::File::open(&src_path).await.with_ctx(|_| { - ( - crate::ErrorKind::Filesystem, - format!("open {}", src_path.display()), - ) - })?, - &mut dst_file, - ) - .await + let mut dst_file = tokio::fs::File::create(&dst_path).await.with_ctx(|_| { + ( + crate::ErrorKind::Filesystem, + format!("create {}", dst_path.display()), + ) + })?; + let mut rdr = tokio::fs::File::open(&src_path).await.with_ctx(|_| { + ( + crate::ErrorKind::Filesystem, + format!("open {}", src_path.display()), + ) + })?; + if let Some(ctr) = ctr { + tokio::io::copy(&mut CountingReader::new(rdr, ctr), &mut dst_file).await + } else { + tokio::io::copy(&mut rdr, &mut dst_file).await + } .with_ctx(|_| { ( crate::ErrorKind::Filesystem, @@ -508,7 +567,7 @@ pub fn dir_copy<'a, P0: AsRef + 'a + Send + Sync, P1: AsRef + 'a + S ) })?; } else if m.is_dir() { - dir_copy(src_path, dst_path).await?; + dir_copy(src_path, dst_path, ctr).await?; } else if m.file_type().is_symlink() { tokio::fs::symlink( tokio::fs::read_link(&src_path).await.with_ctx(|_| { @@ -535,3 +594,77 @@ pub fn dir_copy<'a, P0: AsRef + 'a + Send + Sync, P1: AsRef + 'a + S } .boxed() } + +#[pin_project::pin_project] +pub struct TimeoutStream { + timeout: Duration, + #[pin] + sleep: Sleep, + #[pin] + stream: S, +} +impl TimeoutStream { + pub fn new(stream: S, timeout: Duration) -> Self { + Self { + timeout, + sleep: tokio::time::sleep(timeout), + stream, + } + } +} +impl AsyncRead for TimeoutStream { + fn poll_read( + self: std::pin::Pin<&mut Self>, + cx: &mut std::task::Context<'_>, + buf: &mut tokio::io::ReadBuf<'_>, + ) -> std::task::Poll> { + let mut this = self.project(); + if let std::task::Poll::Ready(_) = this.sleep.as_mut().poll(cx) { + return std::task::Poll::Ready(Err(std::io::Error::new( + std::io::ErrorKind::TimedOut, + "timed out", + ))); + } + let res = this.stream.poll_read(cx, buf); + if res.is_ready() { + this.sleep.reset(Instant::now() + *this.timeout); + } + res + } +} +impl AsyncWrite for TimeoutStream { + fn poll_write( + self: std::pin::Pin<&mut Self>, + cx: &mut std::task::Context<'_>, + buf: &[u8], + ) -> std::task::Poll> { + let mut this = self.project(); + let res = this.stream.poll_write(cx, buf); + if res.is_ready() { + this.sleep.reset(Instant::now() + *this.timeout); + } + res + } + fn poll_flush( + self: std::pin::Pin<&mut Self>, + cx: &mut std::task::Context<'_>, + ) -> std::task::Poll> { + let mut this = self.project(); + let res = this.stream.poll_flush(cx); + if res.is_ready() { + this.sleep.reset(Instant::now() + *this.timeout); + } + res + } + fn poll_shutdown( + self: std::pin::Pin<&mut Self>, + cx: &mut std::task::Context<'_>, + ) -> std::task::Poll> { + let mut this = self.project(); + let res = this.stream.poll_shutdown(cx); + if res.is_ready() { + this.sleep.reset(Instant::now() + *this.timeout); + } + res + } +} diff --git a/backend/src/version/v0_3_4_4.rs b/backend/src/version/v0_3_4_4.rs new file mode 100644 index 000000000..1876ff700 --- /dev/null +++ b/backend/src/version/v0_3_4_4.rs @@ -0,0 +1,41 @@ +use async_trait::async_trait; +use emver::VersionRange; +use models::ResultExt; + +use super::v0_3_0::V0_3_0_COMPAT; +use super::*; + +const V0_3_4_4: emver::Version = emver::Version::new(0, 3, 4, 4); + +#[derive(Clone, Debug)] +pub struct Version; + +#[async_trait] +impl VersionT for Version { + type Previous = v0_3_4_3::Version; + fn new() -> Self { + Version + } + fn semver(&self) -> emver::Version { + V0_3_4_4 + } + fn compat(&self) -> &'static VersionRange { + &*V0_3_0_COMPAT + } + async fn up(&self, db: &mut Db, _secrets: &PgPool) -> Result<(), Error> { + let mut tor_addr = crate::db::DatabaseModel::new() + .server_info() + .tor_address() + .get_mut(db) + .await?; + tor_addr + .set_scheme("https") + .map_err(|_| eyre!("unable to update url scheme to https")) + .with_kind(crate::ErrorKind::ParseUrl)?; + tor_addr.save(db).await?; + Ok(()) + } + async fn down(&self, _db: &mut Db, _secrets: &PgPool) -> Result<(), Error> { + Ok(()) + } +} diff --git a/backend/startd.service b/backend/startd.service new file mode 100644 index 000000000..894298e54 --- /dev/null +++ b/backend/startd.service @@ -0,0 +1,19 @@ +[Unit] +Description=StartOS Daemon +After=network-online.target +Requires=network-online.target +Wants=avahi-daemon.service + +[Service] +Type=simple +Environment=RUST_LOG=startos=debug,js_engine=debug,patch_db=warn +ExecStart=/usr/bin/startd +Restart=always +RestartSec=3 +ManagedOOMPreference=avoid +CPUAccounting=true +CPUWeight=1000 +LimitNOFILE=65536 + +[Install] +WantedBy=multi-user.target diff --git a/backend/test/js_action_execute/package-data/scripts/test-package/0.3.0.3/embassy.js b/backend/test/js_action_execute/package-data/scripts/test-package/0.3.0.3/embassy.js index b9d9c009d..752051b9a 100644 --- a/backend/test/js_action_execute/package-data/scripts/test-package/0.3.0.3/embassy.js +++ b/backend/test/js_action_execute/package-data/scripts/test-package/0.3.0.3/embassy.js @@ -1145,7 +1145,14 @@ export const action = { async "test-disk-usage"(effects, _input) { const usage = await effects.diskUsage() - return usage + return { + result: { + copyable: false, + message: `${usage.used} / ${usage.total}`, + version: "0", + qr: false, + }, + }; } }; diff --git a/build/raspberrypi/config.yaml b/build/raspberrypi/config.yaml deleted file mode 100644 index cd242269f..000000000 --- a/build/raspberrypi/config.yaml +++ /dev/null @@ -1,5 +0,0 @@ -os-partitions: - boot: /dev/mmcblk0p1 - root: /dev/mmcblk0p2 -ethernet-interface: end0 -wifi-interface: wlan0 \ No newline at end of file diff --git a/compress-uis.sh b/compress-uis.sh new file mode 100755 index 000000000..964ddeb57 --- /dev/null +++ b/compress-uis.sh @@ -0,0 +1,22 @@ +#!/bin/bash + +set -e + +rm -rf frontend/dist/static + +find frontend/dist/raw -type f -not -name '*.gz' -and -not -name '*.br' | xargs -n 1 -P 0 gzip -kf +find frontend/dist/raw -type f -not -name '*.gz' -and -not -name '*.br' | xargs -n 1 -P 0 brotli -kf + +for file in $(find frontend/dist/raw -type f -not -name '*.gz' -and -not -name '*.br'); do + raw_size=$(du --bytes $file | awk '{print $1}') + gz_size=$(du --bytes $file.gz | awk '{print $1}') + br_size=$(du --bytes $file.br | awk '{print $1}') + if [ $((gz_size * 100 / raw_size)) -gt 70 ]; then + rm $file.gz + fi + if [ $((br_size * 100 / raw_size)) -gt 70 ]; then + rm $file.br + fi +done + +cp -r frontend/dist/raw frontend/dist/static \ No newline at end of file diff --git a/frontend/angular.json b/frontend/angular.json index dca324ac9..8bfaffae4 100644 --- a/frontend/angular.json +++ b/frontend/angular.json @@ -14,7 +14,7 @@ "builder": "@angular-devkit/build-angular:browser", "options": { "preserveSymlinks": true, - "outputPath": "dist/ui", + "outputPath": "dist/raw/ui", "index": "projects/ui/src/index.html", "main": "projects/ui/src/main.ts", "polyfills": "projects/ui/src/polyfills.ts", @@ -39,7 +39,7 @@ "projects/ui/src/manifest.webmanifest", { "glob": "ngsw.json", - "input": "dist/ui", + "input": "dist/raw/ui", "output": "projects/ui/src" }, { @@ -153,7 +153,7 @@ "build": { "builder": "@angular-devkit/build-angular:browser", "options": { - "outputPath": "dist/install-wizard", + "outputPath": "dist/raw/install-wizard", "index": "projects/install-wizard/src/index.html", "main": "projects/install-wizard/src/main.ts", "polyfills": "projects/install-wizard/src/polyfills.ts", @@ -283,7 +283,7 @@ "build": { "builder": "@angular-devkit/build-angular:browser", "options": { - "outputPath": "dist/setup-wizard", + "outputPath": "dist/raw/setup-wizard", "index": "projects/setup-wizard/src/index.html", "main": "projects/setup-wizard/src/main.ts", "polyfills": "projects/setup-wizard/src/polyfills.ts", @@ -403,7 +403,7 @@ "build": { "builder": "@angular-devkit/build-angular:browser", "options": { - "outputPath": "dist/diagnostic-ui", + "outputPath": "dist/raw/diagnostic-ui", "index": "projects/diagnostic-ui/src/index.html", "main": "projects/diagnostic-ui/src/main.ts", "polyfills": "projects/diagnostic-ui/src/polyfills.ts", diff --git a/frontend/package-lock.json b/frontend/package-lock.json index 8cbbe67d5..ffca74100 100644 --- a/frontend/package-lock.json +++ b/frontend/package-lock.json @@ -1,12 +1,12 @@ { "name": "startos-ui", - "version": "0.3.4.3", + "version": "0.3.4.4", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "startos-ui", - "version": "0.3.4.3", + "version": "0.3.4.4", "dependencies": { "@angular/animations": "^14.1.0", "@angular/common": "^14.1.0", diff --git a/frontend/package.json b/frontend/package.json index b92c8c172..359e3d607 100644 --- a/frontend/package.json +++ b/frontend/package.json @@ -1,6 +1,6 @@ { "name": "startos-ui", - "version": "0.3.4.3", + "version": "0.3.4.4", "author": "Start9 Labs, Inc", "homepage": "https://start9.com/", "scripts": { @@ -22,7 +22,7 @@ "build:all": "npm run build:deps && npm run build:dui && npm run build:setup && npm run build:ui && npm run build:install-wiz", "build:shared": "ng build shared", "build:marketplace": "npm run build:shared && ng build marketplace", - "analyze:ui": "webpack-bundle-analyzer dist/ui/stats.json", + "analyze:ui": "webpack-bundle-analyzer dist/raw/ui/stats.json", "publish:shared": "npm run build:shared && npm publish ./dist/shared --access public", "publish:marketplace": "npm run build:marketplace && npm publish ./dist/marketplace --access public", "start:dui": "npm run-script build-config && ionic serve --project diagnostic-ui --host 0.0.0.0", diff --git a/frontend/projects/setup-wizard/src/app/pages/embassy/embassy.page.ts b/frontend/projects/setup-wizard/src/app/pages/embassy/embassy.page.ts index 855051879..1a5dd042d 100644 --- a/frontend/projects/setup-wizard/src/app/pages/embassy/embassy.page.ts +++ b/frontend/projects/setup-wizard/src/app/pages/embassy/embassy.page.ts @@ -155,7 +155,6 @@ export class EmbassyPage { await this.navCtrl.navigateForward(`/loading`) } catch (e: any) { this.errorToastService.present(e) - console.error(e) } finally { loader.dismiss() } diff --git a/frontend/projects/setup-wizard/src/app/pages/success/download-doc/download-doc.component.html b/frontend/projects/setup-wizard/src/app/pages/success/download-doc/download-doc.component.html index 5598b4214..b7f76d477 100644 --- a/frontend/projects/setup-wizard/src/app/pages/success/download-doc/download-doc.component.html +++ b/frontend/projects/setup-wizard/src/app/pages/success/download-doc/download-doc.component.html @@ -27,31 +27,15 @@

-

- Access from home (LAN) -

-

- Visit the address below when you are connected to the same WiFi or - Local Area Network (LAN) as your server: -

-

- -

Important!

- Be sure to + Download your server's Root CA and follow the instructions - to establish a secure connection by installing your server's root - certificate authority. + to establish a secure connection with your server.

- -
+
+

+ Access from home (LAN) +

+

+ Visit the address below when you are connected to the same WiFi or + Local Area Network (LAN) as your server. +

+

+ +

-

Access on the go (Tor)

-

Visit the address below when you are away from home:

+

Visit the address below when you are away from home.

+

+ Note: + This address will only work from a Tor-enabled browser. + + Follow the instructions + + to get setup. +

-
-

Important!

-

- This address will only work from a Tor-enabled browser. - - Follow the instructions - - to get setup. -

-
diff --git a/frontend/projects/setup-wizard/src/app/pages/success/success.page.ts b/frontend/projects/setup-wizard/src/app/pages/success/success.page.ts index 4ea73e619..d9bdedd46 100644 --- a/frontend/projects/setup-wizard/src/app/pages/success/success.page.ts +++ b/frontend/projects/setup-wizard/src/app/pages/success/success.page.ts @@ -49,7 +49,7 @@ export class SuccessPage { const ret = await this.api.complete() if (!this.isKiosk) { this.torAddress = ret['tor-address'] - this.lanAddress = ret['lan-address'].replace('https', 'http') + this.lanAddress = ret['lan-address'].replace(/^https:/, 'http:') this.cert = ret['root-ca'] await this.api.exit() diff --git a/frontend/projects/setup-wizard/src/app/services/api/mock-api.service.ts b/frontend/projects/setup-wizard/src/app/services/api/mock-api.service.ts index c42ef4200..96730955e 100644 --- a/frontend/projects/setup-wizard/src/app/services/api/mock-api.service.ts +++ b/frontend/projects/setup-wizard/src/app/services/api/mock-api.service.ts @@ -7,10 +7,10 @@ import { } from '@start9labs/shared' import { ApiService, - CifsRecoverySource, AttachReq, - ExecuteReq, + CifsRecoverySource, CompleteRes, + ExecuteReq, } from './api.service' import * as jose from 'node-jose' import { interval, map, Observable } from 'rxjs' @@ -151,7 +151,7 @@ export class MockApiService extends ApiService { async complete(): Promise { await pauseFor(1000) return { - 'tor-address': 'http://asdafsadasdasasdasdfasdfasdf.onion', + 'tor-address': 'https://asdafsadasdasasdasdfasdfasdf.onion', 'lan-address': 'https://adjective-noun.local', 'root-ca': encodeBase64(rootCA), } diff --git a/frontend/projects/shared/assets/img/icon_apple_touch.png b/frontend/projects/shared/assets/img/icon_apple_touch.png new file mode 100644 index 000000000..3ca45d443 Binary files /dev/null and b/frontend/projects/shared/assets/img/icon_apple_touch.png differ diff --git a/frontend/projects/ui/src/app/app.component.ts b/frontend/projects/ui/src/app/app.component.ts index af049e130..5caa9bfab 100644 --- a/frontend/projects/ui/src/app/app.component.ts +++ b/frontend/projects/ui/src/app/app.component.ts @@ -38,7 +38,7 @@ export class AppComponent implements OnDestroy { readonly themeSwitcher: ThemeSwitcherService, ) {} - ngOnInit() { + async ngOnInit() { this.patch .watch$('ui', 'name') .subscribe(name => this.titleService.setTitle(name || 'StartOS')) diff --git a/frontend/projects/ui/src/app/app/preloader/preloader.component.ts b/frontend/projects/ui/src/app/app/preloader/preloader.component.ts index df0ae29b7..73f23898c 100644 --- a/frontend/projects/ui/src/app/app/preloader/preloader.component.ts +++ b/frontend/projects/ui/src/app/app/preloader/preloader.component.ts @@ -41,6 +41,7 @@ const ICONS = [ 'file-tray-stacked-outline', 'finger-print-outline', 'flash-outline', + 'flask-outline', 'flash-off-outline', 'folder-open-outline', 'globe-outline', @@ -48,7 +49,6 @@ const ICONS = [ 'hammer-outline', 'help-circle-outline', 'hammer-outline', - 'home-outline', 'information-circle-outline', 'key-outline', 'list-outline', @@ -76,6 +76,7 @@ const ICONS = [ 'remove-circle-outline', 'remove-outline', 'repeat-outline', + 'ribbon-outline', 'rocket-outline', 'save-outline', 'server-outline', diff --git a/frontend/projects/ui/src/app/apps/ui/pages/services/app-show/app-show.page.html b/frontend/projects/ui/src/app/apps/ui/pages/services/app-show/app-show.page.html index c0ca7224c..cbbaf402c 100644 --- a/frontend/projects/ui/src/app/apps/ui/pages/services/app-show/app-show.page.html +++ b/frontend/projects/ui/src/app/apps/ui/pages/services/app-show/app-show.page.html @@ -49,7 +49,6 @@ -

This page cannot safely be accessed over an insecure connection

diff --git a/frontend/projects/ui/src/app/apps/ui/pages/system/experimental-features/experimental-features.page.ts b/frontend/projects/ui/src/app/apps/ui/pages/system/experimental-features/experimental-features.page.ts index ae0025204..ed57066ab 100644 --- a/frontend/projects/ui/src/app/apps/ui/pages/system/experimental-features/experimental-features.page.ts +++ b/frontend/projects/ui/src/app/apps/ui/pages/system/experimental-features/experimental-features.page.ts @@ -43,9 +43,6 @@ export class ExperimentalFeaturesPage { label: 'Wipe state', type: 'checkbox', value: 'wipe', - handler: val => { - console.error(val) - }, }, ], buttons: [ @@ -56,8 +53,7 @@ export class ExperimentalFeaturesPage { { text: 'Reset', handler: (value: string[]) => { - console.error(value) - this.resetTor(value.some(v => 'wipe')) + this.resetTor(value.some(v => v === 'wipe')) }, cssClass: 'enter-click', }, diff --git a/frontend/projects/ui/src/app/apps/ui/pages/system/lan/lan.page.html b/frontend/projects/ui/src/app/apps/ui/pages/system/lan/lan.page.html index 5c11fea02..aa995a2af 100644 --- a/frontend/projects/ui/src/app/apps/ui/pages/system/lan/lan.page.html +++ b/frontend/projects/ui/src/app/apps/ui/pages/system/lan/lan.page.html @@ -1,6 +1,6 @@ - Secure LAN + Trust Root CA @@ -13,7 +13,7 @@

- For a secure local connection, + For a secure local connection and faster Tor experience, -

Download Certificate

+

Download Root CA

diff --git a/frontend/projects/ui/src/app/apps/ui/pages/system/server-show/server-show.page.ts b/frontend/projects/ui/src/app/apps/ui/pages/system/server-show/server-show.page.ts index 7dd200e63..7542687c4 100644 --- a/frontend/projects/ui/src/app/apps/ui/pages/system/server-show/server-show.page.ts +++ b/frontend/projects/ui/src/app/apps/ui/pages/system/server-show/server-show.page.ts @@ -1,10 +1,9 @@ -import { DOCUMENT } from '@angular/common' import { Component, Inject } from '@angular/core' import { AlertController, LoadingController, - NavController, ModalController, + NavController, ToastController, } from '@ionic/angular' import { ApiService } from 'src/app/services/api/embassy-api.service' @@ -23,6 +22,9 @@ import { GenericInputOptions, } from 'src/app/apps/ui/modals/generic-input/generic-input.component' import { ConfigService } from 'src/app/services/config.service' +import { DOCUMENT } from '@angular/common' +import { getServerInfo } from 'src/app/util/get-server-info' +import * as argon2 from '@start9labs/argon2' @Component({ selector: 'server-show', @@ -38,6 +40,8 @@ export class ServerShowPage { readonly showDiskRepair$ = this.ClientStorageService.showDiskRepair$ readonly secure = this.config.isSecure() + readonly isTorHttp = + this.config.isTor() && this.document.location.protocol === 'http:' constructor( private readonly alertCtrl: AlertController, @@ -94,7 +98,103 @@ export class ServerShowPage { await modal.present() } - private async updateEos(): Promise { + async presentAlertResetPassword() { + const alert = await this.alertCtrl.create({ + header: 'Warning', + message: + 'You will still need your current password to decrypt existing backups!', + buttons: [ + { + text: 'Cancel', + role: 'cancel', + }, + { + text: 'Continue', + handler: () => this.presentModalResetPassword(), + cssClass: 'enter-click', + }, + ], + cssClass: 'alert-warning-message', + }) + + await alert.present() + } + + async presentModalResetPassword(): Promise { + const modal = await this.modalCtrl.create({ + component: GenericFormPage, + componentProps: { + title: 'Change Master Password', + spec: PasswordSpec, + buttons: [ + { + text: 'Save', + handler: (value: any) => { + return this.resetPassword(value) + }, + isSubmit: true, + }, + ], + }, + }) + await modal.present() + } + + private async resetPassword(value: { + currPass: string + newPass: string + newPass2: string + }): Promise { + let err = '' + + if (value.newPass !== value.newPass2) { + err = 'New passwords do not match' + } else if (value.newPass.length < 12) { + err = 'New password must be 12 characters or greater' + } else if (value.newPass.length > 64) { + err = 'New password must be less than 65 characters' + } + + // confirm current password is correct + const { 'password-hash': passwordHash } = await getServerInfo(this.patch) + try { + argon2.verify(passwordHash, value.currPass) + } catch (e) { + err = 'Current password is invalid' + } + + if (err) { + this.errToast.present(err) + return false + } + + const loader = await this.loadingCtrl.create({ + message: 'Changing master password...', + }) + await loader.present() + + try { + await this.embassyApi.resetPassword({ + 'old-password': value.currPass, + 'new-password': value.newPass, + }) + const toast = await this.toastCtrl.create({ + header: 'Password changed!', + position: 'bottom', + duration: 2000, + }) + + toast.present() + return true + } catch (e: any) { + this.errToast.present(e) + return false + } finally { + loader.dismiss() + } + } + + async updateEos(): Promise { const modal = await this.modalCtrl.create({ component: OSUpdatePage, }) @@ -369,11 +469,11 @@ export class ServerShowPage { disabled$: of(false), }, { - title: 'LAN', - description: `Download and trust your server's certificate for a secure local connection`, - icon: 'home-outline', + title: 'Root CA', + description: `Download and trust your server's root certificate authority`, + icon: 'ribbon-outline', action: () => - this.navCtrl.navigateForward(['lan'], { relativeTo: this.route }), + this.navCtrl.navigateForward(['root-ca'], { relativeTo: this.route }), detail: true, disabled$: of(false), }, @@ -416,6 +516,14 @@ export class ServerShowPage { detail: true, disabled$: of(false), }, + { + title: 'Change Master Password', + description: `Change your StartOS master password`, + icon: 'key-outline', + action: () => this.presentAlertResetPassword(), + detail: false, + disabled$: of(!this.secure), + }, { title: 'Experimental Features', description: 'Try out new and potentially unstable new features', @@ -510,11 +618,7 @@ export class ServerShowPage { description: 'Get help from the Start9 team and community', icon: 'chatbubbles-outline', action: () => - window.open( - 'https://start9.com/contact', - '_blank', - 'noreferrer', - ), + window.open('https://start9.com/contact', '_blank', 'noreferrer'), detail: true, disabled$: of(false), }, @@ -616,3 +720,30 @@ interface SettingBtn { detail: boolean disabled$: Observable } + +const PasswordSpec: ConfigSpec = { + currPass: { + type: 'string', + name: 'Current Password', + placeholder: 'CurrentPass', + nullable: false, + masked: true, + copyable: false, + }, + newPass: { + type: 'string', + name: 'New Password', + placeholder: 'NewPass', + nullable: false, + masked: true, + copyable: false, + }, + newPass2: { + type: 'string', + name: 'Retype New Password', + placeholder: 'NewPass', + nullable: false, + masked: true, + copyable: false, + }, +} diff --git a/frontend/projects/ui/src/app/apps/ui/pages/system/system.module.ts b/frontend/projects/ui/src/app/apps/ui/pages/system/system.module.ts index ff4093f02..b9bf3bff2 100644 --- a/frontend/projects/ui/src/app/apps/ui/pages/system/system.module.ts +++ b/frontend/projects/ui/src/app/apps/ui/pages/system/system.module.ts @@ -10,7 +10,7 @@ const routes: Routes = [ ), }, { - path: 'lan', + path: 'root-ca', loadChildren: () => import('./lan/lan.module').then(m => m.LANPageModule), }, { diff --git a/frontend/projects/ui/src/app/common/os-welcome/os-welcome.page.html b/frontend/projects/ui/src/app/common/os-welcome/os-welcome.page.html index cddf37d15..cd0c93507 100644 --- a/frontend/projects/ui/src/app/common/os-welcome/os-welcome.page.html +++ b/frontend/projects/ui/src/app/common/os-welcome/os-welcome.page.html @@ -12,6 +12,30 @@

This Release

+

0.3.4.4

+

+ View the complete + + release notes + + for more details. +

+

Highlights
+
    +
  • Https over Tor for faster UI loading times
  • +
  • Change password through UI
  • +
  • Use IP address for Network Folder backups
  • +
  • + Multiple bug fixes, performance enhancements, and other small features +
  • +
+ +

Previous Releases

+

0.3.4.3

View the complete @@ -28,12 +52,10 @@

  • Improved Tor reliability
  • Experimental features tab
  • -
  • multiple bugfixes and general performance enhancements
  • +
  • Multiple bugfixes and general performance enhancements
  • Update branding
-

Previous Releases

-

0.3.4.2

View the complete diff --git a/frontend/projects/ui/src/app/common/toast-container/refresh-alert/refresh-alert.component.html b/frontend/projects/ui/src/app/common/toast-container/refresh-alert/refresh-alert.component.html index 20985c11e..a8dd08107 100644 --- a/frontend/projects/ui/src/app/common/toast-container/refresh-alert/refresh-alert.component.html +++ b/frontend/projects/ui/src/app/common/toast-container/refresh-alert/refresh-alert.component.html @@ -1,15 +1,28 @@ - Your user interface is cached and out of date. Hard refresh the page to get - the latest UI. -

    -
  • - On Mac - : cmd + shift + R -
  • -
  • - On Linux/Windows - : ctrl + shift + R -
  • -
- Ok + + Your user interface is cached and out of date. Hard refresh the page to get + the latest UI. +
    +
  • + On Mac + : cmd + shift + R +
  • +
  • + On Linux/Windows + : ctrl + shift + R +
  • +
  • + On Android/iOS + : Browser specific, typically a refresh button in the browser menu. +
  • +
+
+ + Your user interface is cached and out of date. Attempt to reload the PWA + using the button below. If you continue to see this message, uninstall and + reinstall the PWA. + + + Ok + Reload diff --git a/frontend/projects/ui/src/app/common/toast-container/refresh-alert/refresh-alert.component.ts b/frontend/projects/ui/src/app/common/toast-container/refresh-alert/refresh-alert.component.ts index e9a2e75ae..f039841d3 100644 --- a/frontend/projects/ui/src/app/common/toast-container/refresh-alert/refresh-alert.component.ts +++ b/frontend/projects/ui/src/app/common/toast-container/refresh-alert/refresh-alert.component.ts @@ -1,7 +1,9 @@ import { ChangeDetectionStrategy, Component, Inject } from '@angular/core' -import { Observable, Subject, merge } from 'rxjs' +import { merge, Observable, Subject } from 'rxjs' import { RefreshAlertService } from './refresh-alert.service' +import { SwUpdate } from '@angular/service-worker' +import { LoadingController } from '@ionic/angular' @Component({ selector: 'refresh-alert', @@ -10,13 +12,36 @@ import { RefreshAlertService } from './refresh-alert.service' }) export class RefreshAlertComponent { private readonly dismiss$ = new Subject() - readonly show$ = merge(this.dismiss$, this.refresh$) + onPwa = false constructor( @Inject(RefreshAlertService) private readonly refresh$: Observable, + private readonly updates: SwUpdate, + private readonly loadingCtrl: LoadingController, ) {} + ngOnInit() { + this.onPwa = window.matchMedia('(display-mode: standalone)').matches + } + + async pwaReload() { + const loader = await this.loadingCtrl.create({ + message: 'Reloading PWA...', + }) + await loader.present() + try { + // attempt to update to the latest client version available + await this.updates.activateUpdate() + } catch (e) { + console.error('Error activating update from service worker: ', e) + } finally { + loader.dismiss() + // always reload, as this resolves most out of sync cases + window.location.reload() + } + } + onDismiss() { this.dismiss$.next(false) } diff --git a/frontend/projects/ui/src/app/common/widget-list/widget-list.component.ts b/frontend/projects/ui/src/app/common/widget-list/widget-list.component.ts index 36eea1f7f..d8e909972 100644 --- a/frontend/projects/ui/src/app/common/widget-list/widget-list.component.ts +++ b/frontend/projects/ui/src/app/common/widget-list/widget-list.component.ts @@ -46,11 +46,11 @@ export class WidgetListComponent { qp: { back: 'true' }, }, { - title: 'Secure LAN', - icon: 'home-outline', + title: 'Root CA', + icon: 'ribbon-outline', color: 'var(--alt-orange)', - description: `Download and trust your server's certificate`, - link: '/system/lan', + description: `Download and trust your server's root certificate authority`, + link: '/system/root-ca', }, { title: 'Create Backup', diff --git a/frontend/projects/ui/src/app/services/api/api.fixures.ts b/frontend/projects/ui/src/app/services/api/api.fixures.ts index 800eb6914..b444adccf 100644 --- a/frontend/projects/ui/src/app/services/api/api.fixures.ts +++ b/frontend/projects/ui/src/app/services/api/api.fixures.ts @@ -35,9 +35,10 @@ export module Mock { 'shutting-down': false, } export const MarketplaceEos: RR.GetMarketplaceEosRes = { - version: '0.3.4.3', + version: '0.3.4.4', headline: 'Our biggest release ever.', 'release-notes': { + '0.3.4.4': 'Some **Markdown** release _notes_ for 0.3.4.4', '0.3.4.3': 'Some **Markdown** release _notes_ for 0.3.4.3', '0.3.4.2': 'Some **Markdown** release _notes_ for 0.3.4.2', '0.3.4.1': 'Some **Markdown** release _notes_ for 0.3.4.1', diff --git a/frontend/projects/ui/src/app/services/api/api.types.ts b/frontend/projects/ui/src/app/services/api/api.types.ts index 8ec0ecf59..b877410f7 100644 --- a/frontend/projects/ui/src/app/services/api/api.types.ts +++ b/frontend/projects/ui/src/app/services/api/api.types.ts @@ -29,6 +29,12 @@ export module RR { export type LogoutReq = {} // auth.logout export type LogoutRes = null + export type ResetPasswordReq = { + 'old-password': string + 'new-password': string + } // auth.reset-password + export type ResetPasswordRes = null + // server export type EchoReq = { message: string } // server.echo @@ -86,11 +92,6 @@ export module RR { export type KillSessionsReq = { ids: string[] } // sessions.kill export type KillSessionsRes = null - // password - - export type UpdatePasswordReq = { password: string } // password.set - export type UpdatePasswordRes = null - // notification export type GetNotificationsReq = { diff --git a/frontend/projects/ui/src/app/services/api/embassy-api.service.ts b/frontend/projects/ui/src/app/services/api/embassy-api.service.ts index 168a7692b..7ce599d4c 100644 --- a/frontend/projects/ui/src/app/services/api/embassy-api.service.ts +++ b/frontend/projects/ui/src/app/services/api/embassy-api.service.ts @@ -53,6 +53,10 @@ export abstract class ApiService { abstract killSessions(params: RR.KillSessionsReq): Promise + abstract resetPassword( + params: RR.ResetPasswordReq, + ): Promise + // server abstract echo(params: RR.EchoReq): Promise @@ -128,9 +132,6 @@ export abstract class ApiService { abstract getEos(): Promise - // password - // abstract updatePassword (params: RR.UpdatePasswordReq): Promise - // notification abstract getNotifications( diff --git a/frontend/projects/ui/src/app/services/api/embassy-live-api.service.ts b/frontend/projects/ui/src/app/services/api/embassy-live-api.service.ts index 3fb8f5a47..5301d4817 100644 --- a/frontend/projects/ui/src/app/services/api/embassy-live-api.service.ts +++ b/frontend/projects/ui/src/app/services/api/embassy-live-api.service.ts @@ -105,6 +105,12 @@ export class LiveApiService extends ApiService { return this.rpcRequest({ method: 'auth.session.kill', params }) } + async resetPassword( + params: RR.ResetPasswordReq, + ): Promise { + return this.rpcRequest({ method: 'auth.reset-password', params }) + } + // server async echo(params: RR.EchoReq): Promise { diff --git a/frontend/projects/ui/src/app/services/api/embassy-mock-api.service.ts b/frontend/projects/ui/src/app/services/api/embassy-mock-api.service.ts index a94564b74..70ff3f2c6 100644 --- a/frontend/projects/ui/src/app/services/api/embassy-mock-api.service.ts +++ b/frontend/projects/ui/src/app/services/api/embassy-mock-api.service.ts @@ -158,6 +158,13 @@ export class MockApiService extends ApiService { return null } + async resetPassword( + params: RR.ResetPasswordReq, + ): Promise { + await pauseFor(2000) + return null + } + // server async echo(params: RR.EchoReq): Promise { @@ -388,12 +395,6 @@ export class MockApiService extends ApiService { return Mock.MarketplaceEos } - // password - // async updatePassword (params: RR.UpdatePasswordReq): Promise { - // await pauseFor(2000) - // return null - // } - // notification async getNotifications( diff --git a/frontend/projects/ui/src/app/services/api/mock-patch.ts b/frontend/projects/ui/src/app/services/api/mock-patch.ts index 4f678ecb5..f6a54ce55 100644 --- a/frontend/projects/ui/src/app/services/api/mock-patch.ts +++ b/frontend/projects/ui/src/app/services/api/mock-patch.ts @@ -39,7 +39,7 @@ export const mockPatchData: DataModel = { country: 'us', 'last-backup': new Date(new Date().valueOf() - 604800001).toISOString(), 'lan-address': 'https://adjective-noun.local', - 'tor-address': 'http://myveryownspecialtoraddress.onion', + 'tor-address': 'https://myveryownspecialtoraddress.onion', 'ip-info': { eth0: { ipv4: '10.0.0.1', diff --git a/frontend/projects/ui/src/app/services/marketplace.service.ts b/frontend/projects/ui/src/app/services/marketplace.service.ts index 302c57d58..b714e89e7 100644 --- a/frontend/projects/ui/src/app/services/marketplace.service.ts +++ b/frontend/projects/ui/src/app/services/marketplace.service.ts @@ -278,6 +278,7 @@ export class MarketplaceService implements AbstractMarketplaceService { > = {}, ): Observable { return this.patch.watch$('server-info', 'eos-version-compat').pipe( + take(1), switchMap(versionCompat => { const qp: RR.GetMarketplacePackagesReq = { ...params, diff --git a/frontend/projects/ui/src/environments/environment.ts b/frontend/projects/ui/src/environments/environment.ts index 6bbb39e80..fb9d65078 100644 --- a/frontend/projects/ui/src/environments/environment.ts +++ b/frontend/projects/ui/src/environments/environment.ts @@ -4,7 +4,7 @@ export const environment = { production: false, - useServiceWorker: true, + useServiceWorker: false, } /* diff --git a/frontend/projects/ui/src/index.html b/frontend/projects/ui/src/index.html index 3cdf84ff5..0248b7462 100644 --- a/frontend/projects/ui/src/index.html +++ b/frontend/projects/ui/src/index.html @@ -14,6 +14,11 @@ + diff --git a/frontend/projects/ui/src/manifest.webmanifest b/frontend/projects/ui/src/manifest.webmanifest index 7895929a7..94e6b08f9 100644 --- a/frontend/projects/ui/src/manifest.webmanifest +++ b/frontend/projects/ui/src/manifest.webmanifest @@ -5,8 +5,8 @@ "background_color": "#1e1e1e", "display": "standalone", "scope": ".", - "start_url": "/", - "id": "/", + "start_url": "/?version=0344", + "id": "/?version=0344", "icons": [ { "src": "assets/img/icon_pwa.png", diff --git a/libs/Cargo.lock b/libs/Cargo.lock index 462acf99d..8714ececd 100644 --- a/libs/Cargo.lock +++ b/libs/Cargo.lock @@ -14,9 +14,9 @@ dependencies = [ [[package]] name = "addr2line" -version = "0.19.0" +version = "0.20.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a76fd60b23679b7d19bd066031410fb7e458ccc5e958eb5c325888ce4baedc97" +checksum = "f4fa78e18c64fce05e902adecd7a5eed15a5e0a3439f7b0e169f0252214865e3" dependencies = [ "gimli", ] @@ -33,20 +33,43 @@ version = "0.7.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fcb51a0695d8f838b1ee009b3fbf66bda078cd64590202a864a8f3e8c4315c47" dependencies = [ - "getrandom 0.2.8", + "getrandom 0.2.10", + "once_cell", + "version_check", +] + +[[package]] +name = "ahash" +version = "0.8.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c99f64d1e06488f620f932677e24bc6e2897582980441ae90a671415bd7ec2f" +dependencies = [ + "cfg-if", "once_cell", "version_check", ] [[package]] name = "aho-corasick" -version = "0.7.20" +version = "1.0.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cc936419f96fa211c1b9166887b38e5e40b19958e5b895be7c1f93adec7071ac" +checksum = "43f6cb1bf222025340178f382c426f13757b2960e89779dfcb319c32542a5a41" dependencies = [ "memchr", ] +[[package]] +name = "allocator-api2" +version = "0.2.16" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0942ffc6dcaadf03badf6e6a2d0228460359d5e34b57ccdc720b7382dfbd5ec5" + +[[package]] +name = "android-tzdata" +version = "0.1.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "e999941b234f3131b00bc13c22d06e8c5ff726d1b6318ac7eb276997bbb4fef0" + [[package]] name = "android_system_properties" version = "0.1.5" @@ -58,29 +81,28 @@ dependencies = [ [[package]] name = "anyhow" -version = "1.0.68" +version = "1.0.72" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2cb2f989d18dd141ab8ae82f64d1a8cdd37e0840f73a406896cf5e99502fab61" +checksum = "3b13c32d80ecc7ab747b80c3784bce54ee8a7a0cc4fbda9bf4cda2cf6fe90854" [[package]] name = "ast_node" -version = "0.7.7" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bc4c00309ed1c8104732df4a5fa9acc3b796b6f8531dfbd5ce0078c86f997244" +checksum = "c704e2f6ee1a98223f5a7629a6ef0f3decb3b552ed282889dc957edff98ce1e6" dependencies = [ - "darling 0.10.2", "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn", + "syn 1.0.109", ] [[package]] name = "async-channel" -version = "1.8.0" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cf46fee83e5ccffc220104713af3292ff9bc7c64c7de289f66dae8e38d826833" +checksum = "81953c529336010edd6d8e358f886d9581267795c61b19475b71314bffa46d35" dependencies = [ "concurrent-queue", "event-listener", @@ -89,34 +111,35 @@ dependencies = [ [[package]] name = "async-stream" -version = "0.3.3" +version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dad5c83079eae9969be7fadefe640a1c566901f05ff91ab221de4b6f68d9507e" +checksum = "cd56dd203fef61ac097dd65721a419ddccb106b2d2b70ba60a6b529f03961a51" dependencies = [ "async-stream-impl", "futures-core", + "pin-project-lite", ] [[package]] name = "async-stream-impl" -version = "0.3.3" +version = "0.3.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "10f203db73a71dfa2fb6dd22763990fa26f3d2625a6da2da900d23b87d26be27" +checksum = "16e62a023e7c117e27523144c5d2459f4397fcc3cab0085af8e2224f643a0193" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] name = "async-trait" -version = "0.1.64" +version = "0.1.69" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1cd7fce9ba8c3c042128ce72d8b2ddbf3a05747efb67ea0313c635e10bda47a2" +checksum = "7b2d0f03b3640e3a630367e40c468cb7f309529c708ed1d88597047b0e7c6ef7" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] @@ -147,9 +170,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa" [[package]] name = "backtrace" -version = "0.3.67" +version = "0.3.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "233d376d6d185f2a3093e58f283f60f880315b6c60075b01f36b3b85154564ca" +checksum = "4319208da049c43661739c5fade2ba182f09d1dc2299b32298d3a31692b17e12" dependencies = [ "addr2line", "cc", @@ -172,12 +195,6 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "23ce669cd6c8588f79e15cf450314f9638f967fc5770ff1c7c1deb0925ea7cfa" -[[package]] -name = "base64" -version = "0.11.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b41b7ea54a0c9d92199de89e20e58d49f02f8e699814ef3fdf266f6f748d15c7" - [[package]] name = "base64" version = "0.13.1" @@ -186,21 +203,21 @@ checksum = "9e1b586273c5702936fe7b7d6896644d8be71e6314cfe09d3167c95f712589e8" [[package]] name = "base64" -version = "0.21.0" +version = "0.21.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4a4ddaa51a5bc52a6948f74c06d20aaaddb71924eab79b8c97a8c556e942d6a" +checksum = "604178f6c5c21f02dc555784810edfb88d34ac2c73b2eae109655649ee73ce3d" [[package]] name = "base64ct" -version = "1.5.3" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b645a089122eccb6111b4f81cbc1a49f5900ac4666bb93ac027feaecf15607bf" +checksum = "8c3c1a368f70d6cf7302d78f8f7093da241fb8e8807c05cc9e51a125895a6d5b" [[package]] name = "better_scoped_tls" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b73e8ecdec39e98aa3b19e8cd0b8ed8f77ccb86a6b0b2dc7cd86d105438a2123" +checksum = "794edcc9b3fb07bb4aecaa11f093fd45663b4feadb782d68303a2268bc2701de" dependencies = [ "scoped-tls", ] @@ -220,6 +237,12 @@ version = "1.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bef38d45163c2f1dde094a7dfd33ccf595c92905c8f8f4fdc18d06fb1037718a" +[[package]] +name = "bitflags" +version = "2.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "630be753d4e58660abd17930c71b647fe46c27ea6b63cc59e1e3851406972e42" + [[package]] name = "bitmaps" version = "2.1.0" @@ -259,9 +282,9 @@ dependencies = [ [[package]] name = "block-buffer" -version = "0.10.3" +version = "0.10.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69cce20737498f97b993470a6e536b8523f0af7892a4f928cceb1ac5e52ebe7e" +checksum = "3078c7629b62d3f0439517fa394996acacc5cbc91c5a20d8c658e77abd503a71" dependencies = [ "generic-array", ] @@ -312,9 +335,9 @@ dependencies = [ [[package]] name = "bumpalo" -version = "3.11.1" +version = "3.13.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "572f695136211188308f16ad2ca5c851a712c464060ae6974944458eb83880ba" +checksum = "a3e2c3daef883ecc1b5d58c15adae93470a91d425f3532ba1695849656af3fc1" [[package]] name = "byteorder" @@ -324,15 +347,15 @@ checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610" [[package]] name = "bytes" -version = "1.3.0" +version = "1.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dfb24e866b15a1af2a1b663f10c6b6b8f397a84aadb828f12e5b289ec23a3a3c" +checksum = "89b2fd2a0dcf38d7971e2194b6b6eebab45ae01067456a7fd93d5547a61b70be" [[package]] name = "cc" -version = "1.0.78" +version = "1.0.79" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a20104e2335ce8a659d6dd92a51a767a0c062599c73b343fd152cb401e828c3d" +checksum = "50d30906286121d95be3d479533b458f87493b30a4b5f79a607db8f5d11aa91f" [[package]] name = "cfg-if" @@ -342,27 +365,27 @@ checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" [[package]] name = "chrono" -version = "0.4.23" +version = "0.4.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "16b0a3d9ed01224b22057780a37bb8c5dbfe1be8ba48678e7bf57ec4b385411f" +checksum = "ec837a71355b28f6556dbd569b37b3f363091c0bd4b2e735674521b4c5fd9bc5" dependencies = [ + "android-tzdata", "iana-time-zone", - "num-integer", "num-traits", "winapi", ] [[package]] name = "clap" -version = "3.2.23" +version = "3.2.25" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "71655c45cb9845d3270c9d6df84ebe72b4dad3c2ba3f7023ad47c144e4e473a5" +checksum = "4ea181bf566f71cb9a5d17a59e1871af638180a18fb0035c92ae62b705207123" dependencies = [ "atty", - "bitflags", + "bitflags 1.3.2", "clap_lex", - "indexmap", - "strsim 0.10.0", + "indexmap 1.9.3", + "strsim", "termcolor", "textwrap", ] @@ -376,16 +399,6 @@ dependencies = [ "os_str_bytes", ] -[[package]] -name = "codespan-reporting" -version = "0.11.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3538270d33cc669650c4b093848450d380def10c331d38c768e34cac80576e6e" -dependencies = [ - "termcolor", - "unicode-width", -] - [[package]] name = "color-eyre" version = "0.6.2" @@ -415,18 +428,18 @@ dependencies = [ [[package]] name = "concurrent-queue" -version = "2.1.0" +version = "2.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c278839b831783b70278b14df4d45e1beb1aad306c07bb796637de9a0e323e8e" +checksum = "62ec6771ecfa0762d24683ee5a32ad78487a3d3afdc0fb8cae19d2c5deb50b7c" dependencies = [ "crossbeam-utils", ] [[package]] name = "const-oid" -version = "0.9.1" +version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cec318a675afcb6a1ea1d4340e2d377e56e47c266f28043ceccbf4412ddfdd3b" +checksum = "795bc6e66a8e340f075fcf6227e417a2dc976b92b91f3cdc778bb858778b6747" [[package]] name = "convert_case" @@ -446,24 +459,24 @@ dependencies = [ [[package]] name = "core-foundation-sys" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5827cebf4670468b8772dd191856768aedcb1b0278a04f989f7766351917b9dc" +checksum = "e496a50fda8aacccc86d7529e2c1e0892dbd0f898a6b5645b5561b89c3210efa" [[package]] name = "cpufeatures" -version = "0.2.5" +version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "28d997bd5e24a5928dd43e46dc529867e207907fe0b239c3477d924f7f2ca320" +checksum = "a17b76ff3a4162b0b27f354a0c87015ddad39d35f9c0c36607a3bdd175dde1f1" dependencies = [ "libc", ] [[package]] name = "crc" -version = "3.0.0" +version = "3.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "53757d12b596c16c78b83458d732a5d1a17ab3f53f2f7412f6fb57cc8a140ab3" +checksum = "86ec7a15cbe22e59248fc7eadb1907dab5ba09372595da4d73dd805ed4417dfe" dependencies = [ "crc-catalog", ] @@ -495,9 +508,9 @@ dependencies = [ [[package]] name = "crossbeam-utils" -version = "0.8.14" +version = "0.8.16" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4fb766fa798726286dbbb842f174001dab8abc7b627a1dd86e0b7222a95d929f" +checksum = "5a22b2d63d4d1dc0b7f1b6b2747dd0088008a9be28b6ddf0b1e7d335e3037294" dependencies = [ "cfg-if", ] @@ -547,82 +560,14 @@ dependencies = [ "zeroize", ] -[[package]] -name = "cxx" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "51d1075c37807dcf850c379432f0df05ba52cc30f279c5cfc43cc221ce7f8579" -dependencies = [ - "cc", - "cxxbridge-flags", - "cxxbridge-macro", - "link-cplusplus", -] - -[[package]] -name = "cxx-build" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5044281f61b27bc598f2f6647d480aed48d2bf52d6eb0b627d84c0361b17aa70" -dependencies = [ - "cc", - "codespan-reporting", - "once_cell", - "proc-macro2", - "quote", - "scratch", - "syn", -] - -[[package]] -name = "cxxbridge-flags" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "61b50bc93ba22c27b0d31128d2d130a0a6b3d267ae27ef7e4fae2167dfe8781c" - -[[package]] -name = "cxxbridge-macro" -version = "1.0.86" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39e61fda7e62115119469c7b3591fd913ecca96fb766cfd3f2e2502ab7bc87a5" -dependencies = [ - "proc-macro2", - "quote", - "syn", -] - -[[package]] -name = "darling" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d706e75d87e35569db781a9b5e2416cff1236a47ed380831f959382ccd5f858" -dependencies = [ - "darling_core 0.10.2", - "darling_macro 0.10.2", -] - [[package]] name = "darling" version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "a01d95850c592940db9b8194bc39f4bc0e89dee5c4265e4b1807c34a9aba453c" dependencies = [ - "darling_core 0.13.4", - "darling_macro 0.13.4", -] - -[[package]] -name = "darling_core" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0c960ae2da4de88a91b2d920c2a7233b400bc33cb28453a2987822d8392519b" -dependencies = [ - "fnv", - "ident_case", - "proc-macro2", - "quote", - "strsim 0.9.3", - "syn", + "darling_core", + "darling_macro", ] [[package]] @@ -635,19 +580,8 @@ dependencies = [ "ident_case", "proc-macro2", "quote", - "strsim 0.10.0", - "syn", -] - -[[package]] -name = "darling_macro" -version = "0.10.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d9b5a2f4ac4969822c62224815d069952656cadc7084fdca9751e6d959189b72" -dependencies = [ - "darling_core 0.10.2", - "quote", - "syn", + "strsim", + "syn 1.0.109", ] [[package]] @@ -656,68 +590,106 @@ version = "0.13.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9c972679f83bdf9c42bd905396b6c3588a843a17f0f16dfcfa3e2c5d57441835" dependencies = [ - "darling_core 0.13.4", + "darling_core", "quote", - "syn", + "syn 1.0.109", ] [[package]] name = "dashmap" -version = "5.4.0" +version = "5.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "907076dfda823b0b36d2a1bb5f90c96660a5bbcd7729e10727f07858f22c4edc" +checksum = "6943ae99c34386c84a470c499d3414f66502a41340aa895406e0d2e4a207b91d" dependencies = [ "cfg-if", - "hashbrown", + "hashbrown 0.14.0", "lock_api", "once_cell", - "parking_lot_core 0.9.6", + "parking_lot_core 0.9.8", ] +[[package]] +name = "data-encoding" +version = "2.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2e66c9d817f1720209181c316d28635c050fa304f9c79e47a520882661b7308" + [[package]] name = "data-url" -version = "0.1.1" +version = "0.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3a30bfce702bcfa94e906ef82421f2c0e61c076ad76030c16ee5d2e9a32fe193" +checksum = "8d7439c3735f405729d52c3fbbe4de140eaf938a1fe47d227c27f8254d4302a5" + +[[package]] +name = "deno-proc-macro-rules" +version = "0.3.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3c65c2ffdafc1564565200967edc4851c7b55422d3913466688907efd05ea26f" dependencies = [ - "matches", + "deno-proc-macro-rules-macros", + "proc-macro2", + "syn 2.0.18", ] [[package]] -name = "debug_unreachable" -version = "0.1.1" +name = "deno-proc-macro-rules-macros" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9a032eac705ca39214d169f83e3d3da290af06d8d1d344d1baad2fd002dca4b3" +checksum = "3047b312b7451e3190865713a4dd6e1f821aed614ada219766ebc3024a690435" dependencies = [ - "unreachable", + "once_cell", + "proc-macro2", + "quote", + "syn 2.0.18", ] [[package]] name = "deno_ast" -version = "0.15.0" +version = "0.27.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a2989afff97ba7da10f186e9a45e946b4ef943b9d4babd2ee7b4b24cc9906b69" +checksum = "a39dc5554b1c835c62914b545f8b378563a997521e39a8f03450b37b216143ef" dependencies = [ "anyhow", "base64 0.13.1", - "data-url", + "deno_media_type", "dprint-swc-ext", "serde", - "swc_ecmascript", + "swc_atoms", + "swc_common", + "swc_config", + "swc_config_macro", + "swc_ecma_ast", + "swc_ecma_codegen", + "swc_ecma_codegen_macros", + "swc_ecma_loader", + "swc_ecma_parser", + "swc_ecma_transforms_base", + "swc_ecma_transforms_classes", + "swc_ecma_transforms_macros", + "swc_ecma_transforms_proposal", + "swc_ecma_transforms_react", + "swc_ecma_transforms_typescript", + "swc_ecma_utils", + "swc_ecma_visit", + "swc_eq_ignore_macros", + "swc_macros_common", + "swc_visit", + "swc_visit_macros", "text_lines", "url", ] [[package]] name = "deno_core" -version = "0.136.0" +version = "0.195.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07ced67ffe84c64aee6e84e40558835752b6f12807f84d15da8f5954e2b670c5" +checksum = "408e433386de30dd501cf82d26ca1fb4cd84b055536f8f6f9c78c3380649d94b" dependencies = [ "anyhow", + "bytes", "deno_ops", "futures", - "indexmap", + "indexmap 1.9.3", "libc", "log", "once_cell", @@ -726,21 +698,44 @@ dependencies = [ "serde", "serde_json", "serde_v8", + "smallvec", "sourcemap", + "tokio", "url", "v8", ] [[package]] -name = "deno_ops" -version = "0.14.0" +name = "deno_media_type" +version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "05520711837dd592d2861319ea3cf2dfd81e39bb92e41758ee9172f3623daebd" +checksum = "63772a60d740a41d97fbffb4788fc3779e6df47289e01892c12be38f4a5beded" dependencies = [ + "data-url", + "serde", + "url", +] + +[[package]] +name = "deno_ops" +version = "0.73.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c6d06feb9b26ccd2997f35610517d5a8f1dd423e21364509523f72474601f87f" +dependencies = [ + "deno-proc-macro-rules", + "lazy-regex", + "once_cell", + "pmutil", "proc-macro-crate", "proc-macro2", "quote", - "syn", + "regex", + "strum", + "strum_macros", + "syn 1.0.109", + "syn 2.0.18", + "thiserror", + "v8", ] [[package]] @@ -764,7 +759,7 @@ dependencies = [ "proc-macro2", "quote", "rustc_version 0.4.0", - "syn", + "syn 1.0.109", ] [[package]] @@ -778,11 +773,11 @@ dependencies = [ [[package]] name = "digest" -version = "0.10.6" +version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8168378f4e5023e7218c89c891c0fd8ecdb5e5e4f18cb78f38cf245dd021e76f" +checksum = "9ed9a281f7bc9b7576e61468ba615a66a5c8cfdff42420a70aa82701a3b1e292" dependencies = [ - "block-buffer 0.10.3", + "block-buffer 0.10.4", "const-oid", "crypto-common", "subtle", @@ -810,22 +805,23 @@ dependencies = [ [[package]] name = "dotenvy" -version = "0.15.6" +version = "0.15.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "03d8c417d7a8cb362e0c37e5d815f5eb7c37f79ff93707329d5a194e42e54ca0" +checksum = "1aaf95b3e5c8f23aa320147307562d361db0ae0d51242340f558153b4eb2439b" [[package]] name = "dprint-swc-ext" -version = "0.1.1" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3df529037ff02f1c43ae8c6cce54d9ad85546ff89cb5c1988f56130c16e16a48" +checksum = "dd4dda8a1b920e8be367aeaad035753d21bb69b3c50515afb41ab1eefbb886b5" dependencies = [ "bumpalo", "num-bigint", "rustc-hash", "swc_atoms", "swc_common", - "swc_ecmascript", + "swc_ecma_ast", + "swc_ecma_parser", "text_lines", ] @@ -868,9 +864,9 @@ dependencies = [ [[package]] name = "either" -version = "1.8.0" +version = "1.8.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90e5c1c8368803113bf0c9584fc495a58b86dc8a29edbf8fe877d21d9507e797" +checksum = "7fcaabb2fef8c910e7f4c7ce9f67a1283a1715879a7c230ca9d6d1ae31f16d91" dependencies = [ "serde", ] @@ -884,7 +880,7 @@ dependencies = [ "base16ct", "crypto-bigint", "der", - "digest 0.10.6", + "digest 0.10.7", "ff", "generic-array", "group", @@ -912,7 +908,7 @@ dependencies = [ "tracing", "tracing-error 0.2.0", "tracing-futures", - "tracing-subscriber 0.3.16", + "tracing-subscriber 0.3.17", "yajrc 0.1.0 (git+https://github.com/dr-bonez/yajrc.git?branch=develop)", ] @@ -929,34 +925,28 @@ dependencies = [ [[package]] name = "encoding_rs" -version = "0.8.31" +version = "0.8.32" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9852635589dc9f9ea1b6fe9f05b50ef208c85c834a562f0c6abb1c475736ec2b" +checksum = "071a31f4ee85403370b58aca746f01041ede6f0da2730960ad001edc2b71b394" dependencies = [ "cfg-if", ] [[package]] -name = "enum_kind" -version = "0.2.1" +name = "equivalent" +version = "1.0.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "78b940da354ae81ef0926c5eaa428207b8f4f091d3956c891dfbd124162bed99" -dependencies = [ - "pmutil", - "proc-macro2", - "swc_macros_common", - "syn", -] +checksum = "5443807d6dff69373d433ab9ef5378ad8df50ca6298caf15de6e52e24aaf54d5" [[package]] name = "errno" -version = "0.2.8" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f639046355ee4f37944e44f60642c6f3a7efa3cf6b78c78a0d989a8ce6c396a1" +checksum = "4bcfec3a70f97c962c307b2d2c56e358cf1d00b558d74262b5f929ee8cc7e73a" dependencies = [ "errno-dragonfly", "libc", - "winapi", + "windows-sys 0.48.0", ] [[package]] @@ -987,9 +977,9 @@ dependencies = [ [[package]] name = "fastrand" -version = "1.8.0" +version = "1.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a7a407cfaa3385c4ae6b23e84623d48c2798d06e3e6a1878f7f59f17b3f86499" +checksum = "e51093e27b0797c359783294ca4f0a911c270184cb10f85783b118614a1501be" dependencies = [ "instant", ] @@ -1015,9 +1005,9 @@ dependencies = [ [[package]] name = "flate2" -version = "1.0.25" +version = "1.0.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a8a2db397cb1c8772f31494cb8917e48cd1e64f0fa7efac59fbd741a0a8ce841" +checksum = "3b9429470923de8e8cbd4d2dc513535400b4b3fef0319fb5c4e1f520a7bef743" dependencies = [ "crc32fast", "miniz_oxide", @@ -1046,9 +1036,9 @@ checksum = "00b0228411908ca8685dba7fc2cdd70ec9990a6e753e89b6ac91a84c40fbaf4b" [[package]] name = "form_urlencoded" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a9c384f161156f5260c24a097c56119f9be8c798586aecc13afbcbe7b7e26bf8" +checksum = "a62bc1cf6f830c2ec14a513a9fb124d0a213a629668a4186f329db21fe045652" dependencies = [ "percent-encoding", ] @@ -1064,14 +1054,14 @@ dependencies = [ [[package]] name = "from_variant" -version = "0.1.4" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f0981e470d2ab9f643df3921d54f1952ea100c39fdb6a3fdc820e20d2291df6c" +checksum = "1d449976075322384507443937df2f1d5577afbf4282f12a5a66ef29fa3e6307" dependencies = [ "pmutil", "proc-macro2", "swc_macros_common", - "syn", + "syn 1.0.109", ] [[package]] @@ -1092,9 +1082,9 @@ checksum = "e6d5a32815ae3f33302d95fdcb2ce17862f8c65363dcfd29360480ba1001fc9c" [[package]] name = "futures" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38390104763dc37a5145a53c29c63c1290b5d316d6086ec32c293f6736051bb0" +checksum = "23342abe12aba583913b2e62f22225ff9c950774065e4bfb61a19cd9770fec40" dependencies = [ "futures-channel", "futures-core", @@ -1107,9 +1097,9 @@ dependencies = [ [[package]] name = "futures-channel" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "52ba265a92256105f45b719605a571ffe2d1f0fea3807304b522c1d778f79eed" +checksum = "955518d47e09b25bbebc7a18df10b81f0c766eaf4c4f1cccef2fca5f2a4fb5f2" dependencies = [ "futures-core", "futures-sink", @@ -1117,15 +1107,15 @@ dependencies = [ [[package]] name = "futures-core" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "04909a7a7e4633ae6c4a9ab280aeb86da1236243a77b694a49eacd659a4bd3ac" +checksum = "4bca583b7e26f571124fe5b7561d49cb2868d79116cfa0eefce955557c6fee8c" [[package]] name = "futures-executor" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7acc85df6714c176ab5edf386123fafe217be88c0840ec11f199441134a074e2" +checksum = "ccecee823288125bd88b4d7f565c9e58e41858e47ab72e8ea2d64e93624386e0" dependencies = [ "futures-core", "futures-task", @@ -1145,38 +1135,38 @@ dependencies = [ [[package]] name = "futures-io" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "00f5fb52a06bdcadeb54e8d3671f8888a39697dcb0b81b23b55174030427f4eb" +checksum = "4fff74096e71ed47f8e023204cfd0aa1289cd54ae5430a9523be060cdb849964" [[package]] name = "futures-macro" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bdfb8ce053d86b91919aad980c220b1fb8401a9394410e1c289ed7e66b61835d" +checksum = "89ca545a94061b6365f2c7355b4b32bd20df3ff95f02da9329b34ccc3bd6ee72" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] name = "futures-sink" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "39c15cf1a4aa79df40f1bb462fb39676d0ad9e366c2a33b590d7c66f4f81fcf9" +checksum = "f43be4fe21a13b9781a69afa4985b0f6ee0e1afab2c6f454a8cf30e2b2237b6e" [[package]] name = "futures-task" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2ffb393ac5d9a6eaa9d3fdf37ae2776656b706e200c8e16b1bdb227f5198e6ea" +checksum = "76d3d132be6c0e6aa1534069c705a74a5997a356c0dc2f86a47765e5617c5b65" [[package]] name = "futures-util" -version = "0.3.25" +version = "0.3.28" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "197676987abd2f9cadff84926f410af1c183608d36641465df73ae8211dc65d6" +checksum = "26b01e40b772d54cf6c6d721c1d1abd0647a0106a12ecaa1c186273392a69533" dependencies = [ "futures-channel", "futures-core", @@ -1192,9 +1182,9 @@ dependencies = [ [[package]] name = "generic-array" -version = "0.14.6" +version = "0.14.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bff49e947297f3312447abdca79f45f4738097cc82b06e72054d2223f601f1b9" +checksum = "85649ca51fd72272d7821adaf274ad91c288277713d9c18820d8499a7ff69e9a" dependencies = [ "typenum", "version_check", @@ -1213,9 +1203,9 @@ dependencies = [ [[package]] name = "getrandom" -version = "0.2.8" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c05aeb6a22b8f62540c194aac980f2115af067bfe15a0734d7277a768d396b31" +checksum = "be4136b2a15dd319360be1c07d9933517ccf0be8f16bf62a3bee4f0d618df427" dependencies = [ "cfg-if", "libc", @@ -1224,9 +1214,9 @@ dependencies = [ [[package]] name = "gimli" -version = "0.27.0" +version = "0.27.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dec7af912d60cdbd3677c1af9352ebae6fb8394d165568a2234df0fa00f87793" +checksum = "b6c80984affa11d98d1b88b66ac8853f143217b399d3c74116778ff8fdb4ed2e" [[package]] name = "group" @@ -1241,9 +1231,9 @@ dependencies = [ [[package]] name = "h2" -version = "0.3.15" +version = "0.3.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5f9f29bc9dda355256b2916cf526ab02ce0aeaaaf2bad60d65ef3f12f11dd0f4" +checksum = "97ec8491ebaf99c8eaa73058b045fe58073cd6be7f596ac993ced0b0a0c01049" dependencies = [ "bytes", "fnv", @@ -1251,7 +1241,7 @@ dependencies = [ "futures-sink", "futures-util", "http", - "indexmap", + "indexmap 1.9.3", "slab", "tokio", "tokio-util", @@ -1270,16 +1260,26 @@ version = "0.12.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8a9ee70c43aaf417c914396645a0fa852624801b24ebb7ae78fe8272889ac888" dependencies = [ - "ahash", + "ahash 0.7.6", +] + +[[package]] +name = "hashbrown" +version = "0.14.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2c6201b9ff9fd90a5a3bac2e56a830d0caa509576f0e503818ee82c181b3437a" +dependencies = [ + "ahash 0.8.3", + "allocator-api2", ] [[package]] name = "hashlink" -version = "0.8.1" +version = "0.8.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "69fe1fcf8b4278d860ad0548329f892a3631fb63f82574df68275f34cdbe0ffa" +checksum = "312f66718a2d7789ffef4f4b7b213138ed9f1eb3aa1d0d82fc99f88fb3ffd26f" dependencies = [ - "hashbrown", + "hashbrown 0.14.0", ] [[package]] @@ -1293,9 +1293,9 @@ dependencies = [ [[package]] name = "heck" -version = "0.4.0" +version = "0.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2540771e65fc8cb83cd6e8a237f70c319bd5c29f78ed1084ba5d50eeac86f7f9" +checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" dependencies = [ "unicode-segmentation", ] @@ -1329,12 +1329,9 @@ dependencies = [ [[package]] name = "hermit-abi" -version = "0.2.6" +version = "0.3.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ee512640fe35acbfb4bb779db6f0d80704c2cacfa2e39b601ef3e3f47d1ae4c7" -dependencies = [ - "libc", -] +checksum = "443144c8cdadd93ebf52ddb4056d257f5b52c04d3c804e657d19eb73fc33668b" [[package]] name = "hex" @@ -1367,14 +1364,14 @@ version = "0.12.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c49c37c09c17a53d937dfbb742eb3a961d65a994e6bcdcf37e7399d0cc8ab5e" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", ] [[package]] name = "http" -version = "0.2.8" +version = "0.2.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "75f43d41e26995c17e71ee126451dd3941010b0514a81a9d11f3b341debc2399" +checksum = "bd6effc99afb63425aff9b05836f029929e345a6148a14b7ecd5ab67af944482" dependencies = [ "bytes", "fnv", @@ -1406,9 +1403,9 @@ checksum = "c4a1e36c821dbe04574f602848a19f742f4fb3c98d40449f11bcad18d6b17421" [[package]] name = "hyper" -version = "0.14.23" +version = "0.14.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "034711faac9d2166cb1baf1a2fb0b60b1f277f8492fd72176c17f3515e1abd3c" +checksum = "ffb1cfd654a8219eaef89881fdb3bb3b1cdc5fa75ded05d6933b2b382e395468" dependencies = [ "bytes", "futures-channel", @@ -1456,26 +1453,25 @@ dependencies = [ [[package]] name = "iana-time-zone" -version = "0.1.53" +version = "0.1.57" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "64c122667b287044802d6ce17ee2ddf13207ed924c712de9a66a5814d5b64765" +checksum = "2fad5b825842d2b38bd206f3e81d6957625fd7f0a361e345c30e01a0ae2dd613" dependencies = [ "android_system_properties", "core-foundation-sys", "iana-time-zone-haiku", "js-sys", "wasm-bindgen", - "winapi", + "windows", ] [[package]] name = "iana-time-zone-haiku" -version = "0.1.1" +version = "0.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0703ae284fc167426161c2e3f1da3ea71d94b21bedbcc9494e92b28e334e3dca" +checksum = "f31827a206f56af32e590ba56d5d2d085f558508192593743f16b2306495269f" dependencies = [ - "cxx", - "cxx-build", + "cc", ] [[package]] @@ -1486,9 +1482,9 @@ checksum = "b9e0384b61958566e926dc50660321d12159025e767c18e043daf26b70104c39" [[package]] name = "idna" -version = "0.3.0" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e14ddfc70884202db2244c223200c204c2bda1bc6e0998d11b5e024d657209e6" +checksum = "7d20d6b07bfbc108882d88ed8e37d39636dcc260e15e30c45e6ba089610b917c" dependencies = [ "unicode-bidi", "unicode-normalization", @@ -1544,12 +1540,22 @@ checksum = "ce23b50ad8242c51a442f3ff322d56b02f08852c77e4c0b4d3fd684abc89c683" [[package]] name = "indexmap" -version = "1.9.2" +version = "1.9.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1885e79c1fc4b10f0e172c475f458b7f7b93061064d98c3293e98c5ba0c8b399" +checksum = "bd070e393353796e801d209ad339e89596eb4c8d430d18ede6a1cced8fafbd99" dependencies = [ "autocfg", - "hashbrown", + "hashbrown 0.12.3", +] + +[[package]] +name = "indexmap" +version = "2.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d5477fe2230a79769d8dc68e0eabf5437907c0457a5614a9e8dddb67f65eb65d" +dependencies = [ + "equivalent", + "hashbrown 0.14.0", ] [[package]] @@ -1563,13 +1569,13 @@ dependencies = [ [[package]] name = "internment" -version = "0.7.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a798d7677f07d6f1e77be484ea8626ddb1566194de399f1206306820c406371" +checksum = "161079c3ad892faa215fcfcf3fd7a6a3c9288df2b06a2c2bad7fbfad4f01d69d" dependencies = [ - "ahash", + "ahash 0.7.6", "dashmap", - "hashbrown", + "hashbrown 0.12.3", "once_cell", "parking_lot 0.12.1", "serde", @@ -1577,31 +1583,32 @@ dependencies = [ [[package]] name = "io-lifetimes" -version = "1.0.4" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e7d6c6f8c91b4b9ed43484ad1a938e393caf35960fce7f82a040497207bd8e9e" +checksum = "eae7b9aee968036d54dce06cebaefd919e4472e753296daccd6d344e3e2df0c2" dependencies = [ + "hermit-abi 0.3.2", "libc", - "windows-sys", + "windows-sys 0.48.0", ] [[package]] name = "ipnet" -version = "2.7.1" +version = "2.8.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "30e22bd8629359895450b59ea7a776c850561b96a3b1d31321c1949d9e6c9146" +checksum = "28b29a3cd74f0f4598934efe3aeba42bae0eb4680554128851ebbecb02af14e6" [[package]] name = "is-macro" -version = "0.2.1" +version = "0.2.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c068d4c6b922cd6284c609cfa6dec0e41615c9c5a1a4ba729a970d8daba05fb" +checksum = "8a7d079e129b77477a49c5c4f1cfe9ce6c2c909ef52520693e8e811a714c7b20" dependencies = [ "Inflector", "pmutil", "proc-macro2", "quote", - "syn", + "syn 1.0.109", ] [[package]] @@ -1624,15 +1631,15 @@ dependencies = [ [[package]] name = "itoa" -version = "1.0.5" +version = "1.0.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fad582f4b9e86b6caa621cabeb0963332d92eea04729ab12892c2533951e6440" +checksum = "af150ab688ff2122fcef229be89cb50dd66af9e01a4ff320cc137eecc9bacc38" [[package]] name = "js-sys" -version = "0.3.60" +version = "0.3.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "49409df3e3bf0856b916e2ceaca09ee28e6871cf7d9ce97a692cacfdb2a25a47" +checksum = "c5f195fe497f702db0f318b07fdd68edb16955aed830df8363d837542f8f935a" dependencies = [ "wasm-bindgen", ] @@ -1645,38 +1652,16 @@ dependencies = [ "dashmap", "deno_ast", "deno_core", - "dprint-swc-ext", "embassy_container_init", "helpers", "itertools 0.10.5", + "lazy_static", "models", "pin-project", "reqwest", "serde", "serde_json", - "sha2 0.10.6", - "swc_atoms", - "swc_common", - "swc_config", - "swc_config_macro", - "swc_ecma_ast", - "swc_ecma_codegen", - "swc_ecma_codegen_macros", - "swc_ecma_parser", - "swc_ecma_transforms", - "swc_ecma_transforms_base", - "swc_ecma_transforms_classes", - "swc_ecma_transforms_macros", - "swc_ecma_transforms_proposal", - "swc_ecma_transforms_react", - "swc_ecma_transforms_typescript", - "swc_ecma_utils", - "swc_ecma_visit", - "swc_ecmascript", - "swc_eq_ignore_macros", - "swc_macros_common", - "swc_visit", - "swc_visit_macros", + "sha2 0.10.7", "tokio", "tracing", ] @@ -1702,13 +1687,36 @@ dependencies = [ [[package]] name = "keccak" -version = "0.1.3" +version = "0.1.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3afef3b6eff9ce9d8ff9b3601125eec7f0c8cbac7abd14f355d053fa56c98768" +checksum = "8f6d5ed8676d904364de097082f4e7d240b571b67989ced0240f08b7f966f940" dependencies = [ "cpufeatures", ] +[[package]] +name = "lazy-regex" +version = "2.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ff63c423c68ea6814b7da9e88ce585f793c87ddd9e78f646970891769c8235d4" +dependencies = [ + "lazy-regex-proc_macros", + "once_cell", + "regex", +] + +[[package]] +name = "lazy-regex-proc_macros" +version = "2.4.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8edfc11b8f56ce85e207e62ea21557cfa09bb24a8f6b04ae181b086ff8611c22" +dependencies = [ + "proc-macro2", + "quote", + "regex", + "syn 1.0.109", +] + [[package]] name = "lazy_async_pool" version = "0.3.3" @@ -1803,24 +1811,15 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.139" +version = "0.2.147" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "201de327520df007757c1f0adce6e827fe8562fbc28bfd9c15571c66ca1f5f79" +checksum = "b4668fb0ea861c1df094127ac5f1da3409a82116a4ba74fca2e58ef927159bb3" [[package]] name = "libm" -version = "0.2.6" +version = "0.2.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "348108ab3fba42ec82ff6e9564fc4ca0247bdccdc68dd8af9764bbc79c3c8ffb" - -[[package]] -name = "link-cplusplus" -version = "1.0.8" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ecd207c9c713c34f95a097a5b029ac2ce6010530c7b49d7fea24d977dede04f5" -dependencies = [ - "cc", -] +checksum = "f7012b1bbb0719e1097c47611d3898568c546d597c2e74d66f6087edd5233ff4" [[package]] name = "linux-raw-sys" @@ -1829,10 +1828,16 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f051f77a7c8e6957c0696eac88f26b0117e54f52d3fc682ab19397a8812846a4" [[package]] -name = "lock_api" -version = "0.4.9" +name = "linux-raw-sys" +version = "0.3.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "435011366fe56583b16cf956f9df0095b405b82d76425bc8981c0e22e60ec4df" +checksum = "ef53942eb7bf7ff43a617b3e2c1c4a5ecf5944a7c1bc12d7ee39bbb15e5c1519" + +[[package]] +name = "lock_api" +version = "0.4.10" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c1cc9717a20b1bb222f333e6a92fd32f7d8a18ddc5a3191a11af45dcbf4dcd16" dependencies = [ "autocfg", "scopeguard", @@ -1840,12 +1845,9 @@ dependencies = [ [[package]] name = "log" -version = "0.4.17" +version = "0.4.19" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "abb12e687cfb44aa40f41fc3978ef76448f9b6038cad6aef4259d3c095a2382e" -dependencies = [ - "cfg-if", -] +checksum = "b06a4cde4c0f271a446782e3eff8de789548ce57dbc8eca9292c27f4a42004b4" [[package]] name = "matchers" @@ -1853,20 +1855,14 @@ version = "0.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8263075bb86c5a1b1427b5ae862e8889656f126e9f77c484496e8b47cf5c5558" dependencies = [ - "regex-automata", + "regex-automata 0.1.10", ] -[[package]] -name = "matches" -version = "0.1.9" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a3e378b66a060d48947b590737b30a1be76706c8dd7b8ba0f2fe3989c68a853f" - [[package]] name = "mbrman" -version = "0.5.1" +version = "0.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a4b239f4755d00466e3ac1d55ddeaf77a66c7580352fc6cbc40d56c218fc94a9" +checksum = "9c487024623ae38584610237dd1be8932bb2b324474b23c37a25f9fbe6bf5e9e" dependencies = [ "bincode", "bitvec", @@ -1881,7 +1877,7 @@ version = "0.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6365506850d44bff6e2fbcb5176cf63650e48bd45ef2fe2665ae1570e0f4b9ca" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -1901,9 +1897,9 @@ dependencies = [ [[package]] name = "mime" -version = "0.3.16" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a60c7ce501c71e03a9c9c0d35b861413ae925bd979cc7a4e30d060069aaac8d" +checksum = "6877bb514081ee2a7ff5ef9de3281f14a4dd4bceac4c09388074a6b5df8a139a" [[package]] name = "minimal-lexical" @@ -1913,23 +1909,22 @@ checksum = "68354c5c6bd36d73ff3feceb05efa59b6acb7626617f4962be322a825e61f79a" [[package]] name = "miniz_oxide" -version = "0.6.2" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b275950c28b37e794e8c55d88aeb5e139d0ce23fdbbeda68f8d7174abdf9e8fa" +checksum = "e7810e0be55b428ada41041c41f32c9f1a42817901b4ccf45fa3d4b6561e74c7" dependencies = [ "adler", ] [[package]] name = "mio" -version = "0.8.5" +version = "0.8.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5d732bc30207a6423068df043e3d02e0735b155ad7ce1a6f76fe2baa5b158de" +checksum = "927a765cd3fc26206e66b296465fa9d3e5ab003e651c1b3c060e7956d96b19d2" dependencies = [ "libc", - "log", "wasi 0.11.0+wasi-snapshot-preview1", - "windows-sys", + "windows-sys 0.48.0", ] [[package]] @@ -1989,7 +1984,7 @@ version = "0.23.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "8f3790c00a0150112de0f4cd161e3d7fc4b2d8a5542ffc35f099a2562aecb35c" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cc", "cfg-if", "libc", @@ -2002,7 +1997,7 @@ version = "0.24.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fa52e972a9a719cecb6864fb88568781eb706bac2cd1d4f04a648542dbf78069" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cfg-if", "libc", "memoffset", @@ -2015,7 +2010,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "f346ff70e7dbfd675fe90590b92d59ef2de15a8779ae305ebcbfd3f0caf59be4" dependencies = [ "autocfg", - "bitflags", + "bitflags 1.3.2", "cfg-if", "libc", "memoffset", @@ -2051,14 +2046,15 @@ dependencies = [ "autocfg", "num-integer", "num-traits", + "rand 0.8.5", "serde", ] [[package]] name = "num-bigint-dig" -version = "0.8.2" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2399c9463abc5f909349d8aa9ba080e0b88b3ce2885389b60b993f39b1a56905" +checksum = "dc84195820f291c7697304f3cbdadd1cb7199c0efc917ff5eafd71225c136151" dependencies = [ "byteorder", "lazy_static", @@ -2104,28 +2100,28 @@ dependencies = [ [[package]] name = "num_cpus" -version = "1.15.0" +version = "1.16.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fac9e2da13b5eb447a6ce3d392f23a29d8694bff781bf03a16cd9ac8697593b" +checksum = "4161fcb6d602d4d2081af7c3a45852d875a03dd337a6bfdd6e06407b61342a43" dependencies = [ - "hermit-abi 0.2.6", + "hermit-abi 0.3.2", "libc", ] [[package]] name = "object" -version = "0.30.2" +version = "0.31.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2b8c786513eb403643f2a88c244c2aaa270ef2153f55094587d0c48a3cf22a83" +checksum = "8bda667d9f2b5051b8833f59f3bf748b28ef54f850f4fcb389a252aa383866d1" dependencies = [ "memchr", ] [[package]] name = "once_cell" -version = "1.17.0" +version = "1.18.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6f61fba1741ea2b3d6a1e3178721804bb716a68a6aeba1149b5d52e3d464ea66" +checksum = "dd8b5dd2ae5ed71462c540258bedcb51965123ad7e7ccf4b9a8cafaa4a63576d" [[package]] name = "opaque-debug" @@ -2135,11 +2131,11 @@ checksum = "624a8340c38c1b80fd549087862da4ba43e08858af025b236e509b6649fc13d5" [[package]] name = "openssl" -version = "0.10.45" +version = "0.10.55" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b102428fd03bc5edf97f62620f7298614c45cedf287c271e7ed450bbaf83f2e1" +checksum = "345df152bc43501c5eb9e4654ff05f794effb78d4efe3d53abc158baddc0703d" dependencies = [ - "bitflags", + "bitflags 1.3.2", "cfg-if", "foreign-types", "libc", @@ -2150,13 +2146,13 @@ dependencies = [ [[package]] name = "openssl-macros" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b501e44f11665960c7e7fcf062c7d96a14ade4aa98116c004b2e37b5be7d736c" +checksum = "a948666b637a0f465e8564c73e89d4dde00d72d4d473cc972f390fc3dcee7d9c" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] @@ -2167,20 +2163,19 @@ checksum = "ff011a302c396a5197692431fc1948019154afc178baf7d8e37367442a4601cf" [[package]] name = "openssl-src" -version = "111.24.0+1.1.1s" +version = "111.26.0+1.1.1u" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3498f259dab01178c6228c6b00dcef0ed2a2d5e20d648c017861227773ea4abd" +checksum = "efc62c9f12b22b8f5208c23a7200a442b2e5999f8bdf80233852122b5a4f6f37" dependencies = [ "cc", ] [[package]] name = "openssl-sys" -version = "0.9.80" +version = "0.9.90" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23bbbf7854cd45b83958ebe919f0e8e516793727652e27fda10a8384cfc790b7" +checksum = "374533b0e45f3a7ced10fcaeccca020e66656bc03dac384f852e4e5a7a8104a6" dependencies = [ - "autocfg", "cc", "libc", "openssl-src", @@ -2190,9 +2185,9 @@ dependencies = [ [[package]] name = "os_str_bytes" -version = "6.4.1" +version = "6.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9b7820b9daea5457c9f21c69448905d723fbd21136ccf521748f23fd49e723ee" +checksum = "4d5d9eb14b174ee9aa2ef96dc2b94637a2d4b6e7cb873c7e171f0c20c6cf3eac" [[package]] name = "overload" @@ -2214,7 +2209,7 @@ checksum = "51f44edd08f51e2ade572f141051021c5af22677e42b7dd28a88155151c33594" dependencies = [ "ecdsa", "elliptic-curve", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -2225,7 +2220,7 @@ checksum = "dfc8c5bf642dde52bb9e87c0ecd8ca5a76faac2eeed98dedb7c717997e1080aa" dependencies = [ "ecdsa", "elliptic-curve", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -2246,7 +2241,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "3742b2c103b9f06bc9fff0a37ff4912935851bee6d36f3c02bcc755bcfec228f" dependencies = [ "lock_api", - "parking_lot_core 0.9.6", + "parking_lot_core 0.9.8", ] [[package]] @@ -2258,29 +2253,29 @@ dependencies = [ "cfg-if", "instant", "libc", - "redox_syscall", + "redox_syscall 0.2.16", "smallvec", "winapi", ] [[package]] name = "parking_lot_core" -version = "0.9.6" +version = "0.9.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba1ef8814b5c993410bb3adfad7a5ed269563e4a2f90c41f5d85be7fb47133bf" +checksum = "93f00c865fe7cabf650081affecd3871070f26767e7b2070a3ffae14c654b447" dependencies = [ "cfg-if", "libc", - "redox_syscall", + "redox_syscall 0.3.5", "smallvec", - "windows-sys", + "windows-targets 0.48.1", ] [[package]] name = "paste" -version = "1.0.11" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d01a5bd0424d00070b0098dd17ebca6f961a959dead1dbcbbbc1d1cd8d3deeba" +checksum = "de3145af08024dea9fa9914f381a17b8fc6034dfb00f3a84013f7ff43f29ed4c" [[package]] name = "patch-db" @@ -2310,7 +2305,7 @@ version = "0.1.0" dependencies = [ "patch-db-macro-internals", "proc-macro2", - "syn", + "syn 1.0.109", ] [[package]] @@ -2320,9 +2315,15 @@ dependencies = [ "heck 0.3.3", "proc-macro2", "quote", - "syn", + "syn 1.0.109", ] +[[package]] +name = "pathdiff" +version = "0.2.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8835116a5c179084a830efb3adc117ab007512b535bc1a21c991d3b32a6b44dd" + [[package]] name = "pem-rfc7468" version = "0.6.0" @@ -2334,9 +2335,9 @@ dependencies = [ [[package]] name = "percent-encoding" -version = "2.2.0" +version = "2.3.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "478c572c3d73181ff3c2539045f6eb99e5491218eae919370993b890cdbdd98e" +checksum = "9b2a4787296e9989611394c33f193f676704af1686e70b8f8033ab5ba9a35a94" [[package]] name = "phf" @@ -2370,7 +2371,7 @@ dependencies = [ "proc-macro-hack", "proc-macro2", "quote", - "syn", + "syn 1.0.109", ] [[package]] @@ -2384,29 +2385,29 @@ dependencies = [ [[package]] name = "pin-project" -version = "1.0.12" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ad29a609b6bcd67fee905812e544992d216af9d755757c05ed2d0e15a74c6ecc" +checksum = "030ad2bc4db10a8944cb0d837f158bdfec4d4a4873ab701a95046770d11f8842" dependencies = [ "pin-project-internal", ] [[package]] name = "pin-project-internal" -version = "1.0.12" +version = "1.1.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "069bdb1e05adc7a8990dce9cc75370895fbe4e3d58b9b73bf1aee56359344a55" +checksum = "ec2e072ecce94ec471b13398d5402c188e76ac03cf74dd1a975161b23a3f6d9c" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] name = "pin-project-lite" -version = "0.2.9" +version = "0.2.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e0a7ae3ac2f1173085d398531c705756c94a4c56843785df85a60c1a0afac116" +checksum = "4c40d25201921e5ff0c862a505c6557ea88568a4e3ace775ab55e93f2f4f9d57" [[package]] name = "pin-utils" @@ -2438,9 +2439,9 @@ dependencies = [ [[package]] name = "pkg-config" -version = "0.3.26" +version = "0.3.27" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ac9a59f73473f1b8d852421e59e64809f025994837ef743615c6d0c5b305160" +checksum = "26072860ba924cbfa98ea39c8c19b4dd6a4a25423dbdf219c1eca91aa0cf6964" [[package]] name = "pmutil" @@ -2450,7 +2451,7 @@ checksum = "3894e5d549cccbe44afecf72922f277f603cd4bb0219c8342631ef18fffbe004" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 1.0.109", ] [[package]] @@ -2467,13 +2468,12 @@ checksum = "925383efa346730478fb4838dbe9137d2a47675ad789c546d150a6e1dd4ab31c" [[package]] name = "proc-macro-crate" -version = "1.2.1" +version = "1.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eda0fc3b0fb7c975631757e14d9049da17374063edb6ebbcbc54d880d4fe94e9" +checksum = "7f4c021e1093a56626774e81216a4ce732a735e5bad4868a03f3ed65ca0c3919" dependencies = [ "once_cell", - "thiserror", - "toml", + "toml_edit", ] [[package]] @@ -2484,9 +2484,9 @@ checksum = "dc375e1527247fe1a97d8b7156678dfe7c1af2fc075c9a4db3690ecd2a148068" [[package]] name = "proc-macro2" -version = "1.0.50" +version = "1.0.66" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6ef7d57beacfaf2d8aee5937dab7b7f28de3cb8b1828479bb5de2a7106f2bae2" +checksum = "18fb31db3f9bddb2ea821cde30a9f70117e3f119938b5ee630b7403aa6e2ead9" dependencies = [ "unicode-ident", ] @@ -2497,20 +2497,29 @@ version = "0.14.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b1de8dacb0873f77e6aefc6d71e044761fcc68060290f5b1089fcdf84626bb69" dependencies = [ - "bitflags", + "bitflags 1.3.2", "byteorder", "chrono", "flate2", "hex", "lazy_static", - "rustix", + "rustix 0.36.15", +] + +[[package]] +name = "psm" +version = "0.1.21" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5787f7cda34e3033a72192c018bc5883100330f362ef279a8cbccfce8bb4e874" +dependencies = [ + "cc", ] [[package]] name = "quote" -version = "1.0.23" +version = "1.0.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8856d8364d252a14d474036ea1358d63c9e6965c8e5c1885c18f73d70bff9c7b" +checksum = "5fe8a65d69dd0808184ebb5f836ab526bb259db23c657efa38711b1072ee47f0" dependencies = [ "proc-macro2", ] @@ -2580,7 +2589,7 @@ version = "0.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "ec0be4795e2f6a28069bec0b5ff3e2ac9bafc99e6a9a7dc3547996c5c816922c" dependencies = [ - "getrandom 0.2.8", + "getrandom 0.2.10", ] [[package]] @@ -2607,7 +2616,16 @@ version = "0.2.16" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fb5a58c1855b4b6819d59012155603f0b22ad30cad752600aadfcb695265519a" dependencies = [ - "bitflags", + "bitflags 1.3.2", +] + +[[package]] +name = "redox_syscall" +version = "0.3.5" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "567664f262709473930a4bf9e51bf2ebf3348f2e748ccc50dea20646858f8f29" +dependencies = [ + "bitflags 1.3.2", ] [[package]] @@ -2616,20 +2634,21 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "b033d837a7cf162d7993aded9304e30a83213c648b6e389db233191f891e5c2b" dependencies = [ - "getrandom 0.2.8", - "redox_syscall", + "getrandom 0.2.10", + "redox_syscall 0.2.16", "thiserror", ] [[package]] name = "regex" -version = "1.7.1" +version = "1.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "48aaa5748ba571fb95cd2c85c09f629215d3a6ece942baa100950af03a34f733" +checksum = "b2eae68fc220f7cf2532e4494aded17545fce192d59cd996e0fe7887f4ceb575" dependencies = [ "aho-corasick", "memchr", - "regex-syntax", + "regex-automata 0.3.3", + "regex-syntax 0.7.4", ] [[package]] @@ -2638,31 +2657,39 @@ version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "6c230d73fb8d8c1b9c0b3135c5142a8acee3a0558fb8db5cf1cb65f8d7862132" dependencies = [ - "regex-syntax", + "regex-syntax 0.6.29", +] + +[[package]] +name = "regex-automata" +version = "0.3.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "39354c10dd07468c2e73926b23bb9c2caca74c5501e38a35da70406f1d923310" +dependencies = [ + "aho-corasick", + "memchr", + "regex-syntax 0.7.4", ] [[package]] name = "regex-syntax" -version = "0.6.28" +version = "0.6.29" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "456c603be3e8d448b072f410900c09faf164fbce2d480456f50eea6e25f9c848" +checksum = "f162c6dd7b008981e4d40210aca20b4bd0f9b60ca9271061b07f78537722f2e1" [[package]] -name = "remove_dir_all" -version = "0.5.3" +name = "regex-syntax" +version = "0.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3acd125665422973a33ac9d3dd2df85edad0f4ae9b00dafb1a05e43a9f5ef8e7" -dependencies = [ - "winapi", -] +checksum = "e5ea92a5b6195c6ef2a0295ea818b312502c6fc94dde986c5553242e18fd4ce2" [[package]] name = "reqwest" -version = "0.11.13" +version = "0.11.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68cc60575865c7831548863cc02356512e3f1dc2f3f82cb837d7fc4cc8f3c97c" +checksum = "cde824a14b7c14f85caff81225f411faacc04a2013f41670f41443742b1c1c55" dependencies = [ - "base64 0.13.1", + "base64 0.21.2", "bytes", "encoding_rs", "futures-core", @@ -2749,7 +2776,7 @@ checksum = "f8e4b9cb00baf2d61bcd35e98d67dcb760382a3b4540df7e63b38d053c8a7b8b" dependencies = [ "proc-macro2", "rpc-toolkit-macro-internals", - "syn", + "syn 1.0.109", ] [[package]] @@ -2760,7 +2787,7 @@ checksum = "d3e2ce21b936feaecdab9c9a8e75b9dca64374ccc11951a58045ad6559b75f42" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 1.0.109", ] [[package]] @@ -2770,7 +2797,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "094052d5470cbcef561cb848a7209968c9f12dfa6d668f4bca048ac5de51099c" dependencies = [ "byteorder", - "digest 0.10.6", + "digest 0.10.7", "num-bigint-dig", "num-integer", "num-iter", @@ -2786,9 +2813,9 @@ dependencies = [ [[package]] name = "rustc-demangle" -version = "0.1.21" +version = "0.1.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ef03e0a2b150c7a90d01faf6254c9c48a41e95fb2a8c2ac1c6f0d2b9aefc342" +checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" [[package]] name = "rustc-hash" @@ -2811,21 +2838,35 @@ version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "bfa0f585226d2e68097d4f95d113b15b83a82e819ab25717ec0590d9584ef366" dependencies = [ - "semver 1.0.16", + "semver 1.0.18", ] [[package]] name = "rustix" -version = "0.36.6" +version = "0.36.15" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4feacf7db682c6c329c4ede12649cd36ecab0f3be5b7d74e6a20304725db4549" +checksum = "c37f1bd5ef1b5422177b7646cba67430579cfe2ace80f284fee876bca52ad941" dependencies = [ - "bitflags", + "bitflags 1.3.2", "errno", "io-lifetimes", "libc", - "linux-raw-sys", - "windows-sys", + "linux-raw-sys 0.1.4", + "windows-sys 0.45.0", +] + +[[package]] +name = "rustix" +version = "0.37.23" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4d69718bf81c6127a49dc64e44a742e8bb9213c0ff8869a22c308f84c1d4ab06" +dependencies = [ + "bitflags 1.3.2", + "errno", + "io-lifetimes", + "libc", + "linux-raw-sys 0.3.8", + "windows-sys 0.48.0", ] [[package]] @@ -2842,26 +2883,32 @@ dependencies = [ [[package]] name = "rustls-pemfile" -version = "1.0.2" +version = "1.0.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d194b56d58803a43635bdc398cd17e383d6f71f9182b9a192c127ca42494a59b" +checksum = "2d3987094b1d07b653b7dfdc3f70ce9a1da9c51ac18c1b06b662e4f9a0e9f4b2" dependencies = [ - "base64 0.21.0", + "base64 0.21.2", ] [[package]] -name = "ryu" -version = "1.0.12" +name = "rustversion" +version = "1.0.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7b4b9743ed687d4b4bcedf9ff5eaa7398495ae14e61cba0a295704edbc7decde" +checksum = "7ffc183a10b4478d04cbbbfc96d0873219d962dd5accaff2ffbd4ceb7df837f4" + +[[package]] +name = "ryu" +version = "1.0.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1ad4cc8da4ef723ed60bced201181d83791ad433213d8c24efffda1eec85d741" [[package]] name = "schannel" -version = "0.1.21" +version = "0.1.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "713cfb06c7059f3588fb8044c0fad1d09e3c01d225e25b9220dbfdcf16dbb1b3" +checksum = "0c3733bf4cf7ea0880754e19cb5a462007c4a8c1914bff372ccc95b464f1df88" dependencies = [ - "windows-sys", + "windows-sys 0.48.0", ] [[package]] @@ -2872,15 +2919,9 @@ checksum = "e1cf6437eb19a8f4a6cc0f7dca544973b0b78843adbfeb3683d1a94a0024a294" [[package]] name = "scopeguard" -version = "1.1.0" +version = "1.2.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d29ab0c6d3fc0ee92fe66e2d99f700eab17a8d57d1c1d3b748380fb20baa78cd" - -[[package]] -name = "scratch" -version = "1.0.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ddccb15bcce173023b3fedd9436f882a0739b8dfb45e4f6b6002bee5929f61b2" +checksum = "94143f37725109f92c262ed2cf5e59bce7498c01bcc1502d7b9afe439a4e9f49" [[package]] name = "sct" @@ -2908,11 +2949,11 @@ dependencies = [ [[package]] name = "security-framework" -version = "2.7.0" +version = "2.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bc1bb97804af6631813c55739f771071e0f2ed33ee20b68c86ec505d906356c" +checksum = "1fc758eb7bffce5b308734e9b0c1468893cae9ff70ebf13e7090be8dcbcc83a8" dependencies = [ - "bitflags", + "bitflags 1.3.2", "core-foundation", "core-foundation-sys", "libc", @@ -2921,9 +2962,9 @@ dependencies = [ [[package]] name = "security-framework-sys" -version = "2.6.1" +version = "2.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0160a13a177a45bfb43ce71c01580998474f556ad854dcbca936dd2841a5c556" +checksum = "f51d0c0d83bec45f16480d0ce0058397a69e48fcdc52d1dc8855fb68acbd31a7" dependencies = [ "core-foundation-sys", "libc", @@ -2940,9 +2981,9 @@ dependencies = [ [[package]] name = "semver" -version = "1.0.16" +version = "1.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "58bc9567378fc7690d6b2addae4e60ac2eeea07becb2c64b9f218b53865cba2a" +checksum = "b0293b4b29daaf487284529cc2f5675b8e57c61f70167ba415a463651fd6a918" [[package]] name = "semver-parser" @@ -2952,9 +2993,9 @@ checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3" [[package]] name = "serde" -version = "1.0.152" +version = "1.0.164" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bb7d1f0d3021d347a83e556fc4683dea2ea09d87bccdf88ff5c12545d89d5efb" +checksum = "9e8c8cf938e98f769bc164923b06dce91cea1751522f46f8466461af04c9027d" dependencies = [ "serde_derive", ] @@ -2970,9 +3011,9 @@ dependencies = [ [[package]] name = "serde_bytes" -version = "0.11.8" +version = "0.11.10" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "718dc5fff5b36f99093fc49b280cfc96ce6fc824317783bff5a1fed0c7a64819" +checksum = "f3c5113243e4a3a1c96587342d067f3e6b0f50790b6cf40d2868eb647a3eef0e" dependencies = [ "serde", ] @@ -2997,22 +3038,22 @@ dependencies = [ [[package]] name = "serde_derive" -version = "1.0.152" +version = "1.0.164" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "af487d118eecd09402d70a5d72551860e788df87b464af30e5ea6a38c75c541e" +checksum = "d9735b638ccc51c28bf6914d90a2e9725b377144fc612c49a611fddd1b631d68" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] name = "serde_json" -version = "1.0.93" +version = "1.0.99" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cad406b69c91885b5107daf2c29572f6c8cdb3c66826821e286c533490c0bc76" +checksum = "46266871c240a00b8f503b877622fe33430b3c7d963bdc0f2adc511e54a1eae3" dependencies = [ - "indexmap", + "indexmap 2.0.0", "itoa", "ryu", "serde", @@ -3032,13 +3073,17 @@ dependencies = [ [[package]] name = "serde_v8" -version = "0.47.0" +version = "0.106.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3ca1daa2506c9d62744fff84d3534192f2e1c70cdf3bed95f298d89156c00b06" +checksum = "1506733ba5b864018c44320fa3bb11dbb4bf01b62dd09eda007be73034371c51" dependencies = [ "bytes", "derive_more", + "num-bigint", "serde", + "serde_bytes", + "smallvec", + "thiserror", "v8", ] @@ -3058,21 +3103,21 @@ version = "1.5.2" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e182d6ec6f05393cc0e5ed1bf81ad6db3a8feedf8ee515ecdd369809bcce8082" dependencies = [ - "darling 0.13.4", + "darling", "proc-macro2", "quote", - "syn", + "syn 1.0.109", ] [[package]] name = "sha-1" -version = "0.10.1" +version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f5058ada175748e33390e40e872bd0fe59a19f265d0158daa551c5a88a76009c" +checksum = "028f48d513f9678cda28f6e4064755b3fbb2af6acd672f2c209b62323f7aea0f" dependencies = [ "cfg-if", "cpufeatures", - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -3083,7 +3128,7 @@ checksum = "f04293dc80c3993519f2d7f6f511707ee7094fe0c6d3406feb330cdb3540eba3" dependencies = [ "cfg-if", "cpufeatures", - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -3101,13 +3146,13 @@ dependencies = [ [[package]] name = "sha2" -version = "0.10.6" +version = "0.10.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "82e6b795fe2e3b1e845bafcb27aa35405c4d47cdfc92af5fc8d3002f76cebdc0" +checksum = "479fb9d862239e610720565ca91403019f2f00410f1864c5aa7479b950a76ed8" dependencies = [ "cfg-if", "cpufeatures", - "digest 0.10.6", + "digest 0.10.7", ] [[package]] @@ -3133,9 +3178,9 @@ dependencies = [ [[package]] name = "signal-hook-registry" -version = "1.4.0" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e51e73328dc4ac0c7ccbda3a494dfa03df1de2f46018127f60c693f2648455b0" +checksum = "d8229b473baa5980ac72ef434c4415e70c4b5e71b423043adb4ba059f89c99a1" dependencies = [ "libc", ] @@ -3146,7 +3191,7 @@ version = "1.6.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "74233d3b3b2f6d4b006dc19dee745e73e2a6bfb6f93607cd3b02bd5b00797d7c" dependencies = [ - "digest 0.10.6", + "digest 0.10.7", "rand_core 0.6.4", ] @@ -3168,18 +3213,29 @@ dependencies = [ [[package]] name = "slab" -version = "0.4.7" +version = "0.4.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4614a76b2a8be0058caa9dbbaf66d988527d86d003c11a94fbd335d7661edcef" +checksum = "6528351c9bc8ab22353f9d776db39a20288e8d6c37ef8cfe3317cf875eecfc2d" dependencies = [ "autocfg", ] [[package]] name = "smallvec" -version = "1.10.0" +version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a507befe795404456341dfab10cef66ead4c041f62b8b11bbb92bffe5d0953e0" +checksum = "62bb4feee49fdd9f707ef802e22365a35de4b7b299de4763d44bfea899442ff9" + +[[package]] +name = "smartstring" +version = "1.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "3fb72c633efbaa2dd666986505016c32c3044395ceaf881518399d2f4127ee29" +dependencies = [ + "autocfg", + "static_assertions", + "version_check", +] [[package]] name = "snapshot_creator" @@ -3192,9 +3248,9 @@ dependencies = [ [[package]] name = "socket2" -version = "0.4.7" +version = "0.4.9" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "02e2d2db9033d13a1567121ddd7a095ee144db4e1ca1b1bda3419bc0da294ebd" +checksum = "64a4a911eed85daf18834cfaa86a79b7d266ff93ff5ba14005426219480ed662" dependencies = [ "libc", "winapi", @@ -3202,17 +3258,16 @@ dependencies = [ [[package]] name = "sourcemap" -version = "6.0.1" +version = "6.2.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6e031f2463ecbdd5f34c950f89f5c1e1032f22c0f8e3dc4bdb2e8b6658cf61eb" +checksum = "eed16231c92d0a6f0388f56e0ab2be24ecff1173f8e22f0ea5e074d0525631cb" dependencies = [ - "base64 0.11.0", + "data-encoding", "if_chain", - "lazy_static", - "regex", "rustc_version 0.2.3", "serde", "serde_json", + "unicode-id", "url", ] @@ -3245,9 +3300,9 @@ dependencies = [ [[package]] name = "sqlx" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9249290c05928352f71c077cc44a464d880c63f26f7534728cca008e135c0428" +checksum = "f8de3b03a925878ed54a954f621e64bf55a3c1bd29652d0d1a17830405350188" dependencies = [ "sqlx-core", "sqlx-macros", @@ -3255,14 +3310,14 @@ dependencies = [ [[package]] name = "sqlx-core" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "dcbc16ddba161afc99e14d1713a453747a2b07fc097d2009f4c300ec99286105" +checksum = "fa8241483a83a3f33aa5fff7e7d9def398ff9990b2752b6c6112b83c6d246029" dependencies = [ - "ahash", + "ahash 0.7.6", "atoi", "base64 0.13.1", - "bitflags", + "bitflags 1.3.2", "byteorder", "bytes", "chrono", @@ -3280,7 +3335,7 @@ dependencies = [ "hex", "hkdf", "hmac 0.12.1", - "indexmap", + "indexmap 1.9.3", "itoa", "libc", "log", @@ -3295,7 +3350,7 @@ dependencies = [ "serde", "serde_json", "sha1", - "sha2 0.10.6", + "sha2 0.10.7", "smallvec", "sqlformat", "sqlx-rt", @@ -3309,31 +3364,31 @@ dependencies = [ [[package]] name = "sqlx-macros" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b850fa514dc11f2ee85be9d055c512aa866746adfacd1cb42d867d68e6a5b0d9" +checksum = "9966e64ae989e7e575b19d7265cb79d7fc3cbbdf179835cb0d716f294c2049c9" dependencies = [ "dotenvy", "either", - "heck 0.4.0", + "heck 0.4.1", "hex", "once_cell", "proc-macro2", "quote", "serde", "serde_json", - "sha2 0.10.6", + "sha2 0.10.7", "sqlx-core", "sqlx-rt", - "syn", + "syn 1.0.109", "url", ] [[package]] name = "sqlx-rt" -version = "0.6.2" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24c5b2d25fa654cc5f841750b8e1cdedbe21189bf9a9382ee90bfa9dd3562396" +checksum = "804d3f245f894e61b1e6263c84b23ca675d96753b5abfd5cc8597d86806e8024" dependencies = [ "once_cell", "tokio", @@ -3348,7 +3403,7 @@ checksum = "19cfdc32e0199062113edf41f344fbf784b8205a94600233c84eb838f45191e1" dependencies = [ "base64ct", "pem-rfc7468", - "sha2 0.10.6", + "sha2 0.10.7", ] [[package]] @@ -3363,12 +3418,31 @@ dependencies = [ "rand_core 0.6.4", "rsa", "sec1", - "sha2 0.10.6", + "sha2 0.10.7", "signature", "ssh-encoding", "zeroize", ] +[[package]] +name = "stable_deref_trait" +version = "1.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "a8f112729512f8e442d81f95a8a7ddf2b7c6b8a1a6f509a95864142b30cab2d3" + +[[package]] +name = "stacker" +version = "0.1.15" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c886bd4480155fd3ef527d45e9ac8dd7118a898a46530b7b94c3e21866259fce" +dependencies = [ + "cc", + "cfg-if", + "libc", + "psm", + "winapi", +] + [[package]] name = "static_assertions" version = "1.1.0" @@ -3377,9 +3451,9 @@ checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" [[package]] name = "string_cache" -version = "0.8.4" +version = "0.8.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "213494b7a2b503146286049378ce02b482200519accc31872ee8be91fa820a08" +checksum = "f91138e76242f575eb1d3b38b4f1362f10d3a43f47d182a5b359af488a02293b" dependencies = [ "new_debug_unreachable", "once_cell", @@ -3403,39 +3477,55 @@ dependencies = [ [[package]] name = "string_enum" -version = "0.3.2" +version = "0.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "994453cd270ad0265796eb24abf5540091ed03e681c5f3c12bc33e4db33253e1" +checksum = "0090512bdfee4b56d82480d66c0fd8a6f53f0fe0f97e075e949b252acdd482e0" dependencies = [ "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn", + "syn 1.0.109", ] [[package]] name = "stringprep" -version = "0.1.2" +version = "0.1.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ee348cb74b87454fff4b551cbf727025810a004f88aeacae7f85b87f4e9a1c1" +checksum = "db3737bde7edce97102e0e2b15365bf7a20bfdb5f60f4f9e8d7004258a51a8da" dependencies = [ "unicode-bidi", "unicode-normalization", ] -[[package]] -name = "strsim" -version = "0.9.3" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6446ced80d6c486436db5c078dde11a9f73d42b57fb273121e160b84f63d894c" - [[package]] name = "strsim" version = "0.10.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "73473c0e59e6d5812c5dfe2a064a6444949f089e20eec9a2e5506596494e4623" +[[package]] +name = "strum" +version = "0.24.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "063e6045c0e62079840579a7e47a355ae92f60eb74daaf156fb1e84ba164e63f" +dependencies = [ + "strum_macros", +] + +[[package]] +name = "strum_macros" +version = "0.24.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1e385be0d24f186b4ce2f9982191e7101bb737312ad61c1f2f984f34bcf85d59" +dependencies = [ + "heck 0.4.1", + "proc-macro2", + "quote", + "rustversion", + "syn 1.0.109", +] + [[package]] name = "subtle" version = "2.4.1" @@ -3444,27 +3534,31 @@ checksum = "6bdef32e8150c2a081110b42772ffe7d7c9032b606bc226c8260fd97e0976601" [[package]] name = "swc_atoms" -version = "0.2.11" +version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ba8735ce37e421749498e038955abc1135eec6a4af0b54a173e55d2e5542d472" +checksum = "93d0307dc4bfd107d49c7528350c372758cfca94fb503629b9a056e6a1572860" dependencies = [ + "once_cell", + "rustc-hash", + "serde", "string_cache", "string_cache_codegen", + "triomphe", ] [[package]] name = "swc_common" -version = "0.18.7" +version = "0.31.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e4516bf4969a924bfd1801aed5c4b214687665898c14b7584d227827faff9d6c" +checksum = "19c774005489d2907fb67909cf42af926e72edee1366512777c605ba2ef19c94" dependencies = [ - "ahash", + "ahash 0.7.6", "ast_node", "better_scoped_tls", "cfg-if", - "debug_unreachable", "either", "from_variant", + "new_debug_unreachable", "num-bigint", "once_cell", "rustc-hash", @@ -3472,6 +3566,7 @@ dependencies = [ "siphasher", "sourcemap", "string_cache", + "swc_atoms", "swc_eq_ignore_macros", "swc_visit", "tracing", @@ -3481,12 +3576,11 @@ dependencies = [ [[package]] name = "swc_config" -version = "0.1.1" +version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b8bb05ef56c14b95dd7e62e95960153af811b9a447287f1f6ca59f1337fb83d4" +checksum = "89c8fc2c12bb1634c7c32fc3c9b6b963ad8f034cc62c4ecddcf215dc4f6f959d" dependencies = [ - "anyhow", - "indexmap", + "indexmap 1.9.3", "serde", "serde_json", "swc_config_macro", @@ -3494,23 +3588,24 @@ dependencies = [ [[package]] name = "swc_config_macro" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "fb64bc03d90fd5c90d6ab917bb2b1d7fbd31957df39e31ea24a3f554b4372251" +checksum = "7dadb9998d4f5fc36ef558ed5a092579441579ee8c6fcce84a5228cca9df4004" dependencies = [ "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn", + "syn 1.0.109", ] [[package]] name = "swc_ecma_ast" -version = "0.78.1" +version = "0.104.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "21f40169fe465e9a93cda5fe397c3afcb69be5ba2f76c4ab22137af6effaebcc" +checksum = "b5cf9dd351d0c285dcd36535267953a18995d4dda0cbe34ac9d1df61aa415b26" dependencies = [ + "bitflags 2.3.3", "is-macro", "num-bigint", "scoped-tls", @@ -3523,15 +3618,15 @@ dependencies = [ [[package]] name = "swc_ecma_codegen" -version = "0.108.6" +version = "0.139.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5eec1d30c8f85e8267a8efc66d680aa777902d567c3a05b7dfd42965a4872243" +checksum = "c66d1ea16bb9b7ea6f87f17325742ff256fcbd65b188af57c2bf415fe4afc945" dependencies = [ - "bitflags", "memchr", "num-bigint", "once_cell", "rustc-hash", + "serde", "sourcemap", "swc_atoms", "swc_common", @@ -3542,29 +3637,44 @@ dependencies = [ [[package]] name = "swc_ecma_codegen_macros" -version = "0.7.0" +version = "0.7.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "59949619b2ef45eedb6c399d05f2c3c7bc678b5074b3103bb670f9e05bb99042" +checksum = "bf4ee0caee1018808d94ecd09490cb7affd3d504b19aa11c49238f5fc4b54901" dependencies = [ "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn", + "syn 1.0.109", +] + +[[package]] +name = "swc_ecma_loader" +version = "0.43.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "fe45f1e5dcc1b005544ff78253b787dea5dfd5e2f712b133964cdc3545c954a4" +dependencies = [ + "ahash 0.7.6", + "anyhow", + "pathdiff", + "serde", + "swc_common", + "tracing", ] [[package]] name = "swc_ecma_parser" -version = "0.104.2" +version = "0.134.12" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a5fea08aeb2eb1469928ac7ca2d208fe7816871787e4d93e34924495e724bb25" +checksum = "f0a3fcfe3d83dd445cbd9321882e47b467594433d9a21c4d6c37a27f534bb89e" dependencies = [ "either", - "enum_kind", "lexical", "num-bigint", "serde", "smallvec", + "smartstring", + "stacker", "swc_atoms", "swc_common", "swc_ecma_ast", @@ -3572,30 +3682,15 @@ dependencies = [ "typed-arena", ] -[[package]] -name = "swc_ecma_transforms" -version = "0.154.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2bce21d9e8ff785aaf9b4ac11375d9f5767630fcaf882f72e6af0516224085a6" -dependencies = [ - "swc_atoms", - "swc_common", - "swc_ecma_ast", - "swc_ecma_transforms_base", - "swc_ecma_transforms_proposal", - "swc_ecma_transforms_react", - "swc_ecma_transforms_typescript", - "swc_ecma_utils", - "swc_ecma_visit", -] - [[package]] name = "swc_ecma_transforms_base" -version = "0.85.4" +version = "0.127.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "528c99be91500ed393e04e5cfc37763b4b68b71bc4f9b54ff0cd21d714920130" +checksum = "f9c33ec5369178f3a0580ab86cfe89ffb9c3fbd122aed379cfb71d469d9d61c1" dependencies = [ "better_scoped_tls", + "bitflags 2.3.3", + "indexmap 1.9.3", "once_cell", "phf", "rustc-hash", @@ -3612,9 +3707,9 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_classes" -version = "0.73.0" +version = "0.116.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e74a27c29def9db5ff03db4d3ab3d37701fb6d100951162223b71132908451eb" +checksum = "6e3b0d5f362f0da97be1f1b06d7b0d8667ea70b4adeabff0dcaecb6259c09525" dependencies = [ "swc_atoms", "swc_common", @@ -3626,24 +3721,25 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_macros" -version = "0.3.0" +version = "0.5.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "18712e4aab969c6508dff3540ade6358f1e013464aa58b3d30da2ab2d9fcbbed" +checksum = "984d5ac69b681fc5438f9abf82b0fda34fe04e119bc75f8213b7e01128c7c9a2" dependencies = [ "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn", + "syn 1.0.109", ] [[package]] name = "swc_ecma_transforms_proposal" -version = "0.107.0" +version = "0.161.22" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "47fc0f3b336764f89adf1899830321c3f5a7e845ede3ad5949eeb7468aa260ab" +checksum = "0cdce42d44ef775bc29f5ada3678a80ff72fa17a0ef705e14f63cfd0e0155e0e" dependencies = [ "either", + "rustc-hash", "serde", "smallvec", "swc_atoms", @@ -3658,16 +3754,15 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_react" -version = "0.114.1" +version = "0.173.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2fbfcd197ebeb0547b59dee39a164633bcf4fb0edbae886f8046e471e6a10502" +checksum = "5fb9481ad4e2acba34c6fbb6d4ccc64efe9f1821675e883dcfa732d7220f4b1e" dependencies = [ - "ahash", + "ahash 0.7.6", "base64 0.13.1", "dashmap", - "indexmap", + "indexmap 1.9.3", "once_cell", - "regex", "serde", "sha-1", "string_enum", @@ -3684,9 +3779,9 @@ dependencies = [ [[package]] name = "swc_ecma_transforms_typescript" -version = "0.117.2" +version = "0.177.23" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "96bf410ffcf91d85dc1f8f1bb969fa2637f9430a6917f2174ad76458c776cb89" +checksum = "1fe2eea4f5b8a25c93cdaa29fb1ce4108893da88a11e61e04b7f5295b5468829" dependencies = [ "serde", "swc_atoms", @@ -3700,24 +3795,27 @@ dependencies = [ [[package]] name = "swc_ecma_utils" -version = "0.85.1" +version = "0.117.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "031ac49cf598f00f048fecd87b3bda5e14b86f6ccd561ada7fce461e0a3ea8d1" +checksum = "ad791bbfdafcebd878584021e050964c8ab68aba7eeac9d0ee4afba4c284a629" dependencies = [ - "indexmap", + "indexmap 1.9.3", + "num_cpus", "once_cell", + "rustc-hash", "swc_atoms", "swc_common", "swc_ecma_ast", "swc_ecma_visit", "tracing", + "unicode-id", ] [[package]] name = "swc_ecma_visit" -version = "0.64.0" +version = "0.90.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f2d3783a0dd1e301ae2945ab1241405f913427f9512ec62756d3d2072f7c21bb" +checksum = "6ce3ac941ae1d6c7e683aa375fc71fbf58df58b441f614d757fbb10554936ca2" dependencies = [ "num-bigint", "swc_atoms", @@ -3727,49 +3825,35 @@ dependencies = [ "tracing", ] -[[package]] -name = "swc_ecmascript" -version = "0.157.0" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bd35679e1dc392f776b691b125692d90a7bebd5d23ec96699cfe37d8ae8633b1" -dependencies = [ - "swc_ecma_ast", - "swc_ecma_codegen", - "swc_ecma_parser", - "swc_ecma_transforms", - "swc_ecma_utils", - "swc_ecma_visit", -] - [[package]] name = "swc_eq_ignore_macros" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c8f200a2eaed938e7c1a685faaa66e6d42fa9e17da5f62572d3cbc335898f5e" +checksum = "0c20468634668c2bbab581947bb8c75c97158d5a6959f4ba33df20983b20b4f6" dependencies = [ "pmutil", "proc-macro2", "quote", - "syn", + "syn 1.0.109", ] [[package]] name = "swc_macros_common" -version = "0.3.5" +version = "0.3.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d5dca3f08d02da4684c3373150f7c045128f81ea00f0c434b1b012bc65a6cce3" +checksum = "3e582c3e3c2269238524923781df5be49e011dbe29cf7683a2215d600a562ea6" dependencies = [ "pmutil", "proc-macro2", "quote", - "syn", + "syn 1.0.109", ] [[package]] name = "swc_visit" -version = "0.3.0" +version = "0.5.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e5c639379dd2a8a0221fa1e12fafbdd594ba53a0cace6560054da52409dfcc1a" +checksum = "5f412dd4fbc58f509a04e64f5c8038333142fc139e8232f01b883db0094b3b51" dependencies = [ "either", "swc_visit_macros", @@ -3777,23 +3861,23 @@ dependencies = [ [[package]] name = "swc_visit_macros" -version = "0.3.1" +version = "0.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c3b9b72892df873972549838bf84d6c56234c7502148a7e23b5a3da6e0fedfb8" +checksum = "4cfc226380ba54a5feed2c12f3ccd33f1ae8e959160290e5d2d9b4e918b6472a" dependencies = [ "Inflector", "pmutil", "proc-macro2", "quote", "swc_macros_common", - "syn", + "syn 1.0.109", ] [[package]] name = "syn" -version = "1.0.107" +version = "1.0.109" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f4064b5b16e03ae50984a5a8ed5d4f8803e6bc1fd170a3cda91a1be4b18e3f5" +checksum = "72b64191b275b66ffe2469e8af2c1cfe3bafa67b529ead792a6d0160888b4237" dependencies = [ "proc-macro2", "quote", @@ -3801,15 +3885,14 @@ dependencies = [ ] [[package]] -name = "synstructure" -version = "0.12.6" +name = "syn" +version = "2.0.18" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f36bdaa60a83aca3921b5259d5400cbf5e90fc51931376a9bd4a0eb79aa7210f" +checksum = "32d41677bcbe24c20c52e7c70b0d8db04134c5d1066bf98662e2871ad200ea3e" dependencies = [ "proc-macro2", "quote", - "syn", - "unicode-xid", + "unicode-ident", ] [[package]] @@ -3820,16 +3903,16 @@ checksum = "55937e1799185b12863d447f42597ed69d9928686b8d88a1df17376a097d8369" [[package]] name = "tempfile" -version = "3.3.0" +version = "3.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5cdb1ef4eaeeaddc8fbd371e5017057064af0911902ef36b39801f67cc6d79e4" +checksum = "31c0432476357e58790aaa47a8efb0c5138f137343f3b5f23bd36a27e3b0a6d6" dependencies = [ + "autocfg", "cfg-if", "fastrand", - "libc", - "redox_syscall", - "remove_dir_all", - "winapi", + "redox_syscall 0.3.5", + "rustix 0.37.23", + "windows-sys 0.48.0", ] [[package]] @@ -3843,9 +3926,9 @@ dependencies = [ [[package]] name = "text_lines" -version = "0.4.1" +version = "0.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e49e3c53dd04de8b8e8390bc4fab57f6db7af7d33b086fe411803e6351c9f9f9" +checksum = "7fd5828de7deaa782e1dd713006ae96b3bee32d3279b79eb67ecf8072c059bcf" dependencies = [ "serde", ] @@ -3858,30 +3941,31 @@ checksum = "222a222a5bfe1bba4a77b45ec488a741b3cb8872e5e499451fd7d0129c9c7c3d" [[package]] name = "thiserror" -version = "1.0.38" +version = "1.0.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a9cd18aa97d5c45c6603caea1da6628790b37f7a34b6ca89522331c5180fed0" +checksum = "978c9a314bd8dc99be594bc3c175faaa9794be04a5a5e153caba6915336cebac" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.38" +version = "1.0.40" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1fb327af4685e4d03fa8cbcf1716380da910eeb2bb8be417e7f9fd3fb164f36f" +checksum = "f9456a42c5b0d803c8cd86e73dd7cc9edd429499f37a3550d286d5e86720569f" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] name = "thread_local" -version = "1.1.4" +version = "1.1.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5516c27b78311c50bf42c071425c560ac799b11c30b31f87e3081965fe5e0180" +checksum = "3fdd6f064ccff2d6567adcb3873ca630700f00b5ad3f060c25b5dcfd9a4ce152" dependencies = [ + "cfg-if", "once_cell", ] @@ -3896,20 +3980,20 @@ dependencies = [ [[package]] name = "tinyvec_macros" -version = "0.1.0" +version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "cda74da7e1a664f795bb1f8a87ec406fb89a02522cf6e50620d016add6dbbf5c" +checksum = "1f3ccbac311fea05f86f61904b462b55fb3df8837a366dfc601a0161d0532f20" [[package]] name = "tokio" -version = "1.24.1" +version = "1.29.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1d9f76183f91ecfb55e1d7d5602bd1d979e38a3a522fe900241cf195624d67ae" +checksum = "532826ff75199d5833b9d2c5fe410f29235e25704ee5f0ef599fb51c21f4a4da" dependencies = [ "autocfg", + "backtrace", "bytes", "libc", - "memchr", "mio", "num_cpus", "parking_lot 0.12.1", @@ -3917,25 +4001,25 @@ dependencies = [ "signal-hook-registry", "socket2", "tokio-macros", - "windows-sys", + "windows-sys 0.48.0", ] [[package]] name = "tokio-macros" -version = "1.8.2" +version = "2.1.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d266c00fde287f55d3f1c3e96c500c362a2b8c695076ec180f27918820bc6df8" +checksum = "630bdcf245f78637c13ec01ffae6187cca34625e8c63150d424b59e55af2675e" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] name = "tokio-native-tls" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f7d995660bd2b7f8c1568414c1126076c13fbb725c40112dc0120b78eb9b717b" +checksum = "bbae76ab933c85776efabc971569dd6119c580d8f5d448769dec1764bf796ef2" dependencies = [ "native-tls", "tokio", @@ -3954,9 +4038,9 @@ dependencies = [ [[package]] name = "tokio-stream" -version = "0.1.11" +version = "0.1.14" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d660770404473ccd7bc9f8b28494a811bc18542b915c0855c51e8f419d5223ce" +checksum = "397c988d37662c7dda6d2208364a706264bf3d6138b11d436cbac0ad38832842" dependencies = [ "futures-core", "pin-project-lite", @@ -3966,9 +4050,9 @@ dependencies = [ [[package]] name = "tokio-util" -version = "0.7.4" +version = "0.7.8" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0bb2e075f03b3d66d8d8785356224ba688d2906a371015e225beeb65ca92c740" +checksum = "806fe8c2c87eccc8b3267cbae29ed3ab2d0bd37fca70ab622e46aaa9375ddb7d" dependencies = [ "bytes", "futures-core", @@ -3979,12 +4063,20 @@ dependencies = [ ] [[package]] -name = "toml" -version = "0.5.10" +name = "toml_datetime" +version = "0.6.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1333c76748e868a4d9d1017b5ab53171dfd095f70c712fdb4653a406547f598f" +checksum = "7cda73e2f1397b1262d6dfdcef8aafae14d1de7748d66822d3bfeeb6d03e5e4b" + +[[package]] +name = "toml_edit" +version = "0.19.14" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "f8123f27e969974a3dfba720fdb560be359f57b44302d280ba72e76a74480e8a" dependencies = [ - "serde", + "indexmap 2.0.0", + "toml_datetime", + "winnow", ] [[package]] @@ -4027,20 +4119,20 @@ dependencies = [ [[package]] name = "tracing-attributes" -version = "0.1.23" +version = "0.1.26" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4017f8f45139870ca7e672686113917c71c7a6e02d4924eda67186083c03081a" +checksum = "5f4f31f56159e98206da9efd823404b79b6ef3143b4a7ab76e67b1751b25a4ab" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", ] [[package]] name = "tracing-core" -version = "0.1.30" +version = "0.1.31" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "24eb03ba0eab1fd845050058ce5e616558e8f8d8fca633e6b163fe25c797213a" +checksum = "0955b8137a1df6f1a2e9a37d8a6656291ff0297c1a97c24e0d8425fe2312f79a" dependencies = [ "once_cell", "valuable", @@ -4063,7 +4155,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d686ec1c0f384b1277f097b2f279a2ecc11afe8c133c1aabf036a27cb4cd206e" dependencies = [ "tracing", - "tracing-subscriber 0.3.16", + "tracing-subscriber 0.3.17", ] [[package]] @@ -4100,9 +4192,9 @@ dependencies = [ [[package]] name = "tracing-subscriber" -version = "0.3.16" +version = "0.3.17" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a6176eae26dd70d0c919749377897b54a9276bd7061339665dd68777926b5a70" +checksum = "30a651bc37f915e81f087d86e62a18eec5f79550c7faff886f7090b4ea757c77" dependencies = [ "matchers", "nu-ansi-term", @@ -4125,6 +4217,16 @@ dependencies = [ "serde_json", ] +[[package]] +name = "triomphe" +version = "0.1.9" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "0eee8098afad3fb0c54a9007aab6804558410503ad676d4633f9c2559a00ac0f" +dependencies = [ + "serde", + "stable_deref_trait", +] + [[package]] name = "try-lock" version = "0.2.4" @@ -4145,9 +4247,9 @@ checksum = "497961ef93d974e23eb6f433eb5fe1b7930b659f06d12dec6fc44a8f554c0bba" [[package]] name = "unicode-bidi" -version = "0.3.8" +version = "0.3.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "099b7128301d285f79ddd55b9a83d5e6b9e97c92e0ea0daebee7263e932de992" +checksum = "92888ba5573ff080736b3648696b70cafad7d250551175acbaa4e0385b3e1460" [[package]] name = "unicode-id" @@ -4157,9 +4259,9 @@ checksum = "d70b6494226b36008c8366c288d77190b3fad2eb4c10533139c1c1f461127f1a" [[package]] name = "unicode-ident" -version = "1.0.6" +version = "1.0.11" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "84a22b9f218b40614adcb3f4ff08b703773ad44fa9423e4e0d346d5db86e4ebc" +checksum = "301abaae475aa91687eb82514b328ab47a211a533026cb25fc3e519b86adfc3c" [[package]] name = "unicode-normalization" @@ -4172,9 +4274,9 @@ dependencies = [ [[package]] name = "unicode-segmentation" -version = "1.10.0" +version = "1.10.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0fdbf052a0783de01e944a6ce7a8cb939e295b1e7be835a1112c3b9a7f047a5a" +checksum = "1dd624098567895118886609431a7c3b8f516e41d30e0643f03d94592a147e36" [[package]] name = "unicode-width" @@ -4182,27 +4284,12 @@ version = "0.1.10" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "c0edd1e5b14653f783770bce4a4dabb4a5108a5370a5f5d8cfe8710c361f6c8b" -[[package]] -name = "unicode-xid" -version = "0.2.4" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "f962df74c8c05a667b5ee8bcf162993134c104e96440b663c8daa176dc772d8c" - [[package]] name = "unicode_categories" version = "0.1.1" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "39ec24b3121d976906ece63c9daad25b85969647682eee313cb5779fdd69e14e" -[[package]] -name = "unreachable" -version = "0.1.1" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1f2ae5ddb18e1c92664717616dd9549dde73f539f01bd7b77c2edb2446bdff91" -dependencies = [ - "void", -] - [[package]] name = "untrusted" version = "0.7.1" @@ -4211,9 +4298,9 @@ checksum = "a156c684c91ea7d62626509bce3cb4e1d9ed5c4d978f7b4352658f96a4c26b4a" [[package]] name = "url" -version = "2.3.1" +version = "2.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "0d68c799ae75762b8c3fe375feb6600ef5602c883c5d21eb51c09f22b83c4643" +checksum = "50bff7831e19200a85b17131d085c25d7811bc4e186efdaf54bbd132994a88cb" dependencies = [ "form_urlencoded", "idna", @@ -4223,14 +4310,13 @@ dependencies = [ [[package]] name = "v8" -version = "0.43.1" +version = "0.74.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c87ec36fec9ea2cd5a368ae9d0a662a7c5e8caa8768ec1fcc02bea623681b98" +checksum = "7568bf38565bd5b350d96abbf3d09417e8c9dd74fbb38860e91b759e46f9009c" dependencies = [ - "bitflags", + "bitflags 1.3.2", "fslock", - "lazy_static", - "libc", + "once_cell", "which", ] @@ -4252,19 +4338,12 @@ version = "0.9.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "49874b5167b65d7193b8aba1567f5c7d93d001cafc34600cee003eda787e483f" -[[package]] -name = "void" -version = "1.0.2" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d" - [[package]] name = "want" -version = "0.3.0" +version = "0.3.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1ce8a968cb1cd110d136ff8b819a556d6fb6d919363c61534f6860c7eb172ba0" +checksum = "bfa7760aed19e106de2c7c0b581b509f2f25d3dacaf737cb82ac61bc6d760b0e" dependencies = [ - "log", "try-lock", ] @@ -4282,9 +4361,9 @@ checksum = "9c8d87e72b64a3b4db28d11ce29237c246188f4f51057d65a7eab63b7987e423" [[package]] name = "wasm-bindgen" -version = "0.2.83" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "eaf9f5aceeec8be17c128b2e93e031fb8a4d469bb9c4ae2d7dc1888b26887268" +checksum = "7706a72ab36d8cb1f80ffbf0e071533974a60d0a308d01a5d0375bf60499a342" dependencies = [ "cfg-if", "wasm-bindgen-macro", @@ -4292,24 +4371,24 @@ dependencies = [ [[package]] name = "wasm-bindgen-backend" -version = "0.2.83" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8ffb332579b0557b52d268b91feab8df3615f265d5270fec2a8c95b17c1142" +checksum = "5ef2b6d3c510e9625e5fe6f509ab07d66a760f0885d858736483c32ed7809abd" dependencies = [ "bumpalo", "log", "once_cell", "proc-macro2", "quote", - "syn", + "syn 2.0.18", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-futures" -version = "0.4.33" +version = "0.4.37" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "23639446165ca5a5de86ae1d8896b737ae80319560fbaa4c2887b7da6e7ebd7d" +checksum = "c02dbc21516f9f1f04f187958890d7e6026df8d16540b7ad9492bc34a67cea03" dependencies = [ "cfg-if", "js-sys", @@ -4319,9 +4398,9 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro" -version = "0.2.83" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "052be0f94026e6cbc75cdefc9bae13fd6052cdcaf532fa6c45e7ae33a1e6c810" +checksum = "dee495e55982a3bd48105a7b947fd2a9b4a8ae3010041b9e0faab3f9cd028f1d" dependencies = [ "quote", "wasm-bindgen-macro-support", @@ -4329,28 +4408,28 @@ dependencies = [ [[package]] name = "wasm-bindgen-macro-support" -version = "0.2.83" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "07bc0c051dc5f23e307b13285f9d75df86bfdf816c5721e573dec1f9b8aa193c" +checksum = "54681b18a46765f095758388f2d0cf16eb8d4169b639ab575a8f5693af210c7b" dependencies = [ "proc-macro2", "quote", - "syn", + "syn 2.0.18", "wasm-bindgen-backend", "wasm-bindgen-shared", ] [[package]] name = "wasm-bindgen-shared" -version = "0.2.83" +version = "0.2.87" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c38c045535d93ec4f0b4defec448e4291638ee608530863b1e2ba115d4fff7f" +checksum = "ca6ad05a4870b2bf5fe995117d3728437bd27d7cd5f06f13c17443ef369775a1" [[package]] name = "web-sys" -version = "0.3.60" +version = "0.3.64" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bcda906d8be16e728fd5adc5b729afad4e444e106ab28cd1c7256e54fa61510f" +checksum = "9b85cbef8c220a6abc02aefd892dfc0fc23afb1c6a426316ec33253a3877249b" dependencies = [ "js-sys", "wasm-bindgen", @@ -4377,9 +4456,9 @@ dependencies = [ [[package]] name = "which" -version = "4.3.0" +version = "4.4.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "1c831fbbee9e129a8cf93e7747a82da9d95ba8e16621cae60ec2cdc849bacb7b" +checksum = "2441c784c52b289a054b7201fc93253e288f094e2f4be9058343127c4226a269" dependencies = [ "either", "libc", @@ -4388,9 +4467,9 @@ dependencies = [ [[package]] name = "whoami" -version = "1.3.0" +version = "1.4.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "45dbc71f0cdca27dc261a9bd37ddec174e4a0af2b900b890f378460f745426e3" +checksum = "22fc3756b8a9133049b26c7f61ab35416c130e8c09b660f5b3958b446f52cc50" dependencies = [ "wasm-bindgen", "web-sys", @@ -4428,61 +4507,154 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "712e227841d057c1ee1cd2fb22fa7e5a5461ae8e48fa2ca79ec42cfc1931183f" [[package]] -name = "windows-sys" -version = "0.42.0" +name = "windows" +version = "0.48.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5a3e1820f08b8513f676f7ab6c1f99ff312fb97b553d30ff4dd86f9f15728aa7" +checksum = "e686886bc078bc1b0b600cac0147aadb815089b6e4da64016cbd754b6342700f" dependencies = [ - "windows_aarch64_gnullvm", - "windows_aarch64_msvc", - "windows_i686_gnu", - "windows_i686_msvc", - "windows_x86_64_gnu", - "windows_x86_64_gnullvm", - "windows_x86_64_msvc", + "windows-targets 0.48.1", +] + +[[package]] +name = "windows-sys" +version = "0.45.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "75283be5efb2831d37ea142365f009c02ec203cd29a3ebecbc093d52315b66d0" +dependencies = [ + "windows-targets 0.42.2", +] + +[[package]] +name = "windows-sys" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "677d2418bec65e3338edb076e806bc1ec15693c5d0104683f2efe857f61056a9" +dependencies = [ + "windows-targets 0.48.1", +] + +[[package]] +name = "windows-targets" +version = "0.42.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "8e5180c00cd44c9b1c88adb3693291f1cd93605ded80c250a75d472756b4d071" +dependencies = [ + "windows_aarch64_gnullvm 0.42.2", + "windows_aarch64_msvc 0.42.2", + "windows_i686_gnu 0.42.2", + "windows_i686_msvc 0.42.2", + "windows_x86_64_gnu 0.42.2", + "windows_x86_64_gnullvm 0.42.2", + "windows_x86_64_msvc 0.42.2", +] + +[[package]] +name = "windows-targets" +version = "0.48.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "05d4b17490f70499f20b9e791dcf6a299785ce8af4d709018206dc5b4953e95f" +dependencies = [ + "windows_aarch64_gnullvm 0.48.0", + "windows_aarch64_msvc 0.48.0", + "windows_i686_gnu 0.48.0", + "windows_i686_msvc 0.48.0", + "windows_x86_64_gnu 0.48.0", + "windows_x86_64_gnullvm 0.48.0", + "windows_x86_64_msvc 0.48.0", ] [[package]] name = "windows_aarch64_gnullvm" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8c9864e83243fdec7fc9c5444389dcbbfd258f745e7853198f365e3c4968a608" +checksum = "597a5118570b68bc08d8d59125332c54f1ba9d9adeedeef5b99b02ba2b0698f8" + +[[package]] +name = "windows_aarch64_gnullvm" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "91ae572e1b79dba883e0d315474df7305d12f569b400fcf90581b06062f7e1bc" [[package]] name = "windows_aarch64_msvc" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "4c8b1b673ffc16c47a9ff48570a9d85e25d265735c503681332589af6253c6c7" +checksum = "e08e8864a60f06ef0d0ff4ba04124db8b0fb3be5776a5cd47641e942e58c4d43" + +[[package]] +name = "windows_aarch64_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b2ef27e0d7bdfcfc7b868b317c1d32c641a6fe4629c171b8928c7b08d98d7cf3" [[package]] name = "windows_i686_gnu" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "de3887528ad530ba7bdbb1faa8275ec7a1155a45ffa57c37993960277145d640" +checksum = "c61d927d8da41da96a81f029489353e68739737d3beca43145c8afec9a31a84f" + +[[package]] +name = "windows_i686_gnu" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "622a1962a7db830d6fd0a69683c80a18fda201879f0f447f065a3b7467daa241" [[package]] name = "windows_i686_msvc" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "bf4d1122317eddd6ff351aa852118a2418ad4214e6613a50e0191f7004372605" +checksum = "44d840b6ec649f480a41c8d80f9c65108b92d89345dd94027bfe06ac444d1060" + +[[package]] +name = "windows_i686_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "4542c6e364ce21bf45d69fdd2a8e455fa38d316158cfd43b3ac1c5b1b19f8e00" [[package]] name = "windows_x86_64_gnu" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c1040f221285e17ebccbc2591ffdc2d44ee1f9186324dd3e84e99ac68d699c45" +checksum = "8de912b8b8feb55c064867cf047dda097f92d51efad5b491dfb98f6bbb70cb36" + +[[package]] +name = "windows_x86_64_gnu" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "ca2b8a661f7628cbd23440e50b05d705db3686f894fc9580820623656af974b1" [[package]] name = "windows_x86_64_gnullvm" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "628bfdf232daa22b0d64fdb62b09fcc36bb01f05a3939e20ab73aaf9470d0463" +checksum = "26d41b46a36d453748aedef1486d5c7a85db22e56aff34643984ea85514e94a3" + +[[package]] +name = "windows_x86_64_gnullvm" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "7896dbc1f41e08872e9d5e8f8baa8fdd2677f29468c4e156210174edc7f7b953" [[package]] name = "windows_x86_64_msvc" -version = "0.42.1" +version = "0.42.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "447660ad36a13288b1db4d4248e857b510e8c3a225c822ba4fb748c0aafecffd" +checksum = "9aec5da331524158c6d1a4ac0ab1541149c0b9505fde06423b02f5ef0106b9f0" + +[[package]] +name = "windows_x86_64_msvc" +version = "0.48.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "1a515f5799fe4961cb532f983ce2b23082366b898e52ffbce459c86f67c8378a" + +[[package]] +name = "winnow" +version = "0.5.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "81fac9742fd1ad1bd9643b991319f72dd031016d44b77039a26977eb667141e7" +dependencies = [ + "memchr", +] [[package]] name = "winreg" @@ -4527,21 +4699,20 @@ dependencies = [ [[package]] name = "zeroize" -version = "1.5.7" +version = "1.6.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c394b5bd0c6f669e7275d9c20aa90ae064cb22e75a1cad54e1b34088034b149f" +checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" dependencies = [ "zeroize_derive", ] [[package]] name = "zeroize_derive" -version = "1.3.3" +version = "1.4.2" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "44bf07cb3e50ea2003396695d58bf46bc9887a1f362260446fad6bc4e79bd36c" +checksum = "ce36e65b0d2999d2aafac989fb249189a141aee1f53c612c1f37d72631959f69" dependencies = [ "proc-macro2", "quote", - "syn", - "synstructure", + "syn 2.0.18", ] diff --git a/libs/build-arm-v8-snapshot.sh b/libs/build-arm-v8-snapshot.sh index 438f3484a..19e700dc4 100755 --- a/libs/build-arm-v8-snapshot.sh +++ b/libs/build-arm-v8-snapshot.sh @@ -2,6 +2,7 @@ # Reason for this being is that we need to create a snapshot for the deno runtime. It wants to pull 3 files from build, and during the creation it gets embedded, but for some # reason during the actual runtime it is looking for them. So this will create a docker in arm that creates the snaphot needed for the arm set -e +shopt -s expand_aliases if [ "$0" != "./build-arm-v8-snapshot.sh" ]; then >&2 echo "Must be run from backend/workspace directory" @@ -13,9 +14,11 @@ if tty -s; then USE_TTY="-it" fi +alias 'rust-gnu-builder'='docker run $USE_TTY --rm -v "$HOME/.cargo/registry":/usr/local/cargo/registry -v "$(pwd)":/home/rust/src -w /home/rust/src -P start9/rust-arm-cross:aarch64' + echo "Building " cd .. -docker run --rm $USE_TTY -v "$HOME/.cargo/registry":/root/.cargo/registry -v "$(pwd)":/home/rust/src start9/rust-arm-cross:aarch64 sh -c "(cd libs/ && cargo build -p snapshot_creator --release )" +rust-gnu-builder sh -c "(cd libs/ && cargo build -p snapshot_creator --release --target=aarch64-unknown-linux-gnu)" cd - echo "Creating Arm v8 Snapshot" diff --git a/libs/embassy_container_init/src/main.rs b/libs/embassy_container_init/src/main.rs index 0764382c0..17db5d74c 100644 --- a/libs/embassy_container_init/src/main.rs +++ b/libs/embassy_container_init/src/main.rs @@ -371,7 +371,7 @@ async fn main() { tracing::error!("Error sending to {id:?}", id = req.id); } } - Err(e) => + Err(e) => if let Err(err) = w .lock() .await diff --git a/libs/js_engine/Cargo.toml b/libs/js_engine/Cargo.toml index 15154b6f7..299eb9fdb 100644 --- a/libs/js_engine/Cargo.toml +++ b/libs/js_engine/Cargo.toml @@ -8,35 +8,13 @@ edition = "2021" [dependencies] async-trait = "0.1.56" dashmap = "5.3.4" -deno_core = "=0.136.0" -deno_ast = { version = "=0.15.0", features = ["transpiling"] } -dprint-swc-ext = "=0.1.1" +deno_core = "0.195.0" +deno_ast = { version = "0.27.2", features = ["transpiling"] } embassy_container_init = { path = "../embassy_container_init" } reqwest = { version = "0.11.11" } -swc_atoms = "=0.2.11" -swc_common = "=0.18.7" -swc_config = "=0.1.1" -swc_config_macro = "=0.1.0" -swc_ecma_ast = "=0.78.1" -swc_ecma_codegen = "=0.108.6" -swc_ecma_codegen_macros = "=0.7.0" -swc_ecma_parser = "=0.104.2" -swc_ecma_transforms = "=0.154.0" -swc_ecma_transforms_base = "=0.85.4" -swc_ecma_transforms_classes = "=0.73.0" -swc_ecma_transforms_macros = "=0.3.0" -swc_ecma_transforms_proposal = "=0.107.0" -swc_ecma_transforms_react = "=0.114.1" -swc_ecma_transforms_typescript = "=0.117.2" -swc_ecma_utils = "=0.85.1" -swc_ecma_visit = "=0.64.0" -swc_ecmascript = "=0.157.0" -swc_eq_ignore_macros = "=0.1.0" -swc_macros_common = "=0.3.5" -swc_visit = "=0.3.0" -swc_visit_macros = "=0.3.1" sha2 = "0.10.2" itertools = "0.10.5" +lazy_static = "1.4.0" models = { path = "../models" } helpers = { path = "../helpers" } serde = { version = "1.0", features = ["derive", "rc"] } diff --git a/libs/js_engine/src/artifacts/ARM_JS_SNAPSHOT.bin b/libs/js_engine/src/artifacts/ARM_JS_SNAPSHOT.bin index 7b6059a90..b366410ca 100644 Binary files a/libs/js_engine/src/artifacts/ARM_JS_SNAPSHOT.bin and b/libs/js_engine/src/artifacts/ARM_JS_SNAPSHOT.bin differ diff --git a/libs/js_engine/src/artifacts/JS_SNAPSHOT.bin b/libs/js_engine/src/artifacts/JS_SNAPSHOT.bin index 9b86d3596..0201d5a99 100644 Binary files a/libs/js_engine/src/artifacts/JS_SNAPSHOT.bin and b/libs/js_engine/src/artifacts/JS_SNAPSHOT.bin differ diff --git a/libs/js_engine/src/artifacts/loadModule.js b/libs/js_engine/src/artifacts/loadModule.js index c422d5dea..b624c11be 100644 --- a/libs/js_engine/src/artifacts/loadModule.js +++ b/libs/js_engine/src/artifacts/loadModule.js @@ -141,7 +141,7 @@ const removeFile = ( { volumeId = requireParam("volumeId"), path = requireParam("path") } = requireParam("options"), ) => Deno.core.opAsync("remove_file", volumeId, path); -const isSandboxed = () => Deno.core.opSync("is_sandboxed"); +const isSandboxed = () => Deno.core.ops["is_sandboxed"](); const writeJsonFile = ( { @@ -265,15 +265,15 @@ const getServiceConfig = async ( ); }; -const started = () => Deno.core.opSync("set_started"); +const started = () => Deno.core.ops.set_started(); const restart = () => Deno.core.opAsync("restart"); const start = () => Deno.core.opAsync("start"); const stop = () => Deno.core.opAsync("stop"); -const currentFunction = Deno.core.opSync("current_function"); -const input = Deno.core.opSync("get_input"); -const variable_args = Deno.core.opSync("get_variable_args"); -const setState = (x) => Deno.core.opAsync("set_value", x); +const currentFunction = Deno.core.ops.current_function(); +const input = Deno.core.ops.get_input(); +const variable_args = Deno.core.ops.get_variable_args(); +const setState = (x) => Deno.core.ops.set_value(x); const effects = { bindLocal, bindTor, diff --git a/libs/js_engine/src/lib.rs b/libs/js_engine/src/lib.rs index a89a74458..b2ce1a04e 100644 --- a/libs/js_engine/src/lib.rs +++ b/libs/js_engine/src/lib.rs @@ -9,8 +9,9 @@ use std::time::SystemTime; use deno_core::anyhow::{anyhow, bail}; use deno_core::error::AnyError; use deno_core::{ - resolve_import, Extension, JsRuntime, ModuleLoader, ModuleSource, ModuleSourceFuture, - ModuleSpecifier, ModuleType, OpDecl, RuntimeOptions, Snapshot, + resolve_import, Extension, FastString, JsRuntime, ModuleLoader, ModuleSource, + ModuleSourceFuture, ModuleSpecifier, ModuleType, OpDecl, ResolutionKind, RuntimeOptions, + Snapshot, }; use embassy_container_init::ProcessGroupId; use helpers::{script_dir, spawn_local, OsApi, Rsync, UnixRpcClient}; @@ -21,6 +22,12 @@ use tokio::io::AsyncReadExt; use tokio::sync::{mpsc, Mutex}; use tracing::instrument; +lazy_static::lazy_static! { + static ref DENO_GLOBAL_JS: ModuleSpecifier = "file:///deno_global.js".parse().unwrap(); + static ref LOAD_MODULE_JS: ModuleSpecifier = "file:///loadModule.js".parse().unwrap(); + static ref EMBASSY_JS: ModuleSpecifier = "file:///embassy.js".parse().unwrap(); +} + pub trait PathForVolumeId: Send + Sync { fn path_for( &self, @@ -32,8 +39,8 @@ pub trait PathForVolumeId: Send + Sync { fn readonly(&self, volume_id: &VolumeId) -> bool; } -#[derive(Serialize, Deserialize, Debug, Default, Clone)] -pub struct JsCode(String); +#[derive(Serialize, Deserialize, Debug, Clone)] +pub struct JsCode(Arc); #[derive(Debug, Clone, Copy)] pub enum JsError { @@ -131,7 +138,7 @@ impl ModuleLoader for ModsLoader { &self, specifier: &str, referrer: &str, - _is_main: bool, + _is_main: ResolutionKind, ) -> Result { if referrer.contains("embassy") { bail!("Embassy.js cannot import anything else"); @@ -143,49 +150,42 @@ impl ModuleLoader for ModsLoader { fn load( &self, module_specifier: &ModuleSpecifier, - maybe_referrer: Option, + maybe_referrer: Option<&ModuleSpecifier>, is_dyn_import: bool, ) -> Pin> { let module_specifier = module_specifier.as_str().to_owned(); let module = match &*module_specifier { - "file:///deno_global.js" => Ok(ModuleSource { - module_url_specified: "file:///deno_global.js".to_string(), - module_url_found: "file:///deno_global.js".to_string(), - code: "const old_deno = Deno; Deno = null; export default old_deno" - .as_bytes() - .to_vec() - .into_boxed_slice(), - module_type: ModuleType::JavaScript, - }), - "file:///loadModule.js" => Ok(ModuleSource { - module_url_specified: "file:///loadModule.js".to_string(), - module_url_found: "file:///loadModule.js".to_string(), - code: include_str!("./artifacts/loadModule.js") - .as_bytes() - .to_vec() - .into_boxed_slice(), - module_type: ModuleType::JavaScript, - }), - "file:///embassy.js" => Ok(ModuleSource { - module_url_specified: "file:///embassy.js".to_string(), - module_url_found: "file:///embassy.js".to_string(), - code: self.code.0.as_bytes().to_vec().into_boxed_slice(), - module_type: ModuleType::JavaScript, - }), + "file:///deno_global.js" => Ok(ModuleSource::new( + ModuleType::JavaScript, + FastString::Static("const old_deno = Deno; Deno = null; export default old_deno"), + &*DENO_GLOBAL_JS, + )), + "file:///loadModule.js" => Ok(ModuleSource::new( + ModuleType::JavaScript, + FastString::Static(include_str!("./artifacts/loadModule.js")), + &*LOAD_MODULE_JS, + )), + "file:///embassy.js" => Ok(ModuleSource::new( + ModuleType::JavaScript, + self.code.0.clone().into(), + &*EMBASSY_JS, + )), + x => Err(anyhow!("Not allowed to import: {}", x)), }; - Box::pin(async move { + let module = module.and_then(|m| { if is_dyn_import { bail!("Will not import dynamic"); } match &maybe_referrer { Some(x) if x.as_str() == "file:///embassy.js" => { - bail!("Embassy is not allowed to import") + bail!("StartJS is not allowed to import") } _ => (), } - module - }) + Ok(m) + }); + Box::pin(async move { module }) } } @@ -234,7 +234,7 @@ impl JsExecutionEnvironment { format!("The file reading created error: {}", err), )); }; - buffer + buffer.into() }); Ok(JsExecutionEnvironment { os, @@ -364,12 +364,11 @@ impl JsExecutionEnvironment { callback_sender, rsyncs: Default::default(), }; - let ext = Extension::builder() + let ext = Extension::builder("embassy") .ops(Self::declarations()) .state(move |state| { state.put(ext_answer_state.clone()); state.put(js_ctx.clone()); - Ok(()) }) .build(); let loader = std::rc::Rc::new(self.module_loader.clone()); diff --git a/libs/snapshot_creator/Cargo.toml b/libs/snapshot_creator/Cargo.toml index cfc468954..08876b517 100644 --- a/libs/snapshot_creator/Cargo.toml +++ b/libs/snapshot_creator/Cargo.toml @@ -7,5 +7,5 @@ edition = "2021" [dependencies] dashmap = "5.3.4" -deno_core = "=0.136.0" -deno_ast = { version = "=0.15.0", features = ["transpiling"] } +deno_core = "0.195.0" +deno_ast = { version = "0.27.2", features = ["transpiling"] } diff --git a/libs/snapshot_creator/src/main.rs b/libs/snapshot_creator/src/main.rs index 8ea372510..dd14873b7 100644 --- a/libs/snapshot_creator/src/main.rs +++ b/libs/snapshot_creator/src/main.rs @@ -1,10 +1,7 @@ -use deno_core::{JsRuntime, RuntimeOptions}; +use deno_core::JsRuntimeForSnapshot; fn main() { - let mut runtime = JsRuntime::new(RuntimeOptions { - will_snapshot: true, - ..Default::default() - }); + let runtime = JsRuntimeForSnapshot::new(Default::default(), Default::default()); let snapshot = runtime.snapshot(); let snapshot_slice: &[u8] = &*snapshot; diff --git a/system-images/compat/Cargo.lock b/system-images/compat/Cargo.lock index 5956a1ce6..f7b8e4277 100644 --- a/system-images/compat/Cargo.lock +++ b/system-images/compat/Cargo.lock @@ -487,6 +487,15 @@ dependencies = [ "winapi", ] +[[package]] +name = "chumsky" +version = "0.9.2" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "23170228b96236b5a7299057ac284a321457700bc8c41a4476052f0f4ba5349d" +dependencies = [ + "hashbrown", +] + [[package]] name = "ciborium" version = "0.2.0" @@ -607,7 +616,6 @@ dependencies = [ "beau_collector", "clap 2.34.0", "dashmap", - "embassy-os", "emver", "failure", "indexmap", @@ -624,6 +632,7 @@ dependencies = [ "serde", "serde_json", "serde_yaml 0.8.26", + "start-os", ] [[package]] @@ -1098,6 +1107,12 @@ version = "0.15.6" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "03d8c417d7a8cb362e0c37e5d815f5eb7c37f79ff93707329d5a194e42e54ca0" +[[package]] +name = "dyn-clone" +version = "1.0.12" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "304e6508efa593091e97a9abbc10f90aa7ca635b6d2784feff3c89d41dd12272" + [[package]] name = "ecdsa" version = "0.14.8" @@ -1178,114 +1193,6 @@ dependencies = [ "zeroize", ] -[[package]] -name = "embassy-os" -version = "0.3.4-rev.3" -dependencies = [ - "aes", - "async-compression", - "async-stream", - "async-trait", - "base32", - "base64 0.13.1", - "base64ct", - "basic-cookies", - "bimap", - "bollard", - "bytes", - "chrono", - "ciborium", - "clap 3.2.23", - "color-eyre", - "cookie", - "cookie_store 0.19.0", - "current_platform", - "digest 0.10.6", - "digest 0.9.0", - "divrem", - "ed25519", - "ed25519-dalek", - "embassy_container_init", - "emver", - "fd-lock-rs", - "futures", - "git-version", - "gpt", - "helpers", - "hex", - "hmac 0.12.1", - "http", - "hyper", - "hyper-ws-listener", - "id-pool", - "imbl 2.0.0", - "indexmap", - "ipnet", - "iprange", - "isocountry", - "itertools 0.10.5", - "josekit", - "jsonpath_lib", - "lazy_static", - "libc", - "log", - "mbrman", - "models", - "nix 0.25.1", - "nom", - "num", - "num_enum", - "openssh-keys", - "openssl", - "p256 0.12.0", - "patch-db", - "pbkdf2", - "pin-project", - "pkcs8", - "prettytable-rs", - "proptest", - "proptest-derive", - "rand 0.7.3", - "rand 0.8.5", - "regex", - "reqwest", - "reqwest_cookie_store", - "rpassword", - "rpc-toolkit", - "rust-argon2", - "scopeguard", - "serde", - "serde_json", - "serde_with 2.2.0", - "serde_yaml 0.9.16", - "sha2 0.10.6", - "sha2 0.9.9", - "simple-logging", - "sqlx", - "ssh-key", - "stderrlog", - "tar", - "thiserror", - "tokio", - "tokio-rustls", - "tokio-socks", - "tokio-stream", - "tokio-tar", - "tokio-tungstenite", - "tokio-util", - "toml", - "torut", - "tracing", - "tracing-error 0.2.0", - "tracing-futures", - "tracing-subscriber 0.3.16", - "trust-dns-server", - "typed-builder", - "url", - "uuid 1.2.2", - "zeroize", -] - [[package]] name = "embassy_container_init" version = "0.1.0" @@ -1826,6 +1733,12 @@ version = "0.4.3" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "7f24254aa9a54b5c858eaee2f5bccdb46aaf0e486a595ed5fd8f86ba55232a70" +[[package]] +name = "hifijson" +version = "0.2.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "85ef6b41c333e6dd2a4aaa59125a19b633cd17e7aaf372b2260809777bcdef4a" + [[package]] name = "hkdf" version = "0.12.3" @@ -2057,6 +1970,25 @@ dependencies = [ "bitmaps 3.2.0", ] +[[package]] +name = "include_dir" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "18762faeff7122e89e0857b02f7ce6fcc0d101d5e9ad2ad7846cc01d61b7f19e" +dependencies = [ + "include_dir_macros", +] + +[[package]] +name = "include_dir_macros" +version = "0.7.3" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "b139284b5cf57ecfa712bcc66950bb635b31aff41c188e8a4cfc758eca374a3f" +dependencies = [ + "proc-macro2 1.0.50", + "quote 1.0.23", +] + [[package]] name = "indenter" version = "0.3.3" @@ -2187,6 +2119,44 @@ version = "1.0.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "fad582f4b9e86b6caa621cabeb0963332d92eea04729ab12892c2533951e6440" +[[package]] +name = "jaq-core" +version = "0.10.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "eb52eeac20f256459e909bd4a03bb8c4fab6a1fdbb8ed52d00f644152df48ece" +dependencies = [ + "ahash", + "dyn-clone", + "hifijson", + "indexmap", + "itertools 0.10.5", + "jaq-parse", + "log", + "once_cell", + "regex", + "serde_json", +] + +[[package]] +name = "jaq-parse" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "2f0f97f01eb9e87af3cbcc843b0dfe693fc6b0a2b9093dc8980dd9fc682826b0" +dependencies = [ + "chumsky", + "serde", +] + +[[package]] +name = "jaq-std" +version = "0.10.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5b261109851c8687bc55eab26e6d81e96f3fdab367e2d3d5706947c218ddaf22" +dependencies = [ + "bincode", + "jaq-parse", +] + [[package]] name = "josekit" version = "0.8.1" @@ -2513,6 +2483,16 @@ version = "1.0.4" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "e4a24736216ec316047a1fc4252e27dabb04218aa4a3f37c6e7ddbf1f9782b54" +[[package]] +name = "new_mime_guess" +version = "4.0.1" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "c2d684d1b59e0dc07b37e2203ef576987473288f530082512aff850585c61b1f" +dependencies = [ + "mime", + "unicase", +] + [[package]] name = "nibble_vec" version = "0.1.0" @@ -4229,6 +4209,116 @@ dependencies = [ "zeroize", ] +[[package]] +name = "start-os" +version = "0.3.4-rev.4" +dependencies = [ + "aes", + "async-compression", + "async-stream", + "async-trait", + "base32", + "base64 0.13.1", + "base64ct", + "basic-cookies", + "bollard", + "bytes", + "chrono", + "ciborium", + "clap 3.2.23", + "color-eyre", + "cookie", + "cookie_store 0.19.0", + "current_platform", + "digest 0.10.6", + "digest 0.9.0", + "divrem", + "ed25519", + "ed25519-dalek", + "embassy_container_init", + "emver", + "fd-lock-rs", + "futures", + "git-version", + "gpt", + "helpers", + "hex", + "hmac 0.12.1", + "http", + "hyper", + "hyper-ws-listener", + "imbl 2.0.0", + "include_dir", + "indexmap", + "ipnet", + "iprange", + "isocountry", + "itertools 0.10.5", + "jaq-core", + "jaq-std", + "josekit", + "jsonpath_lib", + "lazy_static", + "libc", + "log", + "mbrman", + "models", + "new_mime_guess", + "nix 0.25.1", + "nom", + "num", + "num_enum", + "openssh-keys", + "openssl", + "p256 0.12.0", + "patch-db", + "pbkdf2", + "pin-project", + "pkcs8", + "prettytable-rs", + "proptest", + "proptest-derive", + "rand 0.7.3", + "rand 0.8.5", + "regex", + "reqwest", + "reqwest_cookie_store", + "rpassword", + "rpc-toolkit", + "rust-argon2", + "scopeguard", + "serde", + "serde_json", + "serde_with 2.2.0", + "serde_yaml 0.9.16", + "sha2 0.10.6", + "sha2 0.9.9", + "simple-logging", + "sqlx", + "ssh-key", + "stderrlog", + "tar", + "thiserror", + "tokio", + "tokio-rustls", + "tokio-socks", + "tokio-stream", + "tokio-tar", + "tokio-tungstenite", + "tokio-util", + "toml", + "torut", + "tracing", + "tracing-error 0.2.0", + "tracing-futures", + "tracing-subscriber 0.3.16", + "trust-dns-server", + "typed-builder", + "url", + "uuid 1.2.2", + "zeroize", +] + [[package]] name = "stderrlog" version = "0.5.4" @@ -4866,6 +4956,15 @@ version = "0.1.5" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "9e79c4d996edb816c91e4308506774452e55e95c3c9de07b6729e17e15a5ef81" +[[package]] +name = "unicase" +version = "2.6.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "50f37be617794602aabbeee0be4f259dc1778fabe05e2d67ee8f79326d5cb4f6" +dependencies = [ + "version_check", +] + [[package]] name = "unicode-bidi" version = "0.3.8" diff --git a/system-images/compat/Cargo.toml b/system-images/compat/Cargo.toml index 1dc735fb4..735667a36 100644 --- a/system-images/compat/Cargo.toml +++ b/system-images/compat/Cargo.toml @@ -11,7 +11,7 @@ anyhow = { version = "1.0.40", features = ["backtrace"] } beau_collector = "0.2.1" clap = "2.33.3" dashmap = "5.3.2" -embassy-os = { path = "../../backend", default-features = false } +start-os = { path = "../../backend", default-features = false } emver = { version = "0.1.7", git = "https://github.com/Start9Labs/emver-rs.git", features = [ "serde", ] } diff --git a/system-images/compat/src/backup.rs b/system-images/compat/src/backup.rs index 2899b52fb..9e54100f8 100644 --- a/system-images/compat/src/backup.rs +++ b/system-images/compat/src/backup.rs @@ -1,6 +1,6 @@ use std::{path::Path, process::Stdio}; -use embassy::disk::main::DEFAULT_PASSWORD; +use startos::disk::main::DEFAULT_PASSWORD; pub fn create_backup( mountpoint: impl AsRef, @@ -19,17 +19,21 @@ pub fn create_backup( let mut data_cmd = std::process::Command::new("duplicity"); for exclude in exclude.lines().map(|s| s.trim()).filter(|s| !s.is_empty()) { if exclude.to_string().starts_with('!') { - data_cmd.arg(format!( - "--include={}", - data_path - .join(exclude.to_string().trim_start_matches('!')) - .display() - )).arg("--allow-source-mismatch"); + data_cmd + .arg(format!( + "--include={}", + data_path + .join(exclude.to_string().trim_start_matches('!')) + .display() + )) + .arg("--allow-source-mismatch"); } else { - data_cmd.arg(format!( - "--exclude={}", - data_path.join(exclude.to_string()).display() - )).arg("--allow-source-mismatch"); + data_cmd + .arg(format!( + "--exclude={}", + data_path.join(exclude.to_string()).display() + )) + .arg("--allow-source-mismatch"); } } let data_output = data_cmd diff --git a/system-images/compat/src/config/mod.rs b/system-images/compat/src/config/mod.rs index 1240f801a..b80af0cf1 100644 --- a/system-images/compat/src/config/mod.rs +++ b/system-images/compat/src/config/mod.rs @@ -3,11 +3,11 @@ use std::collections::{BTreeMap, BTreeSet, HashMap}; use std::path::Path; use beau_collector::BeauCollector; -use embassy::config::action::SetResult; -use embassy::config::{spec, Config}; -use embassy::s9pk::manifest::PackageId; -use embassy::status::health_check::HealthCheckId; use linear_map::LinearMap; +use startos::config::action::SetResult; +use startos::config::{spec, Config}; +use startos::s9pk::manifest::PackageId; +use startos::status::health_check::HealthCheckId; pub mod rules; diff --git a/system-images/compat/src/config/rules.rs b/system-images/compat/src/config/rules.rs index d3df0b7cf..ea2650237 100644 --- a/system-images/compat/src/config/rules.rs +++ b/system-images/compat/src/config/rules.rs @@ -7,8 +7,8 @@ use pest::Parser; use rand::SeedableRng; use serde_json::Value; -use embassy::config::util::STATIC_NULL; -use embassy::config::Config; +use startos::config::util::STATIC_NULL; +use startos::config::Config; #[derive(Parser)] #[grammar = "config/rule_parser.pest"] diff --git a/system-images/compat/src/main.rs b/system-images/compat/src/main.rs index dcd723882..338e01f5b 100644 --- a/system-images/compat/src/main.rs +++ b/system-images/compat/src/main.rs @@ -19,8 +19,8 @@ use clap::{App, Arg, SubCommand}; use config::{ apply_dependency_configuration, validate_configuration, validate_dependency_configuration, }; -use embassy::config::action::ConfigRes; use serde_json::json; +use startos::config::action::ConfigRes; const PROPERTIES_FALLBACK_MESSAGE: &str = "Could not find properties. The service might still be starting";