Forum Discussion

Former Member's avatar
Former Member
4 years ago

Can't autofill sudo commands

I have went through https://support.1password.com/mac-universal-autofill/#autofill-your-mac-login and am unable to autofill my password when using sudo commands.

I have a Mac login item, which also shows in Quick Access when Terminal or iTerm2 is focused.
Using the Universal Autofill shortcut prompts me to unlock.
1Password has the Automation permission for both Terminal.app and iTerm.app and the Accessibility permission.

When I use either the Universal Autofill shortcut or the autofill option in Quick Access at a sudo prompt in either Terminal or iTerm2, nothing happens, and when I hit enter after using the shortcut, I get "Sorry, try again.". I used sudo echo as a test command.


1Password Version: 8.8.0-119
OS Version: macOS 12.4

18 Replies

  • Former Member's avatar
    Former Member

    They closed the thread I opened about this and are going to handle it over email. I will update this post here after resolution in case it is helpful to you too: https://1password.community/discussion/130658/1password-8-silent-rust-error-when-trying-to-autofill-in-iterm2

  • Former Member's avatar
    Former Member

    Probably means that if it were to autofill the password, it would be immediately visible (like maybe it isn't on a hidden password field or something)
    Entering the password manually hides it as expected and Secure Keyboard Entry is enabled, although maybe it could be incorrectly checking these.

  • Former Member's avatar
    Former Member

    Probably means that if it were to autofill the password, it would be immediately visible (like maybe it isn't on a hidden password field or something). That would be my guess. Good to know that our iTerm issue is the same however.

  • Former Member's avatar
    Former Member

    Thanks, looks like I have the same error when using iTerm, but not with Terminal.app, which gives a different set of logs:

    INFO tokio-runtime-worker(ThreadId(52)) [swift] Brain.swift:447 :: collectPageDetails(fastCollection:prettyPrint:) | @Autofill: Collecting from pid(22848)
    INFO tokio-runtime-worker(ThreadId(52)) [swift] Brain.swift:344 :: collectTerminalElement(app:) | @Autofill: Collecting a terminal app
    INFO tokio-runtime-worker(ThreadId(52)) [swift] Brain.swift:371 :: collectTerminalElement(app:) | @Autofill: Terminal in echo mode, filling disabled
    INFO tokio-runtime-worker(ThreadId(3)) [1P:op-desktop-autofill/src/macos.rs:160] Nothing to be filled
    INFO tokio-runtime-worker(ThreadId(3)) [1P:op-desktop-autofill/src/macos.rs:168] Active app is a terminal; not trying to fill more than once
    INFO tokio-runtime-worker(ThreadId(3)) [1P:op-desktop-autofill/src/macos.rs:177] Done filling

    I don't really have a guess for what "echo mode" could be referring to.

  • Former Member's avatar
    Former Member

    Yeah, definitely tried reinstalling iTerm. After that, I also tried installing it again using brew, just to see if it would make a difference. Curious if your logs say anything. Based on 1Password documentation if you're running on mac you can find them at: ~/Library/Group Containers/2BUA8C4S2C.com.1password/Library/Application Support/1Password/Data/logs

  • Former Member's avatar
    Former Member

    This sounds like iTerm isn't signed as expected which is a different issue to what I was experiencing since I can't get it to work in Terminal.app either and the Automation prompt showed for both. Might be worth making another thread for your issue to avoid it getting lost? Unless it's a 1Password verification bug, I think reinstalling iTerm might help.

  • Former Member's avatar
    Former Member

    Maybe this will help. Looks like some sort of a silent rust error showing up in my logs when I try and autofill in iTerm2:

    ```
    ERROR 2022-06-07T01:43:56.302 tokio-runtime-worker(ThreadId(7)) [1P:op-desktop-autofill/src/macos.rs:114] active application did not have expected signature, aborting fill: DoesNotMatchTeam
    ERROR 2022-06-07T01:43:56.302 tokio-runtime-worker(ThreadId(7)) [1P:op-app/src/app/backend.rs:209] AppError at op-app/src/app/backend/autofill.rs:356:25
    AutoTypeError(GatheringActiveAppInfoFailed)

    Stack backtrace:
    0: backtrace::backtrace::trace
    1: anyhow::backtrace::capture::Backtrace::capture
    2: anyhow::error::::new
    3: core::future::from_generator::GenFuture%3CT as core::future::future::Future>::poll
    4: core::future::from_generator::GenFuture%3CT as core::future::future::Future>::poll
    5: tokio::runtime::task::harness::poll_future
    6: tokio::runtime::task::harness::Harness::poll
    7: std::thread::local::LocalKey::with
    8: tokio::runtime::thread_pool::worker::Context::run_task
    9: tokio::runtime::thread_pool::worker::Context::run
    10: tokio::macros::scoped_tls::ScopedKey::set
    11: tokio::runtime::thread_pool::worker::run
    12: tokio::runtime::blocking::task::BlockingTask%3CT as core::future::future::Future>::poll
    13: tokio::runtime::task::harness::Harness::poll
    14: tokio::runtime::blocking::pool::Inner::run
    15: std::sys_common::backtrace::__rust_begin_short_backtrace
    16: core::ops::function::FnOnce::call_once{{vtable.shim}}
    17: std::sys::unix::thread::Thread::new::thread_start
    18: __pthread_deallocate
    ```

  • Former Member's avatar
    Former Member

    I'm seeing a similar issue. It works in Terminal.app for me but it doesn't work in iTerm.app. I have also setup a Mac login item. However, 1Password never requests automation access to iTerm. So, under Security & Privacy > Privacy (Tab) > Automation > 1Password I only see a checkbox for Terminal and not iTerm. Following instructions in the same referenced docs I cannot get 1Password to request this automation access for iTerm.