Skip to content

Commit

Permalink
fix(v2): Adapt NewForwardingEntity to refactored NewEntity
Browse files Browse the repository at this point in the history
  • Loading branch information
lubux committed Feb 28, 2024
1 parent 16f8541 commit 54e58ae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions openpgp/v2/forwarding.go
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,6 @@ func (e *Entity) NewForwardingEntity(
// Generate a new Primary key for the forwardee
config.Algorithm = packet.PubKeyAlgoEdDSA
config.Curve = packet.Curve25519
keyLifetimeSecs := config.KeyLifetime()

forwardeePrimaryPrivRaw, err := newSigner(config)
if err != nil {
Expand All @@ -49,7 +48,8 @@ func (e *Entity) NewForwardingEntity(
Subkeys: []Subkey{},
}

err = forwardeeKey.addUserId(userIdData{name, comment, email}, config, now, keyLifetimeSecs, true)
keyProperties := selectKeyProperties(now, config, primary)
err = forwardeeKey.addUserId(userIdData{name, comment, email}, config, keyProperties)
if err != nil {
return nil, nil, err
}
Expand Down

0 comments on commit 54e58ae

Please sign in to comment.