Netfilter-Devel Archive on lore.kernel.org
 help / color / Atom feed
From: Fernando Fernandez Mancera <ffmancera@riseup.net>
To: Pablo Neira Ayuso <pablo@netfilter.org>
Cc: netfilter-devel@vger.kernel.org
Subject: Re: [PATCH nft v2] src: add synproxy stateful object support
Date: Sun, 8 Sep 2019 20:37:38 +0200
Message-ID: <6c35d687-769c-a726-1bd5-9be4d8fe548d@riseup.net> (raw)
In-Reply-To: <20190907185532.odf3x26uuh5ctrza@salvia>

Hi Pablo,

On 9/7/19 8:55 PM, Pablo Neira Ayuso wrote:
> On Sat, Sep 07, 2019 at 08:30:22PM +0200, Fernando Fernandez Mancera wrote:
>> Add support for "synproxy" stateful object. For example (for TCP port 80 and
>> using maps with saddr):
>>
>> table ip foo {
>> 	synproxy https-synproxy {
>> 		synproxy mss 1460 wscale 7 timestamp sack-perm
>> 	}
> 
> Please, update syntax, so this looks like:
> 
>  	synproxy https-synproxy {
>  		mss 1460
>                 wscale 7
>                 timestamp sack-perm
>  	}
> 
> One option per line.
> 
> Thanks!
> 

I have updated the syntax.

    table ip foo {
            synproxy https-synproxy {
                    mss 1460
                    wscale 7
                    timestamp sack-perm
            }

            synproxy other-synproxy {
                    mss 1460
                    wscale 5
            }

            chain bar {
                    tcp dport 80 synproxy name "https-synproxy"
                    synproxy name ip saddr map { 192.168.1.0/24 :
"https-synproxy", 192.168.2.0/24 : "other-synproxy" }
            }
    }

But then I am getting errors when using "nft -f". Then how it is
possible to allow that on the parser?

mark:3:11-11: Error: syntax error, unexpected newline, expecting wscale
		mss 1460
		        ^
mark:4:3-8: Error: syntax error, unexpected wscale
		wscale 7
		^^^^^^
mark:5:3-11: Error: syntax error, unexpected timestamp
		timestamp sack-perm
		^^^^^^^^^
mark:9:11-11: Error: syntax error, unexpected newline, expecting wscale
		mss 1460
		        ^
mark:10:3-8: Error: syntax error, unexpected wscale
		wscale 5
		^^^^^^

Thanks! :-)

  reply index

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-09-07 18:30 Fernando Fernandez Mancera
2019-09-07 18:55 ` Pablo Neira Ayuso
2019-09-08 18:37   ` Fernando Fernandez Mancera [this message]
2019-09-08 19:33     ` Pablo Neira Ayuso

Reply instructions:

You may reply publically to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=6c35d687-769c-a726-1bd5-9be4d8fe548d@riseup.net \
    --to=ffmancera@riseup.net \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=pablo@netfilter.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

Netfilter-Devel Archive on lore.kernel.org

Archives are clonable:
	git clone --mirror https://lore.kernel.org/netfilter-devel/0 netfilter-devel/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 netfilter-devel netfilter-devel/ https://lore.kernel.org/netfilter-devel \
		netfilter-devel@vger.kernel.org
	public-inbox-index netfilter-devel

Example config snippet for mirrors

Newsgroup available over NNTP:
	nntp://nntp.lore.kernel.org/org.kernel.vger.netfilter-devel


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git