Unlock any CLI using biometrics with 1Password Shell Plugins
Tags: programming
Published: 2022-12-07 17:49:08

I love Touch ID. When I use it to log in to a site or authorize a purchase, authentication just kind of _happens_. It doesn’t feel futuristic anymore, but it does feel like the present. It’s the modern computing experience.
​
Then I open my terminal, and I'm transported right back to the past. Why can't devs have that modern experience?
​
I know I'm not alone. When we introduced Touch ID support for [1Password CLI 2.0](https://blog.1password.com/1password-cli-2_0/), one of the most frequent pieces of feedback we heard was: Can we have touch ID for _all_ CLIs? 
​
So, about that. 
​
## Introducing 1Password Shell Plugins

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iguomkv9cpgr59h73mt7.gif)
​
We use CLIs to perform quick actions from the comfort of our terminals and automate recurring tasks. You might use the [GitLab CLI](https://about.gitlab.com/blog/2022/12/07/introducing-the-gitlab-cli/) to submit your code in a merge request, so the team can review it and include it in the next release, for example. Many other developer platforms like [AWS](https://aws.amazon.com/cli/), [Stripe](https://stripe.com/docs/stripe-cli), [Sentry](https://docs.sentry.io/product/cli/), and [CircleCI](https://circleci.com/docs/local-cli/) offer CLIs as well.
​
Connecting a CLI to your online account often involves generating API access keys in a browser, then pasting those values into the terminal. Those credentials are usually saved in a plaintext config file that gives the CLI persistent access to your account, even after reboots. But if an attacker or process gains access to your system, they have the same level of access to your account that you do. 
​
We built [1Password Shell Plugins](https://developer.1password.com/docs/cli/shell-plugins) so you can securely store all of your access keys in encrypted 1Password vaults, rather than on disk. When you use a Shell Plugin for a particular service, access to the associated API keys is restricted to your specific terminal session. 
​
Because they're saved in 1Password, you can securely sign in to any CLI with your fingerprint or another form of biometrics. If the service supports it, MFA codes can be filled automatically  – so there’s no need to pull out your phone multiple times every day.
​
In fact, there’s no need to type _anything_. No plaintext, no typing passwords, no hassle – you can stay in the zone and focus on the task at hand. 
​
## Extensibility built in
​
We’ve already built Shell Plugins for many popular CLIs, including:
- [GitLab](https://developer.1password.com/docs/cli/shell-plugins/gitlab)
- [CircleCI](https://developer.1password.com/docs/cli/shell-plugins/circleci)
- [Amazon Web Services](https://developer.1password.com/docs/cli/shell-plugins/aws)
- [Sentry](https://developer.1password.com/docs/cli/shell-plugins/sentry) (Get $240 in Sentry credits with code “1Password”) 
- [Stripe](https://developer.1password.com/docs/cli/shell-plugins/stripe)
- [Twilio](https://developer.1password.com/docs/cli/shell-plugins/twilio)
- [GitHub](https://developer.1password.com/docs/cli/shell-plugins/github)
​

There are [many more pre-built integrations](https://developer.1password.com/docs/cli/shell-plugins), but you’re not limited to the ones we built. You can build your own, for any CLI. 
​
Shell Plugins are fully extensible and aren’t restricted to specific services. If you don't see an integration you need, you can join the open source project (currently in beta) and [contribute your own](https://developer.1password.com/docs/cli/shell-plugins/contribute/). 
​
Want to add MFA support to an existing Shell Plugin? You can do that too.
​
​
> _Many of our users rely on GitLab to shorten code review cycles, increase their developer productivity and strengthen overall security at every step. 1Password’s latest rollout is an important development in that last bucket. Launching Shell Plugins will help ensure developers can access our tools in their terminals as quickly and securely as possible._ – Kai Armstrong, senior product manager, GitLab
​
## Your keys, but portable
​
Storing your keys in 1Password means you can use them _everywhere_. If you switch to a different machine, system, or environment, the process is exactly the same. 
​
Just install and configure Shell Plugins on your machine, then use biometrics to grant access to your key in 1Password. If the plugin supports MFA, you can use 1Password to autofill the codes.
​
This all makes setup, developer onboarding, and collaboration simpler. If new teammates are in the relevant group in 1Password, they already have the permissions they need to access the shared credentials and contribute immediately. All they have to do is install the [1Password CLI](https://1password.com/downloads/command-line/) and the appropriate Shell Plugins.
​
## How Shell Plugins work
​
Once you've set up 1Password CLI, you can install a supported Shell Plugin with a single command. For example, to install the plugin for GitLab, you would run:
​
`op plugin init glab`
​

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/27flmwv6vc6oclzp9r8o.png)
​
During the configuration process, you can import existing credentials from your config file or create new credentials in 1Password. 
​

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7jjcspqd1epzjnhd2ouc.png)
​
At this point, your credentials are safely stored in 1Password, so you can remove them from your disk. 
​
[Check out the developer docs](https://developer.1password.com/docs/cli/shell-plugins/) to learn more about Shell Plugins.
​

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/m0ywimmrzua7h9uyz86a.png)
​
## Introducing CI/CD integrations
​
One more thing. When you’re setting up a CI/CD workflow, you often need to manually enter secrets by visiting the settings page of the tool you’re using. But now you can store those secrets in 1Password, too. 
​
You can access them directly within your CI/CD tools – and reference their location in 1Password directly within the job that requires them – via new integrations for:
- [CircleCI](http://developer.1password.com/docs/ci-cd/circle-ci)
- [Jenkins](http://developer.1password.com/docs/ci-cd/jenkins)
- [GitHub Actions](https://developer.1password.com/docs/ci-cd/github-actions)
​

Again, feel free to [jump into the documentation](https://developer.1password.com/docs/ci-cd/) to get started.
​
## Securing the software development life cycle
​
Our goal is to bring this same level of security and ease of use to the entire [software development life cycle](https://1password.com/developers/). My colleague, Marc Mackenbach, has written about [how far the developer user experience has to go](https://blog.1password.com/developers-deserve-great-ux/) before it catches up with the consumer experience in terms of both security and UX.
​
We're working on that. Check out [1Password.com/developers](https://1password.com/developers/) for a quick overview of everything we’re building to secure developer workflows. In the meantime, feel free to [start exploring the Shell Plugins documentation](https://developer.1password.com/docs/cli/shell-plugins/). 
​
And maybe keep your phone in your pocket. You won’t need it nearly as often anymore. 😉