Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
Warden Connectors
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
713
Warden
Warden Connectors
Commits
49b1af39
Commit
49b1af39
authored
7 years ago
by
Pavel Kácha
Browse files
Options
Downloads
Patches
Plain Diff
Fixed and extended ssh template and README (thx bartos@cesnet.cz)
parent
d3e7b324
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
fail2ban/README
+2
-1
2 additions, 1 deletion
fail2ban/README
fail2ban/f2ban_ssh.sh
+6
-4
6 additions, 4 deletions
fail2ban/f2ban_ssh.sh
with
8 additions
and
5 deletions
fail2ban/README
+
2
−
1
View file @
49b1af39
...
...
@@ -29,7 +29,8 @@ In the corresponding action following invocation can be used:
actionban = /usr/local/bin/f2ban_XXX.sh <ip> <failures> <time>
Please, edit corresponding paths and Warden names in the corresponding
script preamble.
script preamble and check/edit contents of the IDEA template (e.g. Target IP
address in f2ban_ssh.sh).
Scripts write generated Idea_ events into warden_filer compatible
directory, so you will need to run properly configured (and registered
...
...
This diff is collapsed.
Click to expand it.
fail2ban/f2ban_ssh.sh
+
6
−
4
View file @
49b1af39
...
...
@@ -31,9 +31,9 @@ cat >"$filer_dir/tmp/$event_id" <<EOF
"ID": "
$event_id
",
"DetectTime": "
$detect_time
",
"CreateTime": "
$create_time
",
"Category": ["A
busive.Spam
"],
"Category": ["A
ttempt.Login
"],
"Description": "SSH dictionary/bruteforce attack",
"Count":
$failures
,
"
Conn
Count":
$failures
,
"Note": "IP attempted
$failures
logins to SSH service",
"Source": [{
"IP4": ["
$src_ip
"],
...
...
@@ -41,8 +41,10 @@ cat >"$filer_dir/tmp/$event_id" <<EOF
}],
"Target": [{
"Type": ["Anonymised"],
"IP4": ["160.217.0.0/16"],
"Anonymised": true
"IP4": ["192.0.2.0/24"],
"Anonymised": true,
"Proto": ["tcp", "ssh"],
"Port": [22]
}],
"Node": [{
"Name": "
$node_name
",
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment