Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

assert correct URLs #35

Closed
jkowalleck opened this issue Dec 2, 2021 · 1 comment · Fixed by #34
Closed

assert correct URLs #35

jkowalleck opened this issue Dec 2, 2021 · 1 comment · Fixed by #34
Assignees
Labels
bug Something isn't working

Comments

@jkowalleck
Copy link
Member

jkowalleck commented Dec 2, 2021

caused by CycloneDX/cyclonedx-php-composer#158


have all the XML strings that are anyURI somehow fixed before rendering the XML.
affected elements:

  • component.purl
  • license.url
  • externalReterence.url
  • and so on ...

according to XML spec the anyURI needs to conform to https://www.ietf.org/rfc/rfc2396.txt

 * @see http://www.w3.org/TR/xmlschema-2/#anyURI
 * @see http://www.datypic.com/sc/xsd/t-xsd_anyURI.html


    /* URIs require that some characters be escaped with their hexadecimal Unicode code point preceded by the %
     * character. This includes non-ASCII characters and some ASCII characters, namely control characters, spaces,
     * and the following characters (unless they are used as deliimiters in the URI): <>#%{}|\^`.
     * [...]
     * The only values that are not accepted are ones that make inappropriate use of reserved characters, such as ones that contain multiple # characters or have % characters that are not followed by two hexadecimal digits.
     * -- as of http://www.datypic.com/sc/xsd/t-xsd_anyURI.html
     */
@jkowalleck
Copy link
Member Author

jkowalleck commented Dec 2, 2021

maybe caused by: #19
related by: #18

jkowalleck added a commit that referenced this issue Dec 2, 2021
jkowalleck added a commit that referenced this issue Dec 2, 2021
jkowalleck added a commit that referenced this issue Dec 2, 2021
jkowalleck added a commit that referenced this issue Dec 3, 2021
jkowalleck added a commit that referenced this issue Dec 3, 2021
related to #35

Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
jkowalleck added a commit that referenced this issue Dec 3, 2021
related to #35

Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
@jkowalleck jkowalleck unpinned this issue Dec 4, 2021
@jkowalleck jkowalleck changed the title XML anyURI escape/fix on rendereing assert correct URLs Dec 2, 2023
jkowalleck added a commit that referenced this issue Dec 2, 2023
migrate/fixup URLs when normalizing to JSON

followup of #35 

---------

Signed-off-by: Jan Kowalleck <jan.kowalleck@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant