Commit ba4f51fc authored by Sietse Ringers's avatar Sietse Ringers
Browse files

Fix wrong version negotiation in server

parent 9fb10b35
......@@ -111,7 +111,7 @@ func (session *session) getProofP(commitments *irma.IssueCommitmentMessage, sche
// Other
func chooseProtocolVersion(min, max *irma.ProtocolVersion) (*irma.ProtocolVersion, error) {
if min.AboveVersion(minProtocolVersion) || max.BelowVersion(min) {
if min.AboveVersion(maxProtocolVersion) || max.BelowVersion(minProtocolVersion) || max.BelowVersion(min) {
return nil, errors.Errorf("Protocol version negotiation failed, min=%s max=%s", min.String(), max.String())
}
if max.AboveVersion(maxProtocolVersion) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment