eric7/Documentation/Source/eric7.Plugins.CheckerPlugins.CodeStyleChecker.Security.Checks.injectionSql.html

branch
eric7
changeset 8372
e0227a7c850e
child 8596
d64760b2da50
equal deleted inserted replaced
8371:d6062691d424 8372:e0227a7c850e
1 <!DOCTYPE html>
2 <html><head>
3 <title>eric7.Plugins.CheckerPlugins.CodeStyleChecker.Security.Checks.injectionSql</title>
4 <meta charset="UTF-8">
5 <style>
6 body {
7 background: #EDECE6;
8 margin: 0em 1em 10em 1em;
9 color: black;
10 }
11
12 h1 { color: white; background: #85774A; }
13 h2 { color: white; background: #85774A; }
14 h3 { color: white; background: #9D936E; }
15 h4 { color: white; background: #9D936E; }
16
17 a { color: #BA6D36; }
18
19 </style>
20 </head>
21 <body>
22 <a NAME="top" ID="top"></a>
23 <h1>eric7.Plugins.CheckerPlugins.CodeStyleChecker.Security.Checks.injectionSql</h1>
24
25 <p>
26 Module implementing a check for SQL injection.
27 </p>
28 <h3>Global Attributes</h3>
29
30 <table>
31 <tr><td>SIMPLE_SQL_RE</td></tr>
32 </table>
33 <h3>Classes</h3>
34
35 <table>
36 <tr><td>None</td></tr>
37 </table>
38 <h3>Functions</h3>
39
40 <table>
41
42 <tr>
43 <td><a href="#_checkString">_checkString</a></td>
44 <td>Function to check a given string against the list of search patterns.</td>
45 </tr>
46 <tr>
47 <td><a href="#_evaluateAst">_evaluateAst</a></td>
48 <td>Function to analyze the given ast node.</td>
49 </tr>
50 <tr>
51 <td><a href="#checkHardcodedSqlExpressions">checkHardcodedSqlExpressions</a></td>
52 <td>Function to check for SQL injection.</td>
53 </tr>
54 <tr>
55 <td><a href="#getChecks">getChecks</a></td>
56 <td>Public method to get a dictionary with checks handled by this module.</td>
57 </tr>
58 </table>
59 <hr />
60 <hr />
61 <a NAME="_checkString" ID="_checkString"></a>
62 <h2>_checkString</h2>
63 <b>_checkString</b>(<i>data</i>)
64
65 <p>
66 Function to check a given string against the list of search patterns.
67 </p>
68 <dl>
69
70 <dt><i>data</i> (str)</dt>
71 <dd>
72 string data to be checked
73 </dd>
74 </dl>
75 <dl>
76 <dt>Return:</dt>
77 <dd>
78 flag indicating a match
79 </dd>
80 </dl>
81 <dl>
82 <dt>Return Type:</dt>
83 <dd>
84 bool
85 </dd>
86 </dl>
87 <div align="right"><a href="#top">Up</a></div>
88 <hr />
89 <hr />
90 <a NAME="_evaluateAst" ID="_evaluateAst"></a>
91 <h2>_evaluateAst</h2>
92 <b>_evaluateAst</b>(<i>node</i>)
93
94 <p>
95 Function to analyze the given ast node.
96 </p>
97 <dl>
98
99 <dt><i>node</i> (ast.Str)</dt>
100 <dd>
101 ast node to be analyzed
102 </dd>
103 </dl>
104 <dl>
105 <dt>Return:</dt>
106 <dd>
107 tuple containing a flag indicating an execute call and
108 the resulting statement
109 </dd>
110 </dl>
111 <dl>
112 <dt>Return Type:</dt>
113 <dd>
114 tuple of (bool, str)
115 </dd>
116 </dl>
117 <div align="right"><a href="#top">Up</a></div>
118 <hr />
119 <hr />
120 <a NAME="checkHardcodedSqlExpressions" ID="checkHardcodedSqlExpressions"></a>
121 <h2>checkHardcodedSqlExpressions</h2>
122 <b>checkHardcodedSqlExpressions</b>(<i>reportError, context, config</i>)
123
124 <p>
125 Function to check for SQL injection.
126 </p>
127 <dl>
128
129 <dt><i>reportError</i> (func)</dt>
130 <dd>
131 function to be used to report errors
132 </dd>
133 <dt><i>context</i> (SecurityContext)</dt>
134 <dd>
135 security context object
136 </dd>
137 <dt><i>config</i> (dict)</dt>
138 <dd>
139 dictionary with configuration data
140 </dd>
141 </dl>
142 <div align="right"><a href="#top">Up</a></div>
143 <hr />
144 <hr />
145 <a NAME="getChecks" ID="getChecks"></a>
146 <h2>getChecks</h2>
147 <b>getChecks</b>(<i></i>)
148
149 <p>
150 Public method to get a dictionary with checks handled by this module.
151 </p>
152 <dl>
153 <dt>Return:</dt>
154 <dd>
155 dictionary containing checker lists containing checker function and
156 list of codes
157 </dd>
158 </dl>
159 <dl>
160 <dt>Return Type:</dt>
161 <dd>
162 dict
163 </dd>
164 </dl>
165 <div align="right"><a href="#top">Up</a></div>
166 <hr />
167 </body></html>

eric ide

mercurial