Using passphrase callback in ruby gpgme

后端 未结 3 1293
梦毁少年i
梦毁少年i 2021-01-06 14:04

I am using ruby gpgme gem (1.0.8). My passphrase callback isn\'t called:

def passfunc(*args)
  fd = args.last
  io = IO.for_fd(fd, \'w\')
  io.puts \"mypassp         


        
3条回答
  •  太阳男子
    2021-01-06 14:44

    It is important to note that as of GnuPG 2.0 (and in 1.4 when the use-agent option is used) pinentry is used for passphrase collection. This means that the gpgme passphrase callback will not be invoked. This is described here and an example of usage can be found in the gpgme-tool example.

提交回复
热议问题