restructuring + tidying
This commit is contained in:
@ -41,7 +41,7 @@ type controller struct {
|
||||
}
|
||||
|
||||
// NewController returns an implementation of the Controller interface for creating new transports
|
||||
func NewController(config *config.Config,clock pub.Clock, client pub.HttpClient, log *logrus.Logger) Controller {
|
||||
func NewController(config *config.Config, clock pub.Clock, client pub.HttpClient, log *logrus.Logger) Controller {
|
||||
return &controller{
|
||||
config: config,
|
||||
clock: clock,
|
||||
@ -50,6 +50,7 @@ func NewController(config *config.Config,clock pub.Clock, client pub.HttpClient,
|
||||
}
|
||||
}
|
||||
|
||||
// NewTransport returns a new http signature transport with the given public key id (a URL), and the given private key.
|
||||
func (c *controller) NewTransport(pubKeyID string, privkey crypto.PrivateKey) (pub.Transport, error) {
|
||||
prefs := []httpsig.Algorithm{httpsig.RSA_SHA256, httpsig.RSA_SHA512}
|
||||
digestAlgo := httpsig.DigestSha256
|
||||
|
||||
Reference in New Issue
Block a user