Giter Club home page Giter Club logo

Comments (15)

joachimtingvold avatar joachimtingvold commented on June 19, 2024 3

I modified the existing code, removing historic stuff (v1 vs v2 CLI, login/logout, etc). Code reduced to about 25% of the original. Seems to work for me on my Mac. Have not done extensive testing yet, and untested on Windows. Biometric 1Password popup works as expected.

The only limitation (for now) is that it doesn't support multiple 1Password-accounts in the same dynamic folder. Also, the Account custom property is a required field even if you only have 1 account, and was done to make sure you are fetching credentials from the account you want (in case you have multiple, like I have).

I have not created a PR yet, as I'm not sure if it should be added as a separate script, or modify the existing one (as this script will only work on 1Password v8 or above).

  1. This assumes 1Password op CLI is setup and working. The script does no check if this is OK or not (could probably improve that part, but.. )
  2. Import the existing 1Password dynamic folder script.
  3. Replace the script code with the following; https://gist.github.com/joachimtingvold/fef17f2772ebd623b1b1ea4135e1e7f5
  4. Remove all of the Login Custom Properties (strictly not needed, but they are not used anymore)
  5. Add the Account custom property. Use the value from the USER ID column from op account list.
  6. Hit "Apply & Close", right click the dynamic folder, and choose "Reload".

The script should probably also be updated to be able to filter on tag(s).

from toolbox.

jvwam avatar jvwam commented on June 19, 2024 2

@joachimtingvold I've updated your scripts to allow for multiple vaults
In the Custom Properties vault field, add a comma separated list of vaults, otherwise it works the same
I haven't tested this extensively yet but I haven't encountered any issues
https://gist.github.com/jvwam/bd7ebeec596507cb1149a3561c8d43ff

from toolbox.

jvwam avatar jvwam commented on June 19, 2024 1

@joachimtingvold I've just tested this on Windows and it's working
The vault custom property is case-sensitive, not an issue if it's copied directly from op vault list

from toolbox.

joachimtingvold avatar joachimtingvold commented on June 19, 2024 1

@elbcloudhh, the version in PR #71 solves this (blank/undefined Vaults variable == use all vaults).

from toolbox.

SixFive7 avatar SixFive7 commented on June 19, 2024

Related to #46?

from toolbox.

StefanKoell avatar StefanKoell commented on June 19, 2024

I agree, if these options are now available (and reliably working) we should definitely utilize the newest version of the 1Password CLI (also assuming that there are no other downsides/showstoppers)

@SixFive7 would you be able to create a PR and/or test for that?

from toolbox.

sez76 avatar sez76 commented on June 19, 2024

Hello, in my case it doesn't work

Details:
System.ArgumentOutOfRangeException: Specified argument was out of the range of valid values. (Parameter 'TaskPath')
at ikdmg.pkfek(RoyalDynamicFolder ncrlj) in <9pbU/0LjpCexFwUaxM2copsqI6CCCN0x+6Hd3IhFJU1JsDLkQnLDomz/TIZwbEZbNCp1h9g5Fw5mi8/fIsEDaCN6gAqy3SaQ3IcDNn16PElix61Nvkgk/wNIikbYwvSXv3yauZsgmMrqg3nwCLjmyg==>:line 196

we still need to disable biometric usage for this to work ?

I'm in Windows 11

from toolbox.

unreliability avatar unreliability commented on June 19, 2024

3. https://gist.github.com/joachimtingvold/fef17f2772ebd623b1b1ea4135e1e7f5

Absolute lifesaver, can confirm this works PERFECTLY after months of trying just about anything to get multi-vault working with 1password 8 + Touch ID, cheers man, just made my evening! Should definitely be PR'd into the main branch!

from toolbox.

joachimtingvold avatar joachimtingvold commented on June 19, 2024

@joachimtingvold I've updated your scripts to allow for multiple vaults In the Custom Properties vault field, add a comma separated list of vaults, otherwise it works the same I haven't tested this extensively yet but I haven't encountered any issues https://gist.github.com/jvwam/bd7ebeec596507cb1149a3561c8d43ff

Excellent. I updated my gist with your changes, so people get the same result regardless of which gist they find (=

from toolbox.

elbcloudhh avatar elbcloudhh commented on June 19, 2024

Hi guys, this is amazing! Thank you. Would it be possible for the script to get all vaults automatically in a way that we don't have to maintain the vault list?

from toolbox.

lazynooblet avatar lazynooblet commented on June 19, 2024

@joachimtingvold thanks for your work. Using your PR I have RoyalTS working with 1Password using a dynamic folder and its really really neat.

I also use 1Password SSH agent, so that linux connections get the ssh key automatically. From a user perspective the SSH agent will approve the app (requiring re-auth) for the request and then subsequent requests for the same key are allowed automatically. So I only need to auth once.

With the dynamic folder, I have to re-auth 1Password every time I connect to a server, is there any way for it to cache the credentials for a period or an option in 1Password to allow a similar experience to the SSH agent?

from toolbox.

joachimtingvold avatar joachimtingvold commented on June 19, 2024

I think the problem is that Royal spawns a new iTerm2-process for each window/tab, which from 1Passwords perspective is not the same instance already authenticated. I notice that the 1Password authorization popup explicitly mentions Royal as the app (and not iTerm), so I guess there could be room for improvements in Royal.

from toolbox.

joachimtingvold avatar joachimtingvold commented on June 19, 2024

Actually, come to think of it, I do not need to re-auth to 1Password for each connection. I have to do it at launch, and when opening new connections after a while (i.e. it's been idle, or screensaver has been triggered, etc). Other than that I don't need to authorize in 1Password much.

from toolbox.

lazynooblet avatar lazynooblet commented on June 19, 2024

I'm not sure why I get a different experience. I get the Windows Hello request on every connection.

2023-09-12 09_55_57-app nooblet org (root) - Royal TS

  • I double click the connection
  • Authenticate with Windows Hello
  • Right click, duplicate, or double click a different connection
  • Authenticate with Windows Hello again

from toolbox.

lemonmojo avatar lemonmojo commented on June 19, 2024

Closing this now that the new implementation has been merged. If the issue is still present in the new version, please create a new GH issue.

from toolbox.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.