mirror of
https://github.com/henrybear327/Proton-API-Bridge.git
synced 2026-05-24 06:45:40 -04:00
Fix signing of SetContentKeyPacketAndSignature
This commit is contained in:
6
file.go
6
file.go
@@ -242,7 +242,7 @@ func (protonDrive *ProtonDrive) DownloadFile(ctx context.Context, link *proton.L
|
||||
return nil, 0, nil, err
|
||||
}
|
||||
|
||||
sessionKey, err := link.GetSessionKey(protonDrive.AddrKR, nodeKR)
|
||||
sessionKey, err := link.GetSessionKey(nodeKR)
|
||||
if err != nil {
|
||||
return nil, 0, nil, err
|
||||
}
|
||||
@@ -438,7 +438,7 @@ func (protonDrive *ProtonDrive) createFileUploadDraft(ctx context.Context, paren
|
||||
return "", "", nil, nil, err
|
||||
}
|
||||
|
||||
newSessionKey, err := createFileReq.SetContentKeyPacketAndSignature(newNodeKR, protonDrive.AddrKR)
|
||||
newSessionKey, err := createFileReq.SetContentKeyPacketAndSignature(newNodeKR)
|
||||
if err != nil {
|
||||
return "", "", nil, nil, err
|
||||
}
|
||||
@@ -516,7 +516,7 @@ func (protonDrive *ProtonDrive) createFileUploadDraft(ctx context.Context, paren
|
||||
if err != nil {
|
||||
return "", "", nil, nil, err
|
||||
}
|
||||
newSessionKey, err = link.GetSessionKey(protonDrive.AddrKR, newNodeKR)
|
||||
newSessionKey, err = link.GetSessionKey(newNodeKR)
|
||||
if err != nil {
|
||||
return "", "", nil, nil, err
|
||||
}
|
||||
|
||||
2
go.mod
2
go.mod
@@ -5,7 +5,7 @@ go 1.18
|
||||
require (
|
||||
github.com/ProtonMail/gluon v0.17.0
|
||||
github.com/ProtonMail/gopenpgp/v2 v2.7.2
|
||||
github.com/henrybear327/go-proton-api v0.0.0-20230723062344-776bc2954583
|
||||
github.com/henrybear327/go-proton-api v0.0.0-20230723213442-6a56030e2edc
|
||||
github.com/relvacode/iso8601 v1.3.0
|
||||
golang.org/x/sync v0.3.0
|
||||
)
|
||||
|
||||
4
go.sum
4
go.sum
@@ -49,8 +49,8 @@ github.com/go-resty/resty/v2 v2.7.0/go.mod h1:9PWDzw47qPphMRFfhsyk0NnSgvluHcljSM
|
||||
github.com/goccy/go-json v0.10.2 h1:CrxCmQqYDkv1z7lO7Wbh2HN93uovUHgrECaO5ZrCXAU=
|
||||
github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I=
|
||||
github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
|
||||
github.com/henrybear327/go-proton-api v0.0.0-20230723062344-776bc2954583 h1:Bbv0iyHKIr2ZXSOKcG4Ja8Z+NxWKdOVqGSLd3/SQTLk=
|
||||
github.com/henrybear327/go-proton-api v0.0.0-20230723062344-776bc2954583/go.mod h1:l42xBSOrCmkAxzWUHcoUsG/cP8m1hMhV72GoChOX3bg=
|
||||
github.com/henrybear327/go-proton-api v0.0.0-20230723213442-6a56030e2edc h1:KivXKtS1s0BZiL+0CSPzT5dPcF+zEjysXXqkA/G1SH8=
|
||||
github.com/henrybear327/go-proton-api v0.0.0-20230723213442-6a56030e2edc/go.mod h1:l42xBSOrCmkAxzWUHcoUsG/cP8m1hMhV72GoChOX3bg=
|
||||
github.com/json-iterator/go v1.1.12 h1:PV8peI4a0ysnczrg+LtxykD8LfKY9ML6u2jnxaEnrnM=
|
||||
github.com/klauspost/cpuid/v2 v2.2.4 h1:acbojRNwl3o09bUq+yDCtZFc1aiwaAAxtcn8YkZXnvk=
|
||||
github.com/leodido/go-urn v1.2.4 h1:XlAE/cm/ms7TE/VMVoduSpNBoyc2dOxHs5MZSwAN63Q=
|
||||
|
||||
Reference in New Issue
Block a user