Permalink
Browse files

Validate algorithm on assign

  • Loading branch information...
1 parent ba146ce commit 3dd139dc264da8dec74ed6375fe4b279554bd8a5 @cmouse cmouse committed Mar 31, 2015
Showing with 5 additions and 0 deletions.
  1. +5 −0 pdns/pdnssec.cc
View
@@ -1996,6 +1996,11 @@ try
}
int algorithm = shorthand2algorithm(cmds[3]);
+ if (algorithm<0) {
+ cerr << "Unable to use unknown algorithm '" << cmds[3] << "'" << std::endl;
+ return 1;
+ }
+
int id;
bool keyOrZone = (cmds[4] == "ksk" ? true : false);
string module = cmds[5];

0 comments on commit 3dd139d

Please sign in to comment.