aboutsummaryrefslogtreecommitdiff
path: root/rp/utils
diff options
context:
space:
mode:
authorRob Austein <sra@hactrn.net>2014-05-31 18:32:19 +0000
committerRob Austein <sra@hactrn.net>2014-05-31 18:32:19 +0000
commita7cad7f4aab21d48eb783935dfabb9859bcc4f37 (patch)
treefa8ec4816cfbef4bb3edf01319fe4b7db9b3a73b /rp/utils
parent61309aa7e3c4d8abb6b7e78c979c851f59a70fc4 (diff)
Still more PyLint.
svn path=/trunk/; revision=5856
Diffstat (limited to 'rp/utils')
-rwxr-xr-xrp/utils/find_roa10
-rwxr-xr-xrp/utils/hashdir6
-rwxr-xr-xrp/utils/print_roa8
-rwxr-xr-xrp/utils/print_rpki_manifest8
-rwxr-xr-xrp/utils/scan_roas6
-rwxr-xr-xrp/utils/scan_routercerts6
-rwxr-xr-xrp/utils/uri9
7 files changed, 23 insertions, 30 deletions
diff --git a/rp/utils/find_roa b/rp/utils/find_roa
index 1fc0af3d..4cfcccac 100755
--- a/rp/utils/find_roa
+++ b/rp/utils/find_roa
@@ -1,13 +1,13 @@
#!/usr/bin/env python
#
# $Id$
-#
+#
# Copyright (C) 2014 Dragon Research Labs ("DRL")
-#
+#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
-#
+#
# THE SOFTWARE IS PROVIDED "AS IS" AND DRL DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
# AND FITNESS. IN NO EVENT SHALL DRL BE LIABLE FOR ANY SPECIAL, DIRECT,
@@ -22,8 +22,6 @@ matching specified prefixes.
"""
import os
-import sys
-import base64
import argparse
import rpki.POW
import rpki.oids
@@ -54,7 +52,7 @@ class Prefix(object):
def __init__(self, val):
addr, length = val.split("/")
- length, sep, maxlength = length.partition("-")
+ length, sep, maxlength = length.partition("-") # pylint: disable=W0612
self.prefix = rpki.POW.IPAddress(addr)
self.length = int(length)
self.maxlength = int(maxlength) if maxlength else self.length
diff --git a/rp/utils/hashdir b/rp/utils/hashdir
index 2f02cd3b..d3fe393c 100755
--- a/rp/utils/hashdir
+++ b/rp/utils/hashdir
@@ -1,13 +1,13 @@
#!/usr/bin/env python
#
# $Id$
-#
+#
# Copyright (C) 2014 Dragon Research Labs ("DRL")
-#
+#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
-#
+#
# THE SOFTWARE IS PROVIDED "AS IS" AND DRL DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
# AND FITNESS. IN NO EVENT SHALL DRL BE LIABLE FOR ANY SPECIAL, DIRECT,
diff --git a/rp/utils/print_roa b/rp/utils/print_roa
index fd7308d1..d5db0c3c 100755
--- a/rp/utils/print_roa
+++ b/rp/utils/print_roa
@@ -1,13 +1,13 @@
#!/usr/bin/env python
#
# $Id$
-#
+#
# Copyright (C) 2014 Dragon Research Labs ("DRL")
-#
+#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
-#
+#
# THE SOFTWARE IS PROVIDED "AS IS" AND DRL DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
# AND FITNESS. IN NO EVENT SHALL DRL BE LIABLE FOR ANY SPECIAL, DIRECT,
@@ -21,8 +21,6 @@ Pretty-print the content of a ROA. Does NOT attempt to verify the
signature.
"""
-import os
-import sys
import argparse
import rpki.POW
diff --git a/rp/utils/print_rpki_manifest b/rp/utils/print_rpki_manifest
index 778b4310..5ebc6356 100755
--- a/rp/utils/print_rpki_manifest
+++ b/rp/utils/print_rpki_manifest
@@ -1,13 +1,13 @@
#!/usr/bin/env python
#
# $Id$
-#
+#
# Copyright (C) 2014 Dragon Research Labs ("DRL")
-#
+#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
-#
+#
# THE SOFTWARE IS PROVIDED "AS IS" AND DRL DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
# AND FITNESS. IN NO EVENT SHALL DRL BE LIABLE FOR ANY SPECIAL, DIRECT,
@@ -21,8 +21,6 @@ Pretty-print the content of a manifest. Does NOT attempt to verify the
signature.
"""
-import os
-import sys
import argparse
import rpki.POW
import rpki.oids
diff --git a/rp/utils/scan_roas b/rp/utils/scan_roas
index 1f5746b1..a1b64f01 100755
--- a/rp/utils/scan_roas
+++ b/rp/utils/scan_roas
@@ -1,13 +1,13 @@
#!/usr/bin/env python
#
# $Id$
-#
+#
# Copyright (C) 2014 Dragon Research Labs ("DRL")
-#
+#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
-#
+#
# THE SOFTWARE IS PROVIDED "AS IS" AND DRL DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
# AND FITNESS. IN NO EVENT SHALL DRL BE LIABLE FOR ANY SPECIAL, DIRECT,
diff --git a/rp/utils/scan_routercerts b/rp/utils/scan_routercerts
index aa3ed9e6..081a6293 100755
--- a/rp/utils/scan_routercerts
+++ b/rp/utils/scan_routercerts
@@ -1,12 +1,12 @@
#!/usr/bin/env python
# $Id$
-#
+#
# Copyright (C) 2014 Dragon Research Labs ("DRL")
-#
+#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
-#
+#
# THE SOFTWARE IS PROVIDED "AS IS" AND DRL DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
# AND FITNESS. IN NO EVENT SHALL DRL BE LIABLE FOR ANY SPECIAL, DIRECT,
diff --git a/rp/utils/uri b/rp/utils/uri
index e095eb30..e72d5e0d 100755
--- a/rp/utils/uri
+++ b/rp/utils/uri
@@ -1,13 +1,13 @@
#!/usr/bin/env python
#
# $Id$
-#
+#
# Copyright (C) 2014 Dragon Research Labs ("DRL")
-#
+#
# Permission to use, copy, modify, and/or distribute this software for any
# purpose with or without fee is hereby granted, provided that the above
# copyright notice and this permission notice appear in all copies.
-#
+#
# THE SOFTWARE IS PROVIDED "AS IS" AND DRL DISCLAIMS ALL WARRANTIES WITH
# REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
# AND FITNESS. IN NO EVENT SHALL DRL BE LIABLE FOR ANY SPECIAL, DIRECT,
@@ -24,7 +24,6 @@ Input files must be in DER format and may be either X.509v3 certificates
or CMS objects which contain X.509v3 certificates in the CMS wrapper.
"""
-import os
import argparse
import rpki.POW
@@ -41,7 +40,7 @@ class Certificate(object):
def __init__(self, fn):
try:
x = rpki.POW.X509.derReadFile(fn)
- except:
+ except: # pylint: disable=W0702
try:
cms = rpki.POW.CMS.derReadFile(fn)
cms.extractWithoutVerifying()