projects
/
freeradius.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1529aec
)
Only "string" can have "encrypt=2"
author
Alan T. DeKok
<aland@freeradius.org>
Wed, 19 Oct 2011 15:20:37 +0000
(17:20 +0200)
committer
Alan T. DeKok
<aland@freeradius.org>
Wed, 19 Oct 2011 15:31:29 +0000
(17:31 +0200)
src/lib/dict.c
patch
|
blob
|
history
diff --git
a/src/lib/dict.c
b/src/lib/dict.c
index
065adca
..
8ca426c
100644
(file)
--- a/
src/lib/dict.c
+++ b/
src/lib/dict.c
@@
-1284,6
+1284,13
@@
static int process_attribute(const char* fn, const int line,
fn, line, key);
return -1;
}
+
+ if ((flags.encrypt == FLAG_ENCRYPT_ASCEND_SECRET) &&
+ (type != PW_TYPE_STRING)) {
+ fr_strerror_printf( "dict_init: %s[%d] Only \"string\" types can have the \"encrypt=2\" flag set.",
+ fn, line);
+ return -1;
+ }
} else if (strncmp(key, "array", 6) == 0) {
flags.array = 1;