Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Prefer nonce.count
  • Loading branch information
Lukasa committed Jan 23, 2023
commit d9952eb08e7e69874c9fe0fad492e42a25437b10
2 changes: 1 addition & 1 deletion Sources/NIOSSH/TransportProtection/AESGCM.swift
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ extension AES.GCM.SealedBox {
// As a workaround for a Swift Crypto inefficiency, we create the combined representation
// directly.
var combined: [UInt8] = []
combined.reserveCapacity(12 + ciphertext.count + tag.count)
combined.reserveCapacity(nonce.count + ciphertext.count + tag.count)

combined.append(contentsOf: nonce)
combined.append(contentsOf: ciphertext)
Expand Down