Create UNIX sockets and proxy to the gpg4win agent
Project description
wsl2gpg
wsl2gpg is a small utility making it possible to use gpg in WSL (Windows Subsystem for Linux) with the agent from Gpg4win.
GnuPG's libassuan emulates sockets on Windows by listening on localhost and writing the TCP port number and a key to the "socket" file. This utility will listen on UNIX sockets in ~/.gnupg and proxy connections to the localhost TCP port. The key is automatically sent first.
With this, gpg in WSL can talk to the Gpg4win agent in Windows.
Usage
You can either install wsl2gpg with pip:
pip install wsl2gpg
Or alternatively just copy __init__.py
somewhere
and make it executable with chmod +x
Then, append a line to your .bashrc
(or rc file of your favorite shell)
to run wsl2gpg when you log in:
wsl2gpg -q -i &
You should then be able to use gpg in WSL as usual. For example, to show information on a Yubikey / smartcard:
$ gpg --card-status
Reader ...........: Yubico Yubikey 4 OTP U2F CCID 0
[...]
Potential Issues
Should the Windows user detection not work, you can set the username manually:
wsl2gpg -u yourwindowsuername
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file wsl2gpg-0.0.2.tar.gz
.
File metadata
- Download URL: wsl2gpg-0.0.2.tar.gz
- Upload date:
- Size: 4.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 7c7a19296539927762e43ffff4b6f76b3a7d9812ee026bbde6f6ebc2a878a92b |
|
MD5 | 39018df5740bdab5849783cf346c90de |
|
BLAKE2b-256 | 62dd2e3812ef867d480135d412a76a52be82b68f6f1064d37b90b2b673557e4b |
File details
Details for the file wsl2gpg-0.0.2-py3-none-any.whl
.
File metadata
- Download URL: wsl2gpg-0.0.2-py3-none-any.whl
- Upload date:
- Size: 8.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.2.0 requests-toolbelt/0.9.1 tqdm/4.48.0 CPython/3.8.2
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 812214aa2e17df6cac5e9fafbf3c788d3724eecbe9afea1685a63cdd979ec21b |
|
MD5 | 5d341f1f44d7ba3f792706a442366b2d |
|
BLAKE2b-256 | 9a22a0fa3d269f60f4109dd521b7d4f8b5534c131ac8f5db02a32fb78eb97189 |