DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD Security

OpenBSD Security Functionally paranoid!

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 7th August 2019
calanon calanon is offline
Port Guard
 
Join Date: Jul 2019
Posts: 38
Default Error in my pf syntax

I have added this rule but I keep getting a syntax error:

Code:
pass log proto tcp to self port ssh \
        (max-src-conn 8, max-src-conn-rate 15/5, \
               overload <bruteforce> flush global)
Reply With Quote
  #2   (View Single Post)  
Old 7th August 2019
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,983
Default

You need a state directive before the state options. Try adding "keep state" after "ssh" on line 1.
Reply With Quote
  #3   (View Single Post)  
Old 7th August 2019
calanon calanon is offline
Port Guard
 
Join Date: Jul 2019
Posts: 38
Default

Quote:
Originally Posted by jggimi View Post
You need a state directive before the state options. Try adding "keep state" after "ssh" on line 1.
Perfect it works!
Reply With Quote
  #4   (View Single Post)  
Old 7th August 2019
jggimi's Avatar
jggimi jggimi is offline
More noise than signal
 
Join Date: May 2008
Location: USA
Posts: 7,983
Default

There's a GRAMMAR section at the end of the pf.conf(5) manual. It's in BNF, so can be difficult to comprehend ... but sometimes I find it can be helpful when I get unexplained syntax errors.
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
[httpd] 'fastcgi param' syntax error jonsec OpenBSD General 22 6th August 2019 03:10 AM
ipsec.conf Syntax error Dr-D OpenBSD Security 8 14th November 2018 11:57 PM
Pf.conf:29 syntax error CyberJet OpenBSD Security 17 3rd May 2013 06:41 PM
Am I blind? syntax error: `(' unexpected guitarscn Programming 1 10th November 2010 08:53 PM
shc unistd.h:239: error: syntax error before '&' token laraaj OpenBSD General 3 11th September 2010 07:21 AM


All times are GMT. The time now is 06:23 AM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick