Skip to content

Commit

Permalink
Fix Ubuntu AWS kernel crawler (again)
Browse files Browse the repository at this point in the history
We skipped some linux-aws-headers packages before.

Also, collapsing the regexes halves the crawler time.
  • Loading branch information
gnosek committed Mar 11, 2020
1 parent 839cd51 commit ef8b0e0
Showing 1 changed file with 2 additions and 16 deletions.
18 changes: 2 additions & 16 deletions probe-builder/kernel-crawler.py
Original file line number Diff line number Diff line change
Expand Up @@ -133,29 +133,15 @@ def sqlite_column(row, col):
"root" : "https://mirrors.kernel.org/ubuntu/pool/main/l/",
"discovery_pattern" : "/html/body//a[regex:test(@href, 'linux-aws.*/')]/@href",
"subdirs" : [""],
"page_pattern" : "/html/body//a[regex:test(@href, '^linux-(image|(aws-.*)?headers)-[3-9].*-aws.*amd64.deb$')]/@href"
},

{
"root" : "https://mirrors.kernel.org/ubuntu/pool/main/l/",
"discovery_pattern" : "/html/body//a[regex:test(@href, 'linux-aws.*/')]/@href",
"subdirs" : [""],
"page_pattern" : "/html/body//a[regex:test(@href, '^linux-(aws-.*)?headers-[3-9].*_all.deb$')]/@href"
"page_pattern" : "/html/body//a[regex:test(@href, '^linux-(image|(aws-.*)?headers|modules)-[3-9].*(all|amd64).deb$')]/@href"
},

{
"root" : "http://security.ubuntu.com/ubuntu/pool/main/l/",
"discovery_pattern" : "/html/body//a[regex:test(@href, 'linux-aws.*/')]/@href",
"subdirs" : [""],
"page_pattern" : "/html/body//a[regex:test(@href, '^linux-(image|(aws-.*)?headers)-[3-9].*-aws.*amd64.deb$')]/@href"
"page_pattern" : "/html/body//a[regex:test(@href, '^linux-(image|(aws-.*)?headers|modules)-[3-9].*(all|amd64).deb$')]/@href"
},

{
"root" : "http://security.ubuntu.com/ubuntu/pool/main/l/",
"discovery_pattern" : "/html/body//a[regex:test(@href, 'linux-aws.*/')]/@href",
"subdirs" : [""],
"page_pattern" : "/html/body//a[regex:test(@href, '^linux-modules-[3-9].*-aws.*amd64.deb$')]/@href"
}
],

"Fedora" : [
Expand Down

0 comments on commit ef8b0e0

Please sign in to comment.