-
Notifications
You must be signed in to change notification settings - Fork 1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improved vsftpd decoder #654
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
OUTPUT Sun Aug 16 15:47:34 2015 [pid 4864] CONNECT: Client "172.28.5.129" Sun Aug 16 15:47:36 2015 [pid 4863] [ftpuser] FAIL LOGIN: Client "172.28.5.129" Sun Aug 16 15:47:49 2015 [pid 4868] CONNECT: Client "172.28.5.129" Sun Aug 16 15:47:50 2015 [pid 4867] [ftpuser] OK LOGIN: Client "172.28.5.129" Sun Aug 16 15:47:50 2015 [pid 4872] [ftpuser] OK UPLOAD: Client "172.28.5.129", "/index.php", 8099 bytes, 1176.26Kbyte/sec Sun Aug 16 15:48:02 2015 [pid 4832] [ftpuser] OK DELETE: Client "172.28.5.129", "/index.php" Sun Aug 16 16:26:06 2015 [pid 4976] [ftpuser] OK CHMOD: Client "172.28.5.129", "/index.php 777" Sun Aug 16 16:26:21 2015 [pid 4976] [ftpuser] OK RENAME: Client "172.28.5.129", "/index.php /4444index.php" **Phase 1: Completed pre-decoding. full event: 'Sun Aug 16 15:47:34 2015 [pid 4864] CONNECT: Client "172.28.5.129"' hostname: 'ossec-server' program_name: '(null)' log: 'Sun Aug 16 15:47:34 2015 [pid 4864] CONNECT: Client "172.28.5.129"' **Phase 2: Completed decoding. decoder: 'vsftpd' action: 'CONNECT' srcip: '172.28.5.129' **Phase 3: Completed filtering (rules). Rule id: '11401' Level: '3' Description: 'FTP session opened.' **Alert to be generated. **Phase 1: Completed pre-decoding. full event: 'Sun Aug 16 15:47:36 2015 [pid 4863] [ftpuser] FAIL LOGIN: Client "172.28.5.129"' hostname: 'ossec-server' program_name: '(null)' log: 'Sun Aug 16 15:47:36 2015 [pid 4863] [ftpuser] FAIL LOGIN: Client "172.28.5.129"' **Phase 2: Completed decoding. decoder: 'vsftpd' dstuser: 'ftpuser' status: 'FAIL LOGIN' srcip: '172.28.5.129' **Phase 3: Completed filtering (rules). Rule id: '11403' Level: '5' Description: 'Login failed accessing the FTP server.' **Alert to be generated. **Phase 1: Completed pre-decoding. full event: 'Sun Aug 16 15:47:49 2015 [pid 4868] CONNECT: Client "172.28.5.129"' hostname: 'ossec-server' program_name: '(null)' log: 'Sun Aug 16 15:47:49 2015 [pid 4868] CONNECT: Client "172.28.5.129"' **Phase 2: Completed decoding. decoder: 'vsftpd' action: 'CONNECT' srcip: '172.28.5.129' **Phase 3: Completed filtering (rules). Rule id: '11401' Level: '3' Description: 'FTP session opened.' **Alert to be generated. **Phase 1: Completed pre-decoding. full event: 'Sun Aug 16 15:47:50 2015 [pid 4867] [ftpuser] OK LOGIN: Client "172.28.5.129"' hostname: 'ossec-server' program_name: '(null)' log: 'Sun Aug 16 15:47:50 2015 [pid 4867] [ftpuser] OK LOGIN: Client "172.28.5.129"' **Phase 2: Completed decoding. decoder: 'vsftpd' dstuser: 'ftpuser' status: 'OK LOGIN' srcip: '172.28.5.129' **Phase 3: Completed filtering (rules). Rule id: '11402' Level: '3' Description: 'FTP Authentication success.' **Alert to be generated. **Phase 1: Completed pre-decoding. full event: 'Sun Aug 16 15:47:50 2015 [pid 4872] [ftpuser] OK UPLOAD: Client "172.28.5.129", "/index.php", 8099 bytes, 1176.26Kbyte/sec' hostname: 'ossec-server' program_name: '(null)' log: 'Sun Aug 16 15:47:50 2015 [pid 4872] [ftpuser] OK UPLOAD: Client "172.28.5.129", "/index.php", 8099 bytes, 1176.26Kbyte/sec' **Phase 2: Completed decoding. decoder: 'vsftpd' dstuser: 'ftpuser' status: 'OK UPLOAD' srcip: '172.28.5.129' url: '/index.php' **Phase 3: Completed filtering (rules). Rule id: '11404' Level: '0' Description: 'FTP server file upload.' **Phase 1: Completed pre-decoding. full event: 'Sun Aug 16 15:48:02 2015 [pid 4832] [ftpuser] OK DELETE: Client "172.28.5.129", "/index.php"' hostname: 'ossec-server' program_name: '(null)' log: 'Sun Aug 16 15:48:02 2015 [pid 4832] [ftpuser] OK DELETE: Client "172.28.5.129", "/index.php"' **Phase 2: Completed decoding. decoder: 'vsftpd' dstuser: 'ftpuser' status: 'OK DELETE' srcip: '172.28.5.129' url: '/index.php"' **Phase 1: Completed pre-decoding. full event: 'Sun Aug 16 16:26:06 2015 [pid 4976] [ftpuser] OK CHMOD: Client "172.28.5.129", "/index.php 777"' hostname: 'ossec-server' program_name: '(null)' log: 'Sun Aug 16 16:26:06 2015 [pid 4976] [ftpuser] OK CHMOD: Client "172.28.5.129", "/index.php 777"' **Phase 2: Completed decoding. decoder: 'vsftpd' dstuser: 'ftpuser' status: 'OK CHMOD' srcip: '172.28.5.129' url: '/index.php 777"' **Phase 1: Completed pre-decoding. full event: 'Sun Aug 16 16:26:21 2015 [pid 4976] [ftpuser] OK RENAME: Client "172.28.5.129", "/index.php /4444index.php"' hostname: 'ossec-server' program_name: '(null)' log: 'Sun Aug 16 16:26:21 2015 [pid 4976] [ftpuser] OK RENAME: Client "172.28.5.129", "/index.php /4444index.php"' **Phase 2: Completed decoding. decoder: 'vsftpd' dstuser: 'ftpuser' status: 'OK RENAME' srcip: '172.28.5.129' url: '/index.php /4444index.php"'
Awesome! Can you add tests to src/contrib/ossec-testing/tests for these log messages? |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
OUTPUT
Sun Aug 16 15:47:34 2015 [pid 4864] CONNECT: Client "172.28.5.129"
Sun Aug 16 15:47:36 2015 [pid 4863] [ftpuser] FAIL LOGIN: Client "172.28.5.129"
Sun Aug 16 15:47:49 2015 [pid 4868] CONNECT: Client "172.28.5.129"
Sun Aug 16 15:47:50 2015 [pid 4867] [ftpuser] OK LOGIN: Client "172.28.5.129"
Sun Aug 16 15:47:50 2015 [pid 4872] [ftpuser] OK UPLOAD: Client "172.28.5.129", "/index.php", 8099 bytes, 1176.26Kbyte/sec
Sun Aug 16 15:48:02 2015 [pid 4832] [ftpuser] OK DELETE: Client "172.28.5.129", "/index.php"
Sun Aug 16 16:26:06 2015 [pid 4976] [ftpuser] OK CHMOD: Client "172.28.5.129", "/index.php 777"
Sun Aug 16 16:26:21 2015 [pid 4976] [ftpuser] OK RENAME: Client "172.28.5.129", "/index.php /4444index.php"
**Phase 1: Completed pre-decoding.
full event: 'Sun Aug 16 15:47:34 2015 [pid 4864] CONNECT: Client "172.28.5.129"'
hostname: 'ossec-server'
program_name: '(null)'
log: 'Sun Aug 16 15:47:34 2015 [pid 4864] CONNECT: Client "172.28.5.129"'
**Phase 2: Completed decoding.
decoder: 'vsftpd'
action: 'CONNECT'
srcip: '172.28.5.129'
*_Phase 3: Completed filtering (rules).
Rule id: '11401'
Level: '3'
Description: 'FTP session opened.'
*_Alert to be generated.
**Phase 1: Completed pre-decoding.
full event: 'Sun Aug 16 15:47:36 2015 [pid 4863] [ftpuser] FAIL LOGIN: Client "172.28.5.129"'
hostname: 'ossec-server'
program_name: '(null)'
log: 'Sun Aug 16 15:47:36 2015 [pid 4863] [ftpuser] FAIL LOGIN: Client "172.28.5.129"'
**Phase 2: Completed decoding.
decoder: 'vsftpd'
dstuser: 'ftpuser'
status: 'FAIL LOGIN'
srcip: '172.28.5.129'
*_Phase 3: Completed filtering (rules).
Rule id: '11403'
Level: '5'
Description: 'Login failed accessing the FTP server.'
*_Alert to be generated.
**Phase 1: Completed pre-decoding.
full event: 'Sun Aug 16 15:47:49 2015 [pid 4868] CONNECT: Client "172.28.5.129"'
hostname: 'ossec-server'
program_name: '(null)'
log: 'Sun Aug 16 15:47:49 2015 [pid 4868] CONNECT: Client "172.28.5.129"'
**Phase 2: Completed decoding.
decoder: 'vsftpd'
action: 'CONNECT'
srcip: '172.28.5.129'
*_Phase 3: Completed filtering (rules).
Rule id: '11401'
Level: '3'
Description: 'FTP session opened.'
*_Alert to be generated.
**Phase 1: Completed pre-decoding.
full event: 'Sun Aug 16 15:47:50 2015 [pid 4867] [ftpuser] OK LOGIN: Client "172.28.5.129"'
hostname: 'ossec-server'
program_name: '(null)'
log: 'Sun Aug 16 15:47:50 2015 [pid 4867] [ftpuser] OK LOGIN: Client "172.28.5.129"'
**Phase 2: Completed decoding.
decoder: 'vsftpd'
dstuser: 'ftpuser'
status: 'OK LOGIN'
srcip: '172.28.5.129'
*_Phase 3: Completed filtering (rules).
Rule id: '11402'
Level: '3'
Description: 'FTP Authentication success.'
*_Alert to be generated.
**Phase 1: Completed pre-decoding.
full event: 'Sun Aug 16 15:47:50 2015 [pid 4872] [ftpuser] OK UPLOAD: Client "172.28.5.129", "/index.php", 8099 bytes, 1176.26Kbyte/sec'
hostname: 'ossec-server'
program_name: '(null)'
log: 'Sun Aug 16 15:47:50 2015 [pid 4872] [ftpuser] OK UPLOAD: Client "172.28.5.129", "/index.php", 8099 bytes, 1176.26Kbyte/sec'
**Phase 2: Completed decoding.
decoder: 'vsftpd'
dstuser: 'ftpuser'
status: 'OK UPLOAD'
srcip: '172.28.5.129'
url: '/index.php'
**Phase 3: Completed filtering (rules).
Rule id: '11404'
Level: '0'
Description: 'FTP server file upload.'
**Phase 1: Completed pre-decoding.
full event: 'Sun Aug 16 15:48:02 2015 [pid 4832] [ftpuser] OK DELETE: Client "172.28.5.129", "/index.php"'
hostname: 'ossec-server'
program_name: '(null)'
log: 'Sun Aug 16 15:48:02 2015 [pid 4832] [ftpuser] OK DELETE: Client "172.28.5.129", "/index.php"'
**Phase 2: Completed decoding.
decoder: 'vsftpd'
dstuser: 'ftpuser'
status: 'OK DELETE'
srcip: '172.28.5.129'
url: '/index.php"'
**Phase 1: Completed pre-decoding.
full event: 'Sun Aug 16 16:26:06 2015 [pid 4976] [ftpuser] OK CHMOD: Client "172.28.5.129", "/index.php 777"'
hostname: 'ossec-server'
program_name: '(null)'
log: 'Sun Aug 16 16:26:06 2015 [pid 4976] [ftpuser] OK CHMOD: Client "172.28.5.129", "/index.php 777"'
**Phase 2: Completed decoding.
decoder: 'vsftpd'
dstuser: 'ftpuser'
status: 'OK CHMOD'
srcip: '172.28.5.129'
url: '/index.php 777"'
**Phase 1: Completed pre-decoding.
full event: 'Sun Aug 16 16:26:21 2015 [pid 4976] [ftpuser] OK RENAME: Client "172.28.5.129", "/index.php /4444index.php"'
hostname: 'ossec-server'
program_name: '(null)'
log: 'Sun Aug 16 16:26:21 2015 [pid 4976] [ftpuser] OK RENAME: Client "172.28.5.129", "/index.php /4444index.php"'
**Phase 2: Completed decoding.
decoder: 'vsftpd'
dstuser: 'ftpuser'
status: 'OK RENAME'
srcip: '172.28.5.129'
url: '/index.php /4444index.php"'