-
Notifications
You must be signed in to change notification settings - Fork 109
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
10 changed files
with
80 additions
and
15 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "spider" | ||
version = "2.21.12" | ||
version = "2.21.13" | ||
authors = [ | ||
"j-mendez <[email protected]>" | ||
] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "spider_chrome" | ||
version = "2.21.12" | ||
version = "2.21.13" | ||
rust-version = "1.70" | ||
authors = [ | ||
"j-mendez <[email protected]>" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
use crate::handler::blockers::Trie; | ||
|
||
lazy_static::lazy_static! { | ||
/// Ignore list of urls. | ||
static ref URL_IGNORE_TRIE: Trie = { | ||
let mut trie = Trie::new(); | ||
let patterns = [ | ||
"https://meta.wikimedia.org/w/index.php?title=MediaWiki:Wikiminiatlas.js&action=raw&ctype=text/javascript", | ||
"https://meta.wikimedia.org/w/index.php?title=MediaWiki:Wikiminiatlas.js&action=raw&ctype=text/javascript", | ||
"https://login.wikimedia.org/wiki/Special:CentralAutoLogin/checkLoggedIn?useformat=desktop&wikiid=ptwiki&type=script&wikiid=ptwiki&type=script", | ||
".wikipedia.org/w/load.php?lang=pt&modules=ext.centralNotice.choiceData%2CgeoIP%2CstartUp%7Cext.centralauth.ForeignApi%2Ccentralautologin%7Cext.checkUser.clientHints%7Cext.cite.ux-enhancements%7Cext.cx.eventlogging.campaigns", | ||
".wikipedia.org/w/load.php?lang=pt&modules=startup&only=scripts&raw=1&skin=vector-2022", | ||
".eventlogging.campaigns", | ||
"%2CFeedbackHighlight%2", | ||
".quicksurveys.", | ||
"Special:CentralAutoLogin/start?type=script", | ||
]; | ||
for pattern in &patterns { | ||
trie.insert(pattern); | ||
} | ||
trie | ||
}; | ||
} | ||
|
||
// Block wikipedia events that are not required | ||
pub fn block_wikipedia( | ||
event: &chromiumoxide_cdp::cdp::browser_protocol::fetch::EventRequestPaused, | ||
) -> bool { | ||
URL_IGNORE_TRIE.contains_prefix(&event.request.url) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "spider_cli" | ||
version = "2.21.12" | ||
version = "2.21.13" | ||
authors = [ | ||
"j-mendez <[email protected]>" | ||
] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "spider_transformations" | ||
version = "2.21.12" | ||
version = "2.21.13" | ||
authors = [ | ||
"j-mendez <[email protected]>" | ||
] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "spider_utils" | ||
version = "2.21.12" | ||
version = "2.21.13" | ||
authors = [ | ||
"j-mendez <[email protected]>" | ||
] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
[package] | ||
name = "spider_worker" | ||
version = "2.21.12" | ||
version = "2.21.13" | ||
authors = [ | ||
"j-mendez <[email protected]>" | ||
] | ||
|