Conditions | 3 |
Total Lines | 17 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | #!/usr/bin/env python |
||
22 | def run(self): |
||
23 | """ |
||
24 | Ping the Duo Platorm. |
||
25 | |||
26 | Returns: An dict with info returned by Duo. |
||
27 | |||
28 | Raises: |
||
29 | RuntimeError: On Invalid keys. |
||
30 | """ |
||
31 | |||
32 | try: |
||
33 | data = self.duo_auth.check() |
||
34 | except RuntimeError, e: |
||
35 | self.send_user_error(e) |
||
36 | raise RuntimeError("Check failed! '%s'" % e) |
||
37 | else: |
||
38 | return data |
||
39 |