misc: small fix or general refactoring i did not bother commenting

This commit is contained in:
evilsocket 2019-02-21 13:51:30 +01:00
parent a174c0d7ed
commit 99a60364cd
No known key found for this signature in database
GPG key ID: 1564D7F30393A456
3 changed files with 3 additions and 8 deletions

View file

@ -103,7 +103,7 @@ func CreateCertificate(cfg CertConfig) (error, *rsa.PrivateKey, []byte) {
KeyUsage: x509.KeyUsageKeyEncipherment | x509.KeyUsageDigitalSignature | x509.KeyUsageCertSign,
ExtKeyUsage: []x509.ExtKeyUsage{x509.ExtKeyUsageClientAuth, x509.ExtKeyUsageServerAuth},
BasicConstraintsValid: true,
IsCA: true,
IsCA: true,
}
cert, err := x509.CreateCertificate(rand.Reader, &template, &template, &priv.PublicKey, priv)

View file

@ -15,11 +15,7 @@
package gousb
/*
#cgo LDFLAGS: -lusb-1.0
#cgo CFLAGS: -I/usr/include/libusb-1.0 -I/data/data/com.termux/files/usr/include/libusb-1.0
#include <libusb.h>
*/
// #include <libusb.h>
import "C"
import "strconv"

View file

@ -24,8 +24,7 @@ import (
)
/*
#cgo LDFLAGS: -lusb-1.0
#cgo CFLAGS: -I/usr/include/libusb-1.0 -I/data/data/com.termux/files/usr/include/libusb-1.0
#cgo pkg-config: libusb-1.0
#include <libusb.h>
int gousb_compact_iso_data(struct libusb_transfer *xfer, unsigned char *status);