
Product
Socket Now Supports pylock.toml Files
Socket now supports pylock.toml, enabling secure, reproducible Python builds with advanced scanning and full alignment with PEP 751's new standard.
This project focuses on managing JSON Web Tokens signed with RS256. Inspired by pyjwt,
this library provides core encode and decode functionality, utilizing the standard crypto
package within Go instead of
cryptography.
pip install pygo-jwt
import pygo_jwt
private_jwk = pygo_jwt.new_jwk(size=2048)
private_pem = pygo_jwt.jwk_to_pem(private_jwk)
public_jwk = pygo_jwt.extract_public_jwk(private_jwk)
public_pem = pygo_jwt.extract_public_pem(private_pem)
payload = {'message': 'hello world', 'count': 4}
token = pygo_jwt.encode(payload=payload, key=private_pem, mode='pem')
token_data = pygo_jwt.decode(token=token, key=public_jwk, mode='jwk')
go mod init main
go get github.com/rkhullar/python-libraries/pygo-jwt/pygo_jwt/go
package main
import (
"fmt"
lib "github.com/rkhullar/python-libraries/pygo-jwt/pygo_jwt/go/core"
)
func main() {
private_jwk, _ := lib.NewJWK(2048, nil)
private_pem, _ := lib.JWKToPEM(private_jwk)
fmt.Println(private_jwk)
fmt.Println(private_pem)
}
FAQs
Encode and Decode RS256 JSON Web Tokens with Python and Go
We found that pygo-jwt demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Product
Socket now supports pylock.toml, enabling secure, reproducible Python builds with advanced scanning and full alignment with PEP 751's new standard.
Security News
Research
Socket uncovered two npm packages that register hidden HTTP endpoints to delete all files on command.
Research
Security News
Malicious Ruby gems typosquat Fastlane plugins to steal Telegram bot tokens, messages, and files, exploiting demand after Vietnam’s Telegram ban.