blob: 5913521cb38f1615a25a85d0b6c5d31df59d1bc3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
@banned@
identifier i;
position p1;
@@
\(strtok@i\|sprintf@i\|strcat@i\|strcpy@i\|strncpy@i\|strncat@i\|strndup@i\|strchrdup@i\)(...)@p1
@script:python@
p1 << banned.p1;
i << banned.i;
@@
print("Banned function '%s' used at %s:%s" % (i, p1[0].file, p1[0].line))
import sys
sys.exit(1)
|