Closed sawanoboly closed 4 years ago
Currently, the following implementation parses the Link header and converts it to Hash.
https://github.com/unixcharles/acme-client/blob/3b24f0243e2d19d7250afca3acdcac55775ad487/lib/acme/client/faraday_middleware.rb#L87-L97
However, as mentioned in certbot's comment, it is better to take into account that the same rel is used more than once.
rel
https://github.com/certbot/certbot/pull/8080/files#diff-2ddf346e79198cd9bd28a8e8ee691b7bR802-R803
It's not urgent, but if there is a future change in the spec, such as multiple alternate certificates being issued in boulder, we may not be able to follow it.
https://github.com/unixcharles/acme-client/pull/191
Good catch.
Looking into it I also found that I'm not properly following the spec and it fail to match entries with a space (; rel= vs ;rel=)
; rel=
;rel=
Currently, the following implementation parses the Link header and converts it to Hash.
https://github.com/unixcharles/acme-client/blob/3b24f0243e2d19d7250afca3acdcac55775ad487/lib/acme/client/faraday_middleware.rb#L87-L97
However, as mentioned in certbot's comment, it is better to take into account that the same
rel
is used more than once.https://github.com/certbot/certbot/pull/8080/files#diff-2ddf346e79198cd9bd28a8e8ee691b7bR802-R803
It's not urgent, but if there is a future change in the spec, such as multiple alternate certificates being issued in boulder, we may not be able to follow it.