Skip to content

Commit

Permalink
Merge pull request #121 from ties/increase-max-message-size
Browse files Browse the repository at this point in the history
Increase maximum PDU length that is decoded
  • Loading branch information
ties authored Jun 26, 2024
2 parents febec67 + 3b91cfa commit bf5793c
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion lib/structs.go
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,16 @@ type Logger interface {
}

const (
messageMaxSize = 2048
// We use the size of the largest sensible PDU.
//
// We ignore the theoretically unbounded length of SKIs for router keys.
// RPs should validate that this has the correct length.
//
// maximum size of ASPA PDU payload:
// * 2^16 providers * 32bit = 262144 bytes
// * length is inclusive of header: 8 bytes
// * flags/afi flags/provider as/customer AS: 16 bytes
messageMaxSize = 262168

PROTOCOL_VERSION_0 = 0
PROTOCOL_VERSION_1 = 1
Expand Down

0 comments on commit bf5793c

Please sign in to comment.