Skip to content
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

[zone parser] disallow nested $GENERATE directive #1033

Merged
merged 1 commit into from Oct 23, 2019

Conversation

chantra
Copy link
Contributor

@chantra chantra commented Oct 23, 2019

While the range number of GENERATE is now limited, one can pass
a line with 2 $GENERATE directive that will exponentially increase the
time spent generating RRs.
Limit to only one per line.
Fixes #1020

@chantra
Copy link
Contributor Author

@chantra chantra commented Oct 23, 2019

fixing test.... had the line number wrong.

@codecov-io
Copy link

@codecov-io codecov-io commented Oct 23, 2019

Codecov Report

Merging #1033 into master will increase coverage by 0.01%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1033      +/-   ##
==========================================
+ Coverage   54.91%   54.92%   +0.01%     
==========================================
  Files          41       41              
  Lines        9866     9869       +3     
==========================================
+ Hits         5418     5421       +3     
  Misses       3425     3425              
  Partials     1023     1023
Impacted Files Coverage Δ
generate.go 79.36% <100%> (+0.16%) ⬆️
scan.go 82.83% <100%> (+0.04%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4d4363a...e9aa97b. Read the comment docs.

generate.go Outdated Show resolved Hide resolved
scan.go Outdated Show resolved Hide resolved
While the range number of GENERATE is now limited, one can pass
a line with 2 $GENERATE directive that will exponentially increase the
time spent generating RRs.
Limit to only one per line.
Fixes miekg#1020
Copy link
Collaborator

@tmthrgd tmthrgd left a comment

LGTM. This is exactly what I meant. It's up to @miekg to decide if the behaviour change is desired.

@miekg
Copy link
Owner

@miekg miekg commented Oct 23, 2019

@tmthrgd
Copy link
Collaborator

@tmthrgd tmthrgd commented Oct 23, 2019

@miekg Just that previously $GENERATE in $GENERATE was allowed (though I can't imagine anyone using it) and now it's disallowed.

@miekg
Copy link
Owner

@miekg miekg commented Oct 23, 2019

@miekg miekg merged commit 9b7437f into miekg:master Oct 23, 2019
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants