Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Move the sanitizer to purely be a filter.#110

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
gsnedders merged 4 commits intohtml5lib:masterfromgsnedders:sanitizer-fixes-72
May 18, 2016

Conversation

gsnedders
Copy link
Member

@gsneddersgsnedders commentedAug 27, 2013
edited
Loading

This drops support for the tokenizing side of thing, which is sadly the only side that works in previous releases.Fixes#72. See all discussion there.

@hoppipolla-critic-bot

Critic review:https://critic.hoppipolla.co.uk/r/287

This is an external review system which you may optionally use for the code review of your pull request.

@landscape-bot
Copy link

Code Health
Repository health increased by 0.45% when pulling28fb733 on gsnedders:sanitizer-fixes-72 intof6741ea on html5lib:master.

@gsnedders
Copy link
MemberAuthor

I think when squashed this is now ready to land.

@landscape-bot
Copy link

Code Health
Repository health increased by 0.46% when pullingf582c58 on gsnedders:sanitizer-fixes-72 intof6741ea on html5lib:master.

As we no longer need the sanitizer to be shared between a filter anda tokenizer, move the entire sanitizer to the filter module.
This is imported into this repo as its expectations are very muchimplementation dependent, with expectations amended to match ouractual behaviour.
@landscape-bot
Copy link

Code Health
Repository health increased by 0.46% when pulling57dfcae on gsnedders:sanitizer-fixes-72 intof6741ea on html5lib:master.

# Remove attributes with disallowed URL values
for attr in (attr_names & self.attr_val_is_uri):
assert attr in attrs
# I don't have a clue where this regexp comes from or why it matches those
Copy link

@mgilsonmgilsonMay 20, 2016
edited
Loading

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

It looks like this regex is trying to remove:

`                Literal backtic...\x00-\x20        Ascii table characters starting at NULL up to and including Space -- Mostly non-printable characters...\x7f-\xa0        Bytes with values 127 (DELETE) -> 160.  More non-printable characters...\s               Whitespace

I don't know why it would be doing these things ...

Copy link
MemberAuthor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

My assumption is it's something to do with legacy attribute parsing in old UAs, for whom such characters can alter parsing.

@gsneddersgsnedders deleted the sanitizer-fixes-72 branchMay 20, 2016 17:18
gsnedders added a commit to gsnedders/html5lib-python that referenced this pull requestMay 22, 2016
This should be unneeded since the sanitizer changes (html5lib#110)
gsnedders added a commit to gsnedders/html5lib-python that referenced this pull requestJul 6, 2016
This should be unneeded since the sanitizer changes (html5lib#110)
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
0.99999999
Development

Successfully merging this pull request may close these issues.

Sanitizing filter broken in 0.90
4 participants
@gsnedders@hoppipolla-critic-bot@landscape-bot@mgilson

[8]ページ先頭

©2009-2025 Movatter.jp