[Secure-testing-commits] r13713 - bin
Raphael Geissert
geissert at alioth.debian.org
Tue Jan 5 00:36:45 UTC 2010
Author: geissert
Date: 2010-01-05 00:36:43 +0000 (Tue, 05 Jan 2010)
New Revision: 13713
Modified:
bin/check-new-issues
Log:
add .h command to list available commands
add ! command to execute any command via system()
Modified: bin/check-new-issues
===================================================================
--- bin/check-new-issues 2010-01-04 23:43:03 UTC (rev 13712)
+++ bin/check-new-issues 2010-01-05 00:36:43 UTC (rev 13713)
@@ -9,25 +9,34 @@
my %opts;
getopts('ln:fhi:t:Tca:e:uU', \%opts);
-if ($opts{h}) {
+sub print_commands {
print <<'EOF';
-downloads allitems.txt from cve.mitre.org and shows full decription for each
-"TODO: check" item (2003 and newer). Then
-
-- tries to guess product name and php filename and does
- apt-cache and apt-file search
-- waits for input:
* blank line to skip to next issue
* .fname to do "apt-file search name"
* .cname to do "apt-cache search name"
* .wname to look up name in wnpp
* .mpackage to search data/embedded-code-copies for "package"
* .rpackage to launch an editor with a report of the issue against "package"
+ * !command to execute a command with system() without any escaping
* v or e to launch an editor with the current item
* q to save and quit
* CTRL-C to quit without saving
* everything else is inserted as product name for a NOT-FOR-US
+EOF
+}
+if ($opts{h}) {
+ print <<'EOF';
+downloads allitems.txt from cve.mitre.org and shows full decription for each
+"TODO: check" item (2003 and newer). Then
+
+- tries to guess product name and php filename and does
+ apt-cache and apt-file search
+- waits for input:
+EOF
+ print_commands;
+ print <<'EOF';
+
Use "svn diff" and "svn revert" as needed ;-)
OPTIONS: [ -l [-n <n>] [-f] ]
@@ -239,6 +248,15 @@
search_embed($s) or print "none\n";
next READ;
}
+ elsif ($r=~ /^.h/i ) {
+ print_commands;
+ next READ;
+ }
+ elsif ($r=~ /^!(.+)$/ ) {
+ system($1);
+ print "exit status: $?\n";
+ next READ;
+ }
elsif ($r=~ /^q$/i ) {
last TODO;
}
More information about the Secure-testing-commits
mailing list