8261472: BasicConstraintsExtension::toString shows "PathLen:2147483647" if there is no pathLenConstraint #2493
…7" if there is no pathLenConstraint 8261472: BasicConstraintsExtension::toString shows "PathLen:2147483647" if there is no pathLenConstraint
@wangweij This change now passes all automated pre-integration checks.
After integration, the commit message for the final commit will be:
At the time when this comment was updated there had been 95 new commits pushed to the
As there are no conflicts, your changes will automatically be rebased on top of these commits when integrating. If you prefer to avoid this automatic rebasing, please check the documentation for the /integrate command for further details.
@wangweij Since your change was applied there have been 95 commits pushed to the
Your commit was automatically rebased without conflicts.
Pushed as commit 4619f37.
On 2/9/2021 9:02 PM, Weijun Wang wrote:
Sorry - not quite right, it's not quite that trivial a fix.
The definition for BasicConstraints is
If pathLenConstraint is not present, then the path length is infinite.??
You really ought to get the same encoding coming and going (e.g.
1) It's not valid to encode or decode pathLenConstraint in the DER as a
2) I'm not sure why the set/get methods were added.? I think it was to
3) And since the only place pathLen is available externally is in the
4) And to fix the problem that led to this discussion, change line 176
5) One more - in the other constructor, change line 108 to "this.pathLen
6) *sigh* Delete lines 197-201.? I have no idea why they are overriding
-------------- next part --------------
Thanks for the comments - a couple of observations of mine below --
On 2/10/21 12:53 AM, Michael StJohns wrote:
Some of this is due to the API for
"the value of pathLenConstraint if the BasicConstraints extension is
We need to be careful that for any changes we make, we still comply with
In this case, I would throw an Exception. If the pathLenConstraint is
The internal X509 classes have set/get/delete methods dating back to the
I think it is better to ensure that in this class, pathLen is never < 0,
That does seem a little weird.