Getting started with 1Password for your growing team, or refining your setup? Our Secured Success quickstart guide is for you.
Forum Discussion
Former Member
4 years agoBiometric not working when executing the CLI from java
Hello
I'm building a java CLI that wraps op for some operations.
The issue was first observed when running a native binary compiled with Graalvm, but after investigation it is perfectly reproduc...
Former Member
4 years agoHey @pierrebeitz ,
Thank you for reaching out to us!
I think you just uncovered a bug :D The issue here seems to be that the 1Password application enforces, on Linux, that the parent caller of the CLI would be owned by root. While in a normal use-case, such as making a CLI command from bash, this would not become apparent, it seems that in this case, since the /home/$USER/.asdf/installs/java/temurin-11.0.15+10/bin/java
file is most likely not owned by root, it does not pass this check.
Although I do not have a Linux system to run local tests on and to try to reproduce this issue, there are a couple of things that come to mind that you could try, in order to try to address this problem:
* prefix the op
command by /bin/bash -c
. This should ensure that the parent of the op
command is bash, which is owned already by root
* try changing the ownership of your java build to root, or install an alternative java version to be owned by root
These being said, we do realise that this is indeed not in line with what happens on the other OS's, and, from a security standpoint, it does not bring too much to the table, so I have opened an internal ticket for investigating getting rid of this check. I'll make sure to update you when any developments are made there. In the meantime, please, let us know if any of the workarounds from above would work for you. Otherwise, I'm going to set up a VM with a test environment, where hopefully I'll be able to come up with new ideas.
Looking forward to hearing from you!
Best,
Horia