Closed makerj closed 4 years ago
https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L415 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L418 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L489 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L508 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L519 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L523 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L531
By PKCS#11 specification,
ulMaxObjectCount is the maximum number of object handles to be returned
So, I think the value of third parameter should be capacity of object variable(in this case, 5), not a octet count of object variable.
object
5
Good spot! Does #31 look like it covers all the places you found?
Yes, #31 covers all the places. (whole project, AFAIK.) Thank you.
https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L415 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L418 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L489 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L508 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L519 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L523 https://github.com/google/pkcs11test/blob/ccd37ec33be75e61a6fc4c48a3fa928577e691d2/object.cc#L531
By PKCS#11 specification,
So, I think the value of third parameter should be capacity of
object
variable(in this case,5
), not a octet count ofobject
variable.