~ubuntu-branches/ubuntu/raring/nginx/raring

« back to all changes in this revision

Viewing changes to debian/modules/naxsi/t/09sqlmap_tamper.t

  • Committer: Package Import Robot
  • Author(s): Kartik Mistry, Michael Lustfield, Kartik Mistry
  • Date: 2012-10-30 10:10:34 UTC
  • mfrom: (4.2.54 sid)
  • Revision ID: package-import@ubuntu.com-20121030101034-fovn0siwczi3jian
Tags: 1.2.4-1
[ Michael Lustfield ]
* debian/nginx-common.nginx.init
  + Added --retry to start-stop-daemon. (Closes: #682360)
  + Added $named to Required-Start/Stop. (Closes: #679879)
  + Added some other modifications after testing. (LP: #1033856)
* debian/rules:
  + Added -DFORTIFY_SOURCE=2 -fstack-protector to build flags.
    (Closes: #680712)
* debian/nginx-common.install:
  + Moved default docs to /usr/share/nginx/html. (Closes: #1031515)
* debian/rules:
  + Set prefix to /usr/share/nginx.
* debian/po/fr.po
  + Updated French translation file. (Closes: #679601)
* debian/logrotate:
  + Removed semicolon after an fi statement. (Closes: #683870)
* debian/copyright:
  + Removed trailing slash from File: fields.
* Changed /var/run to /run in multiple files. (LP: #1050516)
* debian/nginx-common.dirs:
  + Added /run to .dirs to avoid conflicts with backports. (LP: #1072641)
* debian/nginx-*.postinst:
  + Added sites-enabled/available directory checks. (Closes: #688410)
    - Thanks Andreas Marschke <andreas.marschke@gmail.com>
  + Moved the symlink creation to nginx-common.
* Updated debconf templates.
* conf/sites-available/default:
  + Updated root to point at /usr/share/nginx/html instead of www.

[ Kartik Mistry ]
* Acknowledged NMUs (Closes: #681758, #681381)
* New upstream release (Closes: #683704)
* debian/po/*.po:
  + Removed ^M characters from headers.
  + Fixed all files with recent unneeded template change.

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
use lib 'lib';
 
3
use Test::Nginx::Socket;
 
4
 
 
5
plan tests => repeat_each(2) * blocks();
 
6
no_root_location();
 
7
no_long_string();
 
8
$ENV{TEST_NGINX_SERVROOT} = server_root();
 
9
run_tests();
 
10
 
 
11
 
 
12
__DATA__
 
13
=== TODO: naxsi does not support utf8, potential bypass. Still too marginal to be worth checking
 
14
--- main_config
 
15
working_directory /tmp/;
 
16
worker_rlimit_core 25M;
 
17
--- http_config
 
18
include /etc/nginx/naxsi_core.rules;
 
19
--- config
 
20
 location / {
 
21
         #LearningMode;
 
22
         SecRulesEnabled;
 
23
         DeniedUrl "/RequestDenied";
 
24
        CheckRule "$SQL >= 8" BLOCK;
 
25
        CheckRule "$RFI >= 8" BLOCK;
 
26
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
27
        CheckRule "$XSS >= 8" BLOCK;
 
28
         root $TEST_NGINX_SERVROOT/html/;
 
29
         index index.html index.htm;
 
30
}
 
31
location /RequestDenied {
 
32
         return 412;
 
33
}
 
34
--- raw_request eval
 
35
"GET /?a=AND+%EF%BC%871%EF%BC%87=%EF%BC%871%EF%BC%87 HTTP/1.0
 
36
 
 
37
"
 
38
--- error_code: 200
 
39
 
 
40
 
 
41
=== TEST 1: hey 2
 
42
--- main_config
 
43
working_directory /tmp/;
 
44
worker_rlimit_core 25M;
 
45
--- http_config
 
46
include /etc/nginx/naxsi_core.rules;
 
47
--- config
 
48
location / {
 
49
         #LearningMode;
 
50
         SecRulesEnabled;
 
51
         DeniedUrl "/RequestDenied";
 
52
        CheckRule "$SQL >= 8" BLOCK;
 
53
        CheckRule "$RFI >= 8" BLOCK;
 
54
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
55
        CheckRule "$XSS >= 8" BLOCK;
 
56
         root $TEST_NGINX_SERVROOT/html/;
 
57
         index index.html index.htm;
 
58
}
 
59
location /RequestDenied {
 
60
         return 412;
 
61
}
 
62
--- raw_request eval
 
63
"GET /?a=AND+%00%271%00%27=%00%271%00%27 HTTP/1.0
 
64
 
 
65
"
 
66
--- error_code: 412
 
67
 
 
68
 
 
69
=== TEST 1: hey 3
 
70
--- main_config
 
71
working_directory /tmp/;
 
72
worker_rlimit_core 25M;
 
73
--- http_config
 
74
include /etc/nginx/naxsi_core.rules;
 
75
--- config
 
76
location / {
 
77
         #LearningMode;
 
78
         SecRulesEnabled;
 
79
         DeniedUrl "/RequestDenied";
 
80
        CheckRule "$SQL >= 8" BLOCK;
 
81
        CheckRule "$RFI >= 8" BLOCK;
 
82
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
83
        CheckRule "$XSS >= 8" BLOCK;
 
84
         root $TEST_NGINX_SERVROOT/html/;
 
85
         index index.html index.htm;
 
86
}
 
87
location /RequestDenied {
 
88
         return 412;
 
89
}
 
90
--- raw_request eval
 
91
"GET /?a=AND+1=1%00 Union select 1 HTTP/1.0
 
92
 
 
93
"
 
94
--- error_code: 412
 
95
 
 
96
 
 
97
=== NOT TODO: base64, not worthing checking
 
98
--- main_config
 
99
working_directory /tmp/;
 
100
worker_rlimit_core 25M;
 
101
--- http_config
 
102
include /etc/nginx/naxsi_core.rules;
 
103
--- config
 
104
location / {
 
105
         #LearningMode;
 
106
         SecRulesEnabled;
 
107
         DeniedUrl "/RequestDenied";
 
108
        CheckRule "$SQL >= 8" BLOCK;
 
109
        CheckRule "$RFI >= 8" BLOCK;
 
110
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
111
        CheckRule "$XSS >= 8" BLOCK;
 
112
         root $TEST_NGINX_SERVROOT/html/;
 
113
         index index.html index.htm;
 
114
}
 
115
location /RequestDenied {
 
116
         return 412;
 
117
}
 
118
--- raw_request eval
 
119
"GET /?a=MScgQU5EIFNMRUVQKDUpIw== HTTP/1.0
 
120
 
 
121
"
 
122
--- error_code: 200
 
123
 
 
124
 
 
125
=== TEST 1: hey 5
 
126
--- main_config
 
127
working_directory /tmp/;
 
128
worker_rlimit_core 25M;
 
129
--- http_config
 
130
include /etc/nginx/naxsi_core.rules;
 
131
--- config
 
132
location / {
 
133
         #LearningMode;
 
134
         SecRulesEnabled;
 
135
         DeniedUrl "/RequestDenied";
 
136
        CheckRule "$SQL >= 8" BLOCK;
 
137
        CheckRule "$RFI >= 8" BLOCK;
 
138
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
139
        CheckRule "$XSS >= 8" BLOCK;
 
140
         root $TEST_NGINX_SERVROOT/html/;
 
141
         index index.html index.htm;
 
142
}
 
143
location /RequestDenied {
 
144
         return 412;
 
145
}
 
146
--- raw_request eval
 
147
"GET /?a='A+NOT+BETWEEN+0+AND+B' HTTP/1.0
 
148
 
 
149
"
 
150
--- error_code: 412
 
151
 
 
152
 
 
153
=== TEST 1: hey 6
 
154
--- main_config
 
155
working_directory /tmp/;
 
156
worker_rlimit_core 25M;
 
157
--- http_config
 
158
include /etc/nginx/naxsi_core.rules;
 
159
--- config
 
160
location / {
 
161
         #LearningMode;
 
162
         SecRulesEnabled;
 
163
         DeniedUrl "/RequestDenied";
 
164
        CheckRule "$SQL >= 8" BLOCK;
 
165
        CheckRule "$RFI >= 8" BLOCK;
 
166
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
167
        CheckRule "$XSS >= 8" BLOCK;
 
168
         root $TEST_NGINX_SERVROOT/html/;
 
169
         index index.html index.htm;
 
170
}
 
171
location /RequestDenied {
 
172
         return 412;
 
173
}
 
174
--- raw_request eval
 
175
"GET /?a=%2553%2545%254c%2545%2543%2554%2520%2546%2549%2545%254c%2544%2520%2546%2552%254f%254d%2520%2554%2541%2542%254c%2545 HTTP/1.0
 
176
 
 
177
"
 
178
--- error_code: 412
 
179
 
 
180
 
 
181
=== TEST 1: hey 7
 
182
--- main_config
 
183
working_directory /tmp/;
 
184
worker_rlimit_core 25M;
 
185
--- http_config
 
186
include /etc/nginx/naxsi_core.rules;
 
187
--- config
 
188
location / {
 
189
         #LearningMode;
 
190
         SecRulesEnabled;
 
191
         DeniedUrl "/RequestDenied";
 
192
        CheckRule "$SQL >= 8" BLOCK;
 
193
        CheckRule "$RFI >= 8" BLOCK;
 
194
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
195
        CheckRule "$XSS >= 8" BLOCK;
 
196
         root $TEST_NGINX_SERVROOT/html/;
 
197
         index index.html index.htm;
 
198
}
 
199
location /RequestDenied {
 
200
         return 412;
 
201
}
 
202
--- raw_request eval
 
203
"GET /?a=%53%45%4c%45%43%54%20%46%49%45%4c%44%20%46%52%4f%4d%20%54%41%42%4c%45 HTTP/1.0
 
204
 
 
205
"
 
206
--- error_code: 412
 
207
 
 
208
 
 
209
=== TEST 1: hey 8
 
210
--- main_config
 
211
working_directory /tmp/;
 
212
worker_rlimit_core 25M;
 
213
--- http_config
 
214
include /etc/nginx/naxsi_core.rules;
 
215
--- config
 
216
location / {
 
217
         #LearningMode;
 
218
         SecRulesEnabled;
 
219
         DeniedUrl "/RequestDenied";
 
220
        CheckRule "$SQL >= 8" BLOCK;
 
221
        CheckRule "$RFI >= 8" BLOCK;
 
222
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
223
        CheckRule "$XSS >= 8" BLOCK;
 
224
         root $TEST_NGINX_SERVROOT/html/;
 
225
         index index.html index.htm;
 
226
}
 
227
location /RequestDenied {
 
228
         return 412;
 
229
}
 
230
--- raw_request eval
 
231
"GET /?a=%u0053%u0045%u004c%u0045%u0043%u0054%u0020%u0046%u0049%u0045%u004c%u0044%u0020%u0046%u0052%u004f%u004d%u0020%u0054%u0041%u0042%u004c%u0045' HTTP/1.0
 
232
 
 
233
"
 
234
--- error_code: 412
 
235
 
 
236
 
 
237
=== TEST 1: hey 9
 
238
--- main_config
 
239
working_directory /tmp/;
 
240
worker_rlimit_core 25M;
 
241
--- http_config
 
242
include /etc/nginx/naxsi_core.rules;
 
243
--- config
 
244
location / {
 
245
         #LearningMode;
 
246
         SecRulesEnabled;
 
247
         DeniedUrl "/RequestDenied";
 
248
        CheckRule "$SQL >= 8" BLOCK;
 
249
        CheckRule "$RFI >= 8" BLOCK;
 
250
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
251
        CheckRule "$XSS >= 8" BLOCK;
 
252
         root $TEST_NGINX_SERVROOT/html/;
 
253
         index index.html index.htm;
 
254
}
 
255
location /RequestDenied {
 
256
         return 412;
 
257
}
 
258
--- raw_request eval
 
259
"GET /?a=SELECT+*+FROM+users+WHERE+id+LIKE+1 HTTP/1.0
 
260
 
 
261
"
 
262
--- error_code: 412
 
263
 
 
264
 
 
265
=== TEST 1: hey 10
 
266
--- main_config
 
267
working_directory /tmp/;
 
268
worker_rlimit_core 25M;
 
269
--- http_config
 
270
include /etc/nginx/naxsi_core.rules;
 
271
--- config
 
272
 location / {
 
273
         #LearningMode;
 
274
         SecRulesEnabled;
 
275
         DeniedUrl "/RequestDenied";
 
276
        CheckRule "$SQL >= 8" BLOCK;
 
277
        CheckRule "$RFI >= 8" BLOCK;
 
278
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
279
        CheckRule "$XSS >= 8" BLOCK;
 
280
         root $TEST_NGINX_SERVROOT/html/;
 
281
         index index.html index.htm;
 
282
}
 
283
location /RequestDenied {
 
284
         return 412;
 
285
}
 
286
--- raw_request eval
 
287
"GET /?a=value'/*!0UNION/*!0ALL/*!0SELECT/*!0CONCAT(/*!0CHAR(58,107,112,113,58),/*!0IFNULL(CAST(/*!0CURRENT_USER()/*!0AS/*!0CHAR),/*!0CHAR(32)),/*!0CHAR(58,97,110,121,58)),+NULL,+NULL#/*!0AND+'QDWa'='QDWa HTTP/1.0
 
288
 
 
289
"
 
290
--- error_code: 412
 
291
 
 
292
 
 
293
=== TEST 1: hey 11
 
294
--- main_config
 
295
working_directory /tmp/;
 
296
worker_rlimit_core 25M;
 
297
--- http_config
 
298
include /etc/nginx/naxsi_core.rules;
 
299
--- config
 
300
location / {
 
301
         #LearningMode;
 
302
         SecRulesEnabled;
 
303
         DeniedUrl "/RequestDenied";
 
304
        CheckRule "$SQL >= 8" BLOCK;
 
305
        CheckRule "$RFI >= 8" BLOCK;
 
306
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
307
        CheckRule "$XSS >= 8" BLOCK;
 
308
         root $TEST_NGINX_SERVROOT/html/;
 
309
         index index.html index.htm;
 
310
}
 
311
location /RequestDenied {
 
312
         return 412;
 
313
}
 
314
--- raw_request eval
 
315
"GET /?a=IF(ISNULL(1),+2,+1) HTTP/1.0
 
316
 
 
317
"
 
318
--- error_code: 412
 
319
 
 
320
 
 
321
=== TEST 1: hey 12
 
322
--- main_config
 
323
working_directory /tmp/;
 
324
worker_rlimit_core 25M;
 
325
--- http_config
 
326
include /etc/nginx/naxsi_core.rules;
 
327
--- config
 
328
location / {
 
329
         #LearningMode;
 
330
         SecRulesEnabled;
 
331
         DeniedUrl "/RequestDenied";
 
332
        CheckRule "$SQL >= 8" BLOCK;
 
333
        CheckRule "$RFI >= 8" BLOCK;
 
334
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
335
        CheckRule "$XSS >= 8" BLOCK;
 
336
         root $TEST_NGINX_SERVROOT/html/;
 
337
         index index.html index.htm;
 
338
}
 
339
location /RequestDenied {
 
340
         return 412;
 
341
}
 
342
--- raw_request eval
 
343
"GET /?a=1+/*!30000AND+2>1*/-- HTTP/1.0
 
344
 
 
345
"
 
346
--- error_code: 412
 
347
 
 
348
 
 
349
=== TEST 1: hey 13
 
350
--- main_config
 
351
working_directory /tmp/;
 
352
worker_rlimit_core 25M;
 
353
--- http_config
 
354
include /etc/nginx/naxsi_core.rules;
 
355
--- config
 
356
location / {
 
357
         #LearningMode;
 
358
         SecRulesEnabled;
 
359
         DeniedUrl "/RequestDenied";
 
360
        CheckRule "$SQL >= 8" BLOCK;
 
361
        CheckRule "$RFI >= 8" BLOCK;
 
362
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
363
        CheckRule "$XSS >= 8" BLOCK;
 
364
         root $TEST_NGINX_SERVROOT/html/;
 
365
         index index.html index.htm;
 
366
}
 
367
location /RequestDenied {
 
368
         return 412;
 
369
}
 
370
--- raw_request eval
 
371
"GET /?a=1+/*!00000AND+2>1*/-- HTTP/1.0
 
372
 
 
373
"
 
374
--- error_code: 412
 
375
 
 
376
 
 
377
=== TEST 1: hey 14
 
378
--- main_config
 
379
working_directory /tmp/;
 
380
worker_rlimit_core 25M;
 
381
--- http_config
 
382
include /etc/nginx/naxsi_core.rules;
 
383
--- config
 
384
location / {
 
385
         #LearningMode;
 
386
         SecRulesEnabled;
 
387
         DeniedUrl "/RequestDenied";
 
388
        CheckRule "$SQL >= 8" BLOCK;
 
389
        CheckRule "$RFI >= 8" BLOCK;
 
390
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
391
        CheckRule "$XSS >= 8" BLOCK;
 
392
         root $TEST_NGINX_SERVROOT/html/;
 
393
         index index.html index.htm;
 
394
}
 
395
location /RequestDenied {
 
396
         return 412;
 
397
}
 
398
--- raw_request eval
 
399
"GET /?a=+UNION+++SELECT++ HTTP/1.0
 
400
 
 
401
"
 
402
--- error_code: 412
 
403
 
 
404
 
 
405
=== NOT TODO: I don't know any server/interpreter decoding this ?
 
406
--- main_config
 
407
working_directory /tmp/;
 
408
worker_rlimit_core 25M;
 
409
--- http_config
 
410
include /etc/nginx/naxsi_core.rules;
 
411
--- config
 
412
location / {
 
413
         #LearningMode;
 
414
         SecRulesEnabled;
 
415
         DeniedUrl "/RequestDenied";
 
416
        CheckRule "$SQL >= 8" BLOCK;
 
417
        CheckRule "$RFI >= 8" BLOCK;
 
418
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
419
        CheckRule "$XSS >= 8" BLOCK;
 
420
         root $TEST_NGINX_SERVROOT/html/;
 
421
         index index.html index.htm;
 
422
}
 
423
location /RequestDenied {
 
424
         return 412;
 
425
}
 
426
--- raw_request eval
 
427
"GET /?a=%S%E%L%E%C%T+%F%I%E%L%D+%F%R%O%M+%T%A%B%L%E HTTP/1.0
 
428
 
 
429
"
 
430
--- error_code: 200
 
431
 
 
432
 
 
433
=== TEST 1: hey 16
 
434
--- main_config
 
435
working_directory /tmp/;
 
436
worker_rlimit_core 25M;
 
437
--- http_config
 
438
include /etc/nginx/naxsi_core.rules;
 
439
--- config
 
440
location / {
 
441
         #LearningMode;
 
442
         SecRulesEnabled;
 
443
         DeniedUrl "/RequestDenied";
 
444
        CheckRule "$SQL >= 8" BLOCK;
 
445
        CheckRule "$RFI >= 8" BLOCK;
 
446
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
447
        CheckRule "$XSS >= 8" BLOCK;
 
448
         root $TEST_NGINX_SERVROOT/html/;
 
449
         index index.html index.htm;
 
450
}
 
451
location /RequestDenied {
 
452
         return 412;
 
453
}
 
454
--- raw_request eval
 
455
"GET /?a=1 UnioN SeLEct 1 HTTP/1.0
 
456
 
 
457
"
 
458
--- error_code: 412
 
459
 
 
460
 
 
461
=== TEST 1: hey 17
 
462
--- main_config
 
463
working_directory /tmp/;
 
464
worker_rlimit_core 25M;
 
465
--- http_config
 
466
include /etc/nginx/naxsi_core.rules;
 
467
--- config
 
468
location / {
 
469
         #LearningMode;
 
470
         SecRulesEnabled;
 
471
         DeniedUrl "/RequestDenied";
 
472
        CheckRule "$SQL >= 8" BLOCK;
 
473
        CheckRule "$RFI >= 8" BLOCK;
 
474
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
475
        CheckRule "$XSS >= 8" BLOCK;
 
476
         root $TEST_NGINX_SERVROOT/html/;
 
477
         index index.html index.htm;
 
478
}
 
479
location /RequestDenied {
 
480
         return 412;
 
481
}
 
482
--- raw_request eval
 
483
"GET /?a=AND+1=1+and+'0having'='0having' HTTP/1.0
 
484
 
 
485
"
 
486
--- error_code: 412
 
487
 
 
488
 
 
489
=== TEST 1: hey 18
 
490
--- main_config
 
491
working_directory /tmp/;
 
492
worker_rlimit_core 25M;
 
493
--- http_config
 
494
include /etc/nginx/naxsi_core.rules;
 
495
--- config
 
496
location / {
 
497
         #LearningMode;
 
498
         SecRulesEnabled;
 
499
         DeniedUrl "/RequestDenied";
 
500
        CheckRule "$SQL >= 8" BLOCK;
 
501
        CheckRule "$RFI >= 8" BLOCK;
 
502
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
503
        CheckRule "$XSS >= 8" BLOCK;
 
504
         root $TEST_NGINX_SERVROOT/html/;
 
505
         index index.html index.htm;
 
506
}
 
507
location /RequestDenied {
 
508
         return 412;
 
509
}
 
510
--- raw_request eval
 
511
"GET /?a=SELECT/**/id/**/FROM/**/users HTTP/1.0
 
512
 
 
513
"
 
514
--- error_code: 412
 
515
 
 
516
 
 
517
=== TEST 1: hey 19
 
518
--- main_config
 
519
working_directory /tmp/;
 
520
worker_rlimit_core 25M;
 
521
--- http_config
 
522
include /etc/nginx/naxsi_core.rules;
 
523
--- config
 
524
location / {
 
525
         #LearningMode;
 
526
         SecRulesEnabled;
 
527
         DeniedUrl "/RequestDenied";
 
528
        CheckRule "$SQL >= 8" BLOCK;
 
529
        CheckRule "$RFI >= 8" BLOCK;
 
530
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
531
        CheckRule "$XSS >= 8" BLOCK;
 
532
         root $TEST_NGINX_SERVROOT/html/;
 
533
         index index.html index.htm;
 
534
}
 
535
location /RequestDenied {
 
536
         return 412;
 
537
}
 
538
--- raw_request eval
 
539
"GET /?a=1--PTTmJopxdWJ%0AAND--cWfcVRPV%0A9227=9227 HTTP/1.0
 
540
 
 
541
"
 
542
--- error_code: 412
 
543
 
 
544
 
 
545
=== TEST 1: hey 20
 
546
--- main_config
 
547
working_directory /tmp/;
 
548
worker_rlimit_core 25M;
 
549
--- http_config
 
550
include /etc/nginx/naxsi_core.rules;
 
551
--- config
 
552
location / {
 
553
         #LearningMode;
 
554
         SecRulesEnabled;
 
555
         DeniedUrl "/RequestDenied";
 
556
        CheckRule "$SQL >= 8" BLOCK;
 
557
        CheckRule "$RFI >= 8" BLOCK;
 
558
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
559
        CheckRule "$XSS >= 8" BLOCK;
 
560
         root $TEST_NGINX_SERVROOT/html/;
 
561
         index index.html index.htm;
 
562
}
 
563
location /RequestDenied {
 
564
         return 412;
 
565
}
 
566
--- raw_request eval
 
567
"GET /?a=1%23PTTmJopxdWJ%0AAND%23cWfcVRPV%0A9227=9227 HTTP/1.0
 
568
 
 
569
"
 
570
--- error_code: 412
 
571
 
 
572
 
 
573
=== TEST 1: hey 21
 
574
--- main_config
 
575
working_directory /tmp/;
 
576
worker_rlimit_core 25M;
 
577
--- http_config
 
578
include /etc/nginx/naxsi_core.rules;
 
579
--- config
 
580
location / {
 
581
         #LearningMode;
 
582
         SecRulesEnabled;
 
583
         DeniedUrl "/RequestDenied";
 
584
        CheckRule "$SQL >= 8" BLOCK;
 
585
        CheckRule "$RFI >= 8" BLOCK;
 
586
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
587
        CheckRule "$XSS >= 8" BLOCK;
 
588
         root $TEST_NGINX_SERVROOT/html/;
 
589
         index index.html index.htm;
 
590
}
 
591
location /RequestDenied {
 
592
         return 412;
 
593
}
 
594
--- raw_request eval
 
595
"GET /?a=1%23PTTmJopxdWJ%0AAND%23cWfcVRPV%0A9227=9227 HTTP/1.0
 
596
 
 
597
"
 
598
--- error_code: 412
 
599
 
 
600
 
 
601
=== TEST 1: hey 22
 
602
--- main_config
 
603
working_directory /tmp/;
 
604
worker_rlimit_core 25M;
 
605
--- http_config
 
606
include /etc/nginx/naxsi_core.rules;
 
607
--- config
 
608
location / {
 
609
         #LearningMode;
 
610
         SecRulesEnabled;
 
611
         DeniedUrl "/RequestDenied";
 
612
        CheckRule "$SQL >= 8" BLOCK;
 
613
        CheckRule "$RFI >= 8" BLOCK;
 
614
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
615
        CheckRule "$XSS >= 8" BLOCK;
 
616
         root $TEST_NGINX_SERVROOT/html/;
 
617
         index index.html index.htm;
 
618
}
 
619
location /RequestDenied {
 
620
         return 412;
 
621
}
 
622
--- raw_request eval
 
623
"GET /?a=SELECT%08id%02FROM%0Fusers HTTP/1.0
 
624
 
 
625
"
 
626
--- error_code: 412
 
627
 
 
628
 
 
629
=== TEST 1: hey 23
 
630
--- main_config
 
631
working_directory /tmp/;
 
632
worker_rlimit_core 25M;
 
633
--- http_config
 
634
include /etc/nginx/naxsi_core.rules;
 
635
--- config
 
636
location / {
 
637
         #LearningMode;
 
638
         SecRulesEnabled;
 
639
         DeniedUrl "/RequestDenied";
 
640
        CheckRule "$SQL >= 8" BLOCK;
 
641
        CheckRule "$RFI >= 8" BLOCK;
 
642
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
643
        CheckRule "$XSS >= 8" BLOCK;
 
644
         root $TEST_NGINX_SERVROOT/html/;
 
645
         index index.html index.htm;
 
646
}
 
647
location /RequestDenied {
 
648
         return 412;
 
649
}
 
650
--- raw_request eval
 
651
"GET /?a=1%23%0A9227=922%237 HTTP/1.0
 
652
 
 
653
"
 
654
--- error_code: 412
 
655
 
 
656
 
 
657
=== TEST 1: hey 24
 
658
--- main_config
 
659
working_directory /tmp/;
 
660
worker_rlimit_core 25M;
 
661
--- http_config
 
662
include /etc/nginx/naxsi_core.rules;
 
663
--- config
 
664
location / {
 
665
         #LearningMode;
 
666
         SecRulesEnabled;
 
667
         DeniedUrl "/RequestDenied";
 
668
        CheckRule "$SQL >= 8" BLOCK;
 
669
        CheckRule "$RFI >= 8" BLOCK;
 
670
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
671
        CheckRule "$XSS >= 8" BLOCK;
 
672
         root $TEST_NGINX_SERVROOT/html/;
 
673
         index index.html index.htm;
 
674
}
 
675
location /RequestDenied {
 
676
         return 412;
 
677
}
 
678
--- raw_request eval
 
679
"GET /?a=SELECT%0Bid%0BFROM%A0users HTTP/1.0
 
680
 
 
681
"
 
682
--- error_code: 412
 
683
 
 
684
 
 
685
=== TEST 1: hey 25
 
686
--- main_config
 
687
working_directory /tmp/;
 
688
worker_rlimit_core 25M;
 
689
--- http_config
 
690
include /etc/nginx/naxsi_core.rules;
 
691
--- config
 
692
location / {
 
693
         #LearningMode;
 
694
         SecRulesEnabled;
 
695
         DeniedUrl "/RequestDenied";
 
696
        CheckRule "$SQL >= 8" BLOCK;
 
697
        CheckRule "$RFI >= 8" BLOCK;
 
698
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
699
        CheckRule "$XSS >= 8" BLOCK;
 
700
         root $TEST_NGINX_SERVROOT/html/;
 
701
         index index.html index.htm;
 
702
}
 
703
location /RequestDenied {
 
704
         return 412;
 
705
}
 
706
--- raw_request eval
 
707
"GET /?a=1--%0AAND--%0A9227=9227 HTTP/1.0
 
708
 
 
709
"
 
710
--- error_code: 412
 
711
 
 
712
 
 
713
=== TEST 1: hey 26
 
714
--- main_config
 
715
working_directory /tmp/;
 
716
worker_rlimit_core 25M;
 
717
--- http_config
 
718
include /etc/nginx/naxsi_core.rules;
 
719
--- config
 
720
location / {
 
721
         #LearningMode;
 
722
         SecRulesEnabled;
 
723
         DeniedUrl "/RequestDenied";
 
724
        CheckRule "$SQL >= 8" BLOCK;
 
725
        CheckRule "$RFI >= 8" BLOCK;
 
726
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
727
        CheckRule "$XSS >= 8" BLOCK;
 
728
         root $TEST_NGINX_SERVROOT/html/;
 
729
         index index.html index.htm;
 
730
}
 
731
location /RequestDenied {
 
732
         return 412;
 
733
}
 
734
--- raw_request eval
 
735
"GET /?a=SELECT+id+FROM+users HTTP/1.0
 
736
 
 
737
"
 
738
--- error_code: 412
 
739
 
 
740
 
 
741
 
 
742
=== TEST 1: hey 28
 
743
--- main_config
 
744
working_directory /tmp/;
 
745
worker_rlimit_core 25M;
 
746
--- http_config
 
747
include /etc/nginx/naxsi_core.rules;
 
748
--- config
 
749
location / {
 
750
         #LearningMode;
 
751
         SecRulesEnabled;
 
752
         DeniedUrl "/RequestDenied";
 
753
        CheckRule "$SQL >= 8" BLOCK;
 
754
        CheckRule "$RFI >= 8" BLOCK;
 
755
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
756
        CheckRule "$XSS >= 8" BLOCK;
 
757
         root $TEST_NGINX_SERVROOT/html/;
 
758
         index index.html index.htm;
 
759
}
 
760
location /RequestDenied {
 
761
         return 412;
 
762
}
 
763
--- raw_request eval
 
764
"GET /?a=1%bf%27+AND+1=1--%20 HTTP/1.0
 
765
 
 
766
"
 
767
--- error_code: 412
 
768
 
 
769
 
 
770
=== TEST 1: hey 29
 
771
--- main_config
 
772
working_directory /tmp/;
 
773
worker_rlimit_core 25M;
 
774
--- http_config
 
775
include /etc/nginx/naxsi_core.rules;
 
776
--- config
 
777
location / {
 
778
         #LearningMode;
 
779
         SecRulesEnabled;
 
780
         DeniedUrl "/RequestDenied";
 
781
        CheckRule "$SQL >= 8" BLOCK;
 
782
        CheckRule "$RFI >= 8" BLOCK;
 
783
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
784
        CheckRule "$XSS >= 8" BLOCK;
 
785
         root $TEST_NGINX_SERVROOT/html/;
 
786
         index index.html index.htm;
 
787
}
 
788
location /RequestDenied {
 
789
         return 412;
 
790
}
 
791
--- raw_request eval
 
792
"GET /?a=1/*!UNION*//*!ALL*//*!SELECT*//*!NULL*/,/*!NULL*/,+CONCAT(CHAR(58,104,116,116,58),IFNULL(CAST(CURRENT_USER()/*!AS*//*!CHAR*/),CHAR(32)),CHAR(58,100,114,117,58))# HTTP/1.0
 
793
 
 
794
"
 
795
--- error_code: 412
 
796
 
 
797
 
 
798
=== TEST 1: hey 30
 
799
--- main_config
 
800
working_directory /tmp/;
 
801
worker_rlimit_core 25M;
 
802
--- http_config
 
803
include /etc/nginx/naxsi_core.rules;
 
804
--- config
 
805
location / {
 
806
         #LearningMode;
 
807
         SecRulesEnabled;
 
808
         DeniedUrl "/RequestDenied";
 
809
        CheckRule "$SQL >= 8" BLOCK;
 
810
        CheckRule "$RFI >= 8" BLOCK;
 
811
        CheckRule "$TRAVERSAL >= 4" BLOCK;
 
812
        CheckRule "$XSS >= 8" BLOCK;
 
813
         root $TEST_NGINX_SERVROOT/html/;
 
814
         index index.html index.htm;
 
815
}
 
816
location /RequestDenied {
 
817
         return 412;
 
818
}
 
819
--- raw_request eval
 
820
"GET /?a=1/*!UNION*//*!ALL*//*!SELECT*//*!NULL*/,/*!NULL*/,/*!CONCAT*/(/*!CHAR*/(58,122,114,115,58),/*!IFNULL*/(CAST(/*!CURRENT_USER*/()/*!AS*//*!CHAR*/),/*!CHAR*/(32)),/*!CHAR*/(58,115,114,121,58))# HTTP/1.0
 
821
 
 
822
"
 
823
--- error_code: 412
 
824
 
 
825