Skip to content

Commit a401afd

Browse files
committed
2 parents f2e6f1a + 8a3ae32 commit a401afd

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

76 files changed

+5290
-804
lines changed

.appveyor.yml

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
version: '1.7.1.dev.{build}'
2+
3+
build: off
4+
branches:
5+
only:
6+
- master
7+
- develop
8+
9+
environment:
10+
matrix:
11+
- PYTHON: "C:\\Python26"
12+
- PYTHON: "C:\\Python26-x64"
13+
- PYTHON: "C:\\Python27"
14+
- PYTHON: "C:\\Python27-x64"
15+
- PYTHON: "C:\\Python33"
16+
- PYTHON: "C:\\Python33-x64"
17+
- PYTHON: "C:\\Python34"
18+
- PYTHON: "C:\\Python34-x64"
19+
- PYTHON: "C:\\Python35"
20+
- PYTHON: "C:\\Python35-x64"
21+
- PYTHON: "C:\\Python36"
22+
- PYTHON: "C:\\Python36-x64"
23+
matrix:
24+
fast_finish: true
25+
26+
cache:
27+
- '%LOCALAPPDATA%\pip\Cache'
28+
- .downloads -> .appveyor.yml
29+
30+
install:
31+
- "cmd /c .\\test\\tools\\ci-win.cmd install"
32+
33+
test_script:
34+
- "cmd /c .\\test\\tools\\ci-win.cmd test"
35+
36+
on_failure:
37+
- ps: get-content .tox\*\log\*

.gitignore

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
*~
22
*.pyc
3-
html/
4-
venv/
5-
.cache/
3+
venv*/
4+
.cache/
5+
.tox
6+
.coverage*
7+
reports/
8+
.scannerwork/
9+
pypi/sshaudit/LICENSE
10+
pypi/sshaudit/README.md
11+
pypi/sshaudit/sshaudit.py

.travis.yml

Lines changed: 75 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,80 @@
11
language: python
2-
python:
3-
- 2.6
4-
- 2.7
5-
- 3.3
6-
- 3.4
7-
- 3.5
8-
- pypy
9-
- pypy3
2+
sudo: false
3+
matrix:
4+
include:
5+
# (default)
6+
- os: linux
7+
python: 2.6
8+
- os: linux
9+
python: 2.7
10+
env: SQ=1
11+
- os: linux
12+
python: 3.3
13+
- os: linux
14+
python: 3.4
15+
- os: linux
16+
python: 3.5
17+
- os: linux
18+
python: 3.6
19+
- os: linux
20+
python: pypy
21+
- os: linux
22+
python: pypy3
23+
- os: linux
24+
python: 3.7-dev
25+
# Ubuntu 12.04
26+
- os: linux
27+
dist: precise
28+
language: generic
29+
env: PY_VER=py26,py27,py33,py34,py35,py36,pypy,pypy3 PY_ORIGIN=pyenv
30+
# Ubuntu 14.04
31+
- os: linux
32+
dist: trusty
33+
language: generic
34+
env: PY_VER=py26,py27,py33,py34,py35,py36,pypy,pypy3 PY_ORIGIN=pyenv
35+
# macOS 10.12 Sierra
36+
- os: osx
37+
osx_image: xcode8.3
38+
language: generic
39+
env: PY_VER=py26,py27,py33,py34,py35,py36,pypy,pypy3
40+
# Mac OS X 10.11 El Capitan
41+
- os: osx
42+
osx_image: xcode7.3
43+
language: generic
44+
env: PY_VER=py26,py27,py33,py34,py35,py36,pypy,pypy3
45+
# Mac OS X 10.10 Yosemite
46+
- os: osx
47+
osx_image: xcode6.4
48+
language: generic
49+
env: PY_VER=py26,py27,py33,py34,py35,py36,pypy,pypy3
50+
allow_failures:
51+
# PyPy3 on Travis CI is out of date
52+
- python: pypy3
53+
# Python nightly could fail
54+
- python: 3.7-dev
55+
- env: PY_VER=py37
56+
- env: PY_VER=py37/pyenv
57+
- env: PY_VER=py37 PY_ORIGIN=pyenv
58+
fast_finish: true
59+
60+
cache:
61+
- pip
62+
- directories:
63+
- $HOME/.pyenv.cache
64+
- $HOME/.bin
65+
66+
before_install:
67+
- source test/tools/ci-linux.sh
68+
- ci_step_before_install
69+
1070
install:
11-
- pip install --upgrade pytest
12-
- pip install --upgrade pytest-cov
13-
- pip install --upgrade coveralls
71+
- ci_step_install
72+
1473
script:
15-
- py.test --cov-report= --cov=ssh-audit -v test
74+
- ci_step_script
75+
1676
after_success:
17-
- coveralls
77+
- ci_step_success
1878

79+
after_failure:
80+
- ci_step_failure

LICENSE

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
The MIT License (MIT)
22

3-
Copyright (C) 2016 Andris Raugulis ([email protected])
3+
Copyright (C) 2017 Andris Raugulis ([email protected])
4+
Copyright (C) 2017-2019 Joe Testa ([email protected])
5+
46

57
Permission is hereby granted, free of charge, to any person obtaining a copy
68
of this software and associated documentation files (the "Software"), to deal

README.md

Lines changed: 39 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,42 +1,73 @@
11
# ssh-audit
2-
[![build status](https://api.travis-ci.org/arthepsy/ssh-audit.svg)](https://travis-ci.org/arthepsy/ssh-audit)
3-
[![coverage status](https://coveralls.io/repos/github/arthepsy/ssh-audit/badge.svg)](https://coveralls.io/github/arthepsy/ssh-audit)
4-
**ssh-audit** is a tool for ssh server auditing.
2+
<!--
3+
[![travis build status](https://api.travis-ci.org/arthepsy/ssh-audit.svg?branch=develop)](https://travis-ci.org/arthepsy/ssh-audit)
4+
[![appveyor build status](https://ci.appveyor.com/api/projects/status/4m5r73m0r023edil/branch/develop?svg=true)](https://ci.appveyor.com/project/arthepsy/ssh-audit)
5+
[![codecov](https://codecov.io/gh/arthepsy/ssh-audit/branch/develop/graph/badge.svg)](https://codecov.io/gh/arthepsy/ssh-audit)
6+
[![Quality Gate](https://sonarqube.com/api/badges/gate?key=arthepsy-github%3Assh-audit%3Adevelop&template=ROUNDED)](https://sq.evolutiongaming.com/dashboard?id=arthepsy-github%3Assh-audit%3Adevelop)
7+
-->
8+
**ssh-audit** is a tool for ssh server & client configuration auditing.
59

610
## Features
711
- SSH1 and SSH2 protocol server support;
12+
- analyze SSH client configuration;
813
- grab banner, recognize device or software and operating system, detect compression;
914
- gather key-exchange, host-key, encryption and message authentication code algorithms;
1015
- output algorithm information (available since, removed/disabled, unsafe/weak/legacy, etc);
1116
- output algorithm recommendations (append or remove based on recognized software version);
1217
- output security information (related issues, assigned CVE list, etc);
1318
- analyze SSH version compatibility based on algorithm information;
1419
- historical information from OpenSSH, Dropbear SSH and libssh;
15-
- no dependencies, compatible with Python 2.6+, Python 3.x and PyPy;
20+
- no dependencies
1621

1722
## Usage
1823
```
19-
usage: ssh-audit.py [-1246pbnvl] <host>
24+
usage: ssh-audit.py [-1246pbcnvlt] <host>
2025
2126
-1, --ssh1 force ssh version 1 only
2227
-2, --ssh2 force ssh version 2 only
2328
-4, --ipv4 enable IPv4 (order of precedence)
2429
-6, --ipv6 enable IPv6 (order of precedence)
2530
-p, --port=<port> port to connect
2631
-b, --batch batch output
32+
-c, --client-audit starts a server on port 2222 to audit client
33+
software config (use -p to change port)
2734
-n, --no-colors disable colors
2835
-v, --verbose verbose output
2936
-l, --level=<level> minimum output level (info|warn|fail)
30-
37+
-t, --timeout=<secs> timeout (in seconds) for connection and reading
38+
(default: 5)
3139
```
3240
* if both IPv4 and IPv6 are used, order of precedence can be set by using either `-46` or `-64`.
3341
* batch flag `-b` will output sections without header and without empty lines (implies verbose flag).
3442
* verbose flag `-v` will prefix each line with section type and algorithm name.
3543

36-
### example
37-
![screenshot](https://cloud.githubusercontent.com/assets/7356025/19233757/3e09b168-8ef0-11e6-91b4-e880bacd0b8a.png)
44+
### Server Audit Example
45+
![screenshot](https://user-images.githubusercontent.com/2982011/64388792-317e6f80-d00e-11e9-826e-a4934769bb07.png)
46+
47+
### Client Audit Example
48+
TODO
3849

3950
## ChangeLog
51+
### v2.1.0 (???)
52+
- Added client software auditing functionality (see `-c` / `--client-audit` option).
53+
- Fixed crash while scanning Solaris Sun_SSH.
54+
- Added 9 new key exchanges: `gss-group1-sha1-toWM5Slw5Ew8Mqkay+al2g==`, `gss-gex-sha1-toWM5Slw5Ew8Mqkay+al2g==`, `gss-group14-sha1-`, `gss-group14-sha1-toWM5Slw5Ew8Mqkay+al2g==`, `gss-group14-sha256-toWM5Slw5Ew8Mqkay+al2g==`, `gss-group15-sha512-toWM5Slw5Ew8Mqkay+al2g==`, `diffie-hellman-group15-sha256`, `ecdh-sha2-1.3.132.0.10`, `curve448-sha512`.
55+
- Added 1 new host key type: `ecdsa-sha2-1.3.132.0.10`.
56+
- Added 4 new ciphers: `idea-cbc`, `serpent128-cbc`, `serpent192-cbc`, `serpent256-cbc`.
57+
58+
59+
### v2.0.0 (2019-08-29)
60+
- Forked from https://github.com/arthepsy/ssh-audit (development was stalled, and developer went MIA).
61+
- Added RSA host key length test.
62+
- Added RSA certificate key length test.
63+
- Added Diffie-Hellman modulus size test.
64+
- Now outputs host key fingerprints for RSA and ED25519.
65+
- Added 5 new key exchanges: `[email protected]`, `[email protected]`, `[email protected]`, `diffie-hellman-group16-sha256`, `diffie-hellman-group17-sha512`.
66+
- Added 3 new encryption algorithms: `des-cbc-ssh1`, `blowfish-ctr`, `twofish-ctr`.
67+
- Added 10 new MACs: `hmac-sha2-56`, `hmac-sha2-224`, `hmac-sha2-384`, `hmac-sha3-256`, `hmac-sha3-384`, `hmac-sha3-512`, `hmac-sha256`, `[email protected]`, `hmac-sha512`, `[email protected]`.
68+
- Added command line argument (-t / --timeout) for connection & reading timeouts.
69+
- Updated CVEs for libssh & Dropbear.
70+
4071
### v1.7.0 (2016-10-26)
4172
- implement options to allow specify IPv4/IPv6 usage and order of precedence
4273
- implement option to specify remote port (old behavior kept for compatibility)

0 commit comments

Comments
 (0)