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

Parsing of "{ip} except;" in Junos ACLs doesn't seem to be functioning #26

Merged
merged 6 commits into from Jan 17, 2013

Conversation

Projects
None yet
1 participant
@jathanism
Member

jathanism commented Jan 17, 2013

Example:

   term spambad { 
        /* This term counts the number of established SMTP connections coming from */ 
        /* external sources */
        from { 
            source-address { 
                10.0.0.0/8 except; 
                10.8.0.0/16 except; 
                172.16.0.0/12 except; 
                192.168.0.0/16 except; 
                0.0.0.0/0; 
            } 
            destination-address { 
                172.128.1.1/32; 
            } 
            protocol tcp; 
            tcp-established; 
            source-port 25; 
            destination-port 1024-65535; 
        }
    }

Results in:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "trigger/acl/parser.py", line 2082, in parse
    success, children, nextchar = parser.parse(data)
  File "simpleparse/baseparser.py", line 30, in parse
    value = tag( data, self.buildTagger( production, processor), start, stop )
  File "simpleparse/objectgenerator.py", line 535, in __call__
    raise error
simpleparse.error.ParserSyntaxError: ParserSyntaxError: missing semicolon on line 59

@ghost ghost assigned jathanism Jun 15, 2012

jathanism added some commits Dec 4, 2012

Merge pull request #62 from mvh/except
Parser modifications to support negation of address in Junos ACLs.
- Matches.output_junos() now accounts for negated objects when displa…
…ying

- IP() now accounts for incoming negated objects
- MyIPy now accounts for negated objects in membership tests
Merge pull request #62 from mvh/except
Parser modifications to support negation of address in Junos ACLs.

Conflicts:
	trigger/acl/parser.py

jathanism added a commit that referenced this pull request Jan 17, 2013

Merge pull request #26 from jathanism/issue-62
Parsing of "{ip} except;" in Junos ACLs doesn't seem to be functioning

@jathanism jathanism merged commit 4dc6090 into trigger:develop Jan 17, 2013

@jathanism jathanism deleted the jathanism:issue-62 branch Jan 17, 2013

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment