JonathanxD / openaws-vpn-client

Unofficial open-source AWS VPN Client GUI for Linux
Other
62 stars 14 forks source link

Unable to connect on aarch64 system #4

Closed hpio closed 1 year ago

hpio commented 1 year ago

Hi there, I've been trying to run patched OpenVPN client on Asahi Linux but I'm facing some issues. I managed to build the client following your instructions and start it, however when I try to connect to vpn it crashes with the following stacktrace

❯ RUST_BACKTRACE=full ./openaws-vpn-client
Starting server
Saved at "/home/piotr/.local/share/openaws-vpn-client/aws-vpn-root-oavc.ovpn"
Remote ("cvpn-endpoint-079ede69a565e36b6.prod.clientvpn.eu-west-1.amazonaws.com", 443)
Connecting...
thread 'tokio-runtime-worker' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "No such file or directory" }', src/cmd.rs:52:10
stack backtrace:
   0:     0xaaab33b7870c - std::backtrace_rs::backtrace::libunwind::trace::hf081397fc7a8644d
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/../../backtrace/src/backtrace/libunwind.rs:93:5
   1:     0xaaab33b7870c - std::backtrace_rs::backtrace::trace_unsynchronized::h23eea5f7a7de1406
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/../../backtrace/src/backtrace/mod.rs:66:5
   2:     0xaaab33b7870c - std::sys_common::backtrace::_print_fmt::h67f2d63e5d16bea6
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/sys_common/backtrace.rs:65:5
   3:     0xaaab33b7870c - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::hf1a4b5df60ee90ab
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/sys_common/backtrace.rs:44:22
   4:     0xaaab33b97b94 - core::fmt::write::ha2eded128cf968e0
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/core/src/fmt/mod.rs:1232:17
   5:     0xaaab33b737cc - std::io::Write::write_fmt::h419ff58022ec8dbd
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/io/mod.rs:1682:15
   6:     0xaaab33b78518 - std::sys_common::backtrace::_print::h2a572ccb2e37afe8
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/sys_common/backtrace.rs:47:5
   7:     0xaaab33b78518 - std::sys_common::backtrace::print::h5cbc1c08907dbf7f
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/sys_common/backtrace.rs:34:9
   8:     0xaaab33b79c08 - std::panicking::default_hook::{{closure}}::h953b9c5b84d880f6
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:267:22
   9:     0xaaab33b7994c - std::panicking::default_hook::h5e6710eb4e71a9e8
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:286:9
  10:     0xaaab33b7a28c - std::panicking::rust_panic_with_hook::h55dd4d33c49b8816
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:688:13
  11:     0xaaab33b7a068 - std::panicking::begin_panic_handler::{{closure}}::h489366f0c44ba511
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:579:13
  12:     0xaaab33b78b9c - std::sys_common::backtrace::__rust_end_short_backtrace::hac86ec723f4a024a
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/sys_common/backtrace.rs:137:18
  13:     0xaaab33b79db4 - rust_begin_unwind
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:575:5
  14:     0xaaab3377a198 - core::panicking::panic_fmt::h2a9d388105fea618
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/core/src/panicking.rs:64:14
  15:     0xaaab3377a4d0 - core::result::unwrap_failed::h4566a0f38d5188f6
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/core/src/result.rs:1790:5
  16:     0xaaab337c2664 - core::result::Result<T,E>::unwrap::hfe55f15491fadb03
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/core/src/result.rs:1112:23
  17:     0xaaab3386025c - openaws_vpn_client::cmd::run_ovpn::{{closure}}::h2c92db695e48e10c
                               at /home/piotr/workspace/openaws-vpn-client/src/cmd.rs:37:15
  18:     0xaaab337d4c8c - openaws_vpn_client::manager::ConnectionManager::connect::{{closure}}::h3300a1a6e4cfbeb4
                               at /home/piotr/workspace/openaws-vpn-client/src/manager.rs:117:84
  19:     0xaaab337f5b50 - tokio::runtime::task::core::CoreStage<T>::poll::{{closure}}::h553310037051a96d
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/core.rs:161:17
  20:     0xaaab33897e48 - tokio::loom::std::unsafe_cell::UnsafeCell<T>::with_mut::hb6d803f6346bc9bf
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/loom/std/unsafe_cell.rs:14:9
  21:     0xaaab337f57e4 - tokio::runtime::task::core::CoreStage<T>::poll::hef750584c5647468
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/core.rs:151:13
  22:     0xaaab3386d934 - tokio::runtime::task::harness::poll_future::{{closure}}::haa9e7cd1f541b1c1
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/harness.rs:461:19
  23:     0xaaab3385b66c - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h05b6d43d26d92ea5
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/core/src/panic/unwind_safe.rs:271:9
  24:     0xaaab337eefdc - std::panicking::try::do_call::had1fdcf2b3e9c7c6
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:483:40
  25:     0xaaab337f1218 - __rust_try
  26:     0xaaab337ebf38 - std::panicking::try::h2657c02026beb501
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:447:19
  27:     0xaaab33802dc8 - std::panic::catch_unwind::hfa2a273b0174ca73
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panic.rs:140:14
  28:     0xaaab3386ccdc - tokio::runtime::task::harness::poll_future::h50d14d795092eee0
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/harness.rs:449:18
  29:     0xaaab3386e3d8 - tokio::runtime::task::harness::Harness<T,S>::poll_inner::h672ddd5da6d2d2fe
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/harness.rs:98:27
  30:     0xaaab338740b8 - tokio::runtime::task::harness::Harness<T,S>::poll::h8bf42d1e18984970
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/harness.rs:53:15
  31:     0xaaab338593bc - tokio::runtime::task::raw::poll::hb4a305398f1e03d6
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/raw.rs:113:5
  32:     0xaaab33ab9068 - tokio::runtime::task::raw::RawTask::poll::h1dae513fb54ecd13
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/raw.rs:70:18
  33:     0xaaab33ab3c44 - tokio::runtime::task::LocalNotified<S>::run::hb01c23d268b0a9a5
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/mod.rs:343:9
  34:     0xaaab33ac377c - tokio::runtime::thread_pool::worker::Context::run_task::{{closure}}::h84e0bb23ce9438a3
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/thread_pool/worker.rs:420:13
  35:     0xaaab33a80ab8 - tokio::coop::with_budget::{{closure}}::h6a1012fb0d3c2591
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/coop.rs:106:9
  36:     0xaaab33a49700 - std::thread::local::LocalKey<T>::try_with::hec5881873dcaec8a
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/thread/local.rs:446:16
  37:     0xaaab33a471d4 - std::thread::local::LocalKey<T>::with::h0738153dd020bdef
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/thread/local.rs:422:9
  38:     0xaaab33ac36cc - tokio::coop::with_budget::h996e2f755c24db67
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/coop.rs:99:5
  39:     0xaaab33ac36cc - tokio::coop::budget::h966e99d188fd2c57
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/coop.rs:76:5
  40:     0xaaab33ac36cc - tokio::runtime::thread_pool::worker::Context::run_task::ha3cd379f55ada036
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/thread_pool/worker.rs:419:9
  41:     0xaaab33ac3144 - tokio::runtime::thread_pool::worker::Context::run::hc4bdc604c1ad8639
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/thread_pool/worker.rs:386:24
  42:     0xaaab33ac2fa0 - tokio::runtime::thread_pool::worker::run::{{closure}}::h64d01b55d3caf6fe
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/thread_pool/worker.rs:371:17
  43:     0xaaab33a69634 - tokio::macros::scoped_tls::ScopedKey<T>::set::h3ff318bc169ded64
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/macros/scoped_tls.rs:61:9
  44:     0xaaab33ac2f04 - tokio::runtime::thread_pool::worker::run::h723350d0525c82be
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/thread_pool/worker.rs:368:5
  45:     0xaaab33ac2d80 - tokio::runtime::thread_pool::worker::Launch::launch::{{closure}}::h48b8fab5330670c7
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/thread_pool/worker.rs:347:45
  46:     0xaaab33aad760 - <tokio::runtime::blocking::task::BlockingTask<T> as core::future::future::Future>::poll::h81134f4d332efbce
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/blocking/task.rs:42:21
  47:     0xaaab33ab32a4 - tokio::runtime::task::core::CoreStage<T>::poll::{{closure}}::h0f4d20e3bf509af1
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/core.rs:161:17
  48:     0xaaab33a5026c - tokio::loom::std::unsafe_cell::UnsafeCell<T>::with_mut::h400b868a8bc1d4bd
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/loom/std/unsafe_cell.rs:14:9
  49:     0xaaab33ab31c8 - tokio::runtime::task::core::CoreStage<T>::poll::hba7a8fd8441f9b53
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/core.rs:151:13
  50:     0xaaab33ac8448 - tokio::runtime::task::harness::poll_future::{{closure}}::h1072d137240fd930
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/harness.rs:461:19
  51:     0xaaab33a8d474 - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::he3d928aa6acc33d1
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/core/src/panic/unwind_safe.rs:271:9
  52:     0xaaab33ac9d60 - std::panicking::try::do_call::hfef4fef746804315
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:483:40
  53:     0xaaab33aca830 - __rust_try
  54:     0xaaab33ac8f28 - std::panicking::try::h667be62a5203f22f
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:447:19
  55:     0xaaab33a5d050 - std::panic::catch_unwind::hd2a79192ef1cae5f
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panic.rs:140:14
  56:     0xaaab33ac82dc - tokio::runtime::task::harness::poll_future::hacc7dd7e6a471b9a
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/harness.rs:449:18
  57:     0xaaab33ac6984 - tokio::runtime::task::harness::Harness<T,S>::poll_inner::h1845e76109fbb249
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/harness.rs:98:27
  58:     0xaaab33ac67cc - tokio::runtime::task::harness::Harness<T,S>::poll::h110becc04006d97d
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/harness.rs:53:15
  59:     0xaaab33ab9184 - tokio::runtime::task::raw::poll::h937fe4fa37c55cac
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/raw.rs:113:5
  60:     0xaaab33ab9068 - tokio::runtime::task::raw::RawTask::poll::h1dae513fb54ecd13
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/raw.rs:70:18
  61:     0xaaab33ab3d08 - tokio::runtime::task::UnownedTask<S>::run::haeb0f39e620e085c
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/task/mod.rs:379:9
  62:     0xaaab33ab5e60 - tokio::runtime::blocking::pool::Inner::run::h54dfe2a98975dc57
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/blocking/pool.rs:264:17
  63:     0xaaab33ab55b0 - tokio::runtime::blocking::pool::Spawner::spawn_thread::{{closure}}::h965ad05cd3735995
                               at /home/piotr/.cargo/registry/src/github.com-1ecc6299db9ec823/tokio-1.14.0/src/runtime/blocking/pool.rs:244:17
  64:     0xaaab33a47198 - std::sys_common::backtrace::__rust_begin_short_backtrace::h35401c3590d4797f
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/sys_common/backtrace.rs:121:18
  65:     0xaaab33a6616c - std::thread::Builder::spawn_unchecked_::{{closure}}::{{closure}}::h7f41deaa4d64c677
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/thread/mod.rs:558:17
  66:     0xaaab33a8d30c - <core::panic::unwind_safe::AssertUnwindSafe<F> as core::ops::function::FnOnce<()>>::call_once::h499d286263eb03c2
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/core/src/panic/unwind_safe.rs:271:9
  67:     0xaaab33ac9ae4 - std::panicking::try::do_call::hbe7fae3e3db121ae
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:483:40
  68:     0xaaab33aca830 - __rust_try
  69:     0xaaab33ac8b50 - std::panicking::try::h4b8cbabcac7ec787
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panicking.rs:447:19
  70:     0xaaab33a5cdd0 - std::panic::catch_unwind::h147974e1a1153810
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/panic.rs:140:14
  71:     0xaaab33a65fd8 - std::thread::Builder::spawn_unchecked_::{{closure}}::ha93c6ed668d044da
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/thread/mod.rs:557:30
  72:     0xaaab33a8d850 - core::ops::function::FnOnce::call_once{{vtable.shim}}::h49dd0f16b78ec470
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/core/src/ops/function.rs:250:5
  73:     0xaaab33b7e7dc - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::hc4a41657821f5e1d
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/alloc/src/boxed.rs:1988:9
  74:     0xaaab33b7e7dc - <alloc::boxed::Box<F,A> as core::ops::function::FnOnce<Args>>::call_once::h5f443415fabd1e4c
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/alloc/src/boxed.rs:1988:9
  75:     0xaaab33b7e7dc - std::sys::unix::thread::Thread::new::thread_start::h9c83277ba2181a95
                               at /rustc/11d96b59307b1702fffe871bfc2d0145d070881e/library/std/src/sys/unix/thread.rs:108:17
  76:     0xffffb08a0aec - <unknown>
  77:     0xffffb090a5dc - <unknown>
  78:                0x0 - <unknown>

system details:

❯ uname -a
Linux khazad-dum 6.1.0-asahi-2-2-edge-ARCH #2 SMP PREEMPT_DYNAMIC Fri, 16 Dec 2022 05:04:23 +0000 aarch64 GNU/Linux

Is there anything i can do to help resolve the issue?

Thanks again

hpio commented 1 year ago

so the issue was on my side, turns out the when starting the binary, the share folder needs to be in the current working directory

JonathanxD commented 1 year ago

Re-opening because I can provide a better experience for this architecture.

@hpio Apart from that, is it working well on aarch64? I can provide aarch64 builds on GitLab if it's of your interest, as well as improve those messages.

I think a standard package for aarch64 like I distribute for x86 would make it less error prone, since I didn't wrote any detailed documentation on how to setup it correctly.

hpio commented 1 year ago

hey @JonathanxD the build is working flawlessly on aarch64, I'm sure many would benefit from having the package available as aarch64 is getting more popular and this is the only working implementation of ovpn and saml i managed to find!

JonathanxD commented 1 year ago

@hpio Sorry for the delay, I've set-up the aarch64 build and it's available on GitLab. The next thing I'll be doing is to upload those artifacts to GitHub as well, but for now I think this already addresses the need of aarch64 builds.