akaaafk commited on
Commit
3208996
·
verified ·
1 Parent(s): 6a8351c

Add files using upload-large-folder tool

Browse files
Files changed (20) hide show
  1. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1447036_bonafide.pt +3 -0
  2. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1454808_bonafide.pt +3 -0
  3. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1455854_bonafide.pt +3 -0
  4. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1458883_bonafide.pt +3 -0
  5. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1462637_bonafide.pt +3 -0
  6. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1470174_bonafide.pt +3 -0
  7. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1471269_bonafide.pt +3 -0
  8. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1775062_bonafide.pt +3 -0
  9. benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1775476_bonafide.pt +3 -0
  10. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/classes/asset/instance.php +555 -0
  11. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/classes/cache/notfound.php +16 -0
  12. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/classes/config/db.php +154 -0
  13. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/.gitkeep +0 -0
  14. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/byte_units.php +44 -0
  15. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/date.php +29 -0
  16. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/pagination.php +7 -0
  17. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/test.php +17 -0
  18. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/upload.php +23 -0
  19. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/validation.php +20 -0
  20. benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/tests/cache/storage/redis.php +24 -0
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1447036_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:95570005998a4631b360223ea2416ca4fab12f70aeebf41c5fd75ec26e93bdb0
3
+ size 49378
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1454808_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:46f9fead85bf4921f91a31c4cf009fb75007a942e7f05502fc491b18d3f91dc8
3
+ size 49378
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1455854_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:fc33cf872ed3c73843b6aa6874442bee5e9c18779578064d47beb6e3d3679804
3
+ size 49378
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1458883_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:3dc5577d09aa8d96821fb1079522cbb0b5e1632a8dc883f45c49c37930f5b94b
3
+ size 49378
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1462637_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:c96feb94519e64d3ce43af353feb437310e999aea05da869a0fce53e412abb72
3
+ size 49378
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1470174_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:e438e229d8e94f98a99ef025f65ece52edfa205c09838a62862d5da7d60aedd4
3
+ size 49378
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1471269_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:b86820c33cfb3093b80b0c64f53c3024ad7563f025984537e9f032829315855e
3
+ size 49378
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1775062_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:4bc8c70f17e19daa439dc17927a6a54d70ef6610475abd821009c578eceedf18
3
+ size 49378
benchmark/IOAI/IOAI-2025/GAITE-Contest/Synthetic_Speech_Detector/training_set/bonafide/LA_E_1775476_bonafide.pt ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:1ec324a1d52d3b7d704e9f2e8791d3512fdc6d922402396c0e0a56782aa13507
3
+ size 49378
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/classes/asset/instance.php ADDED
@@ -0,0 +1,555 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Part of the Fuel framework.
4
+ *
5
+ * @package Fuel
6
+ * @version 1.7
7
+ * @author Fuel Development Team
8
+ * @license MIT License
9
+ * @copyright 2010 - 2013 Fuel Development Team
10
+ * @link http://fuelphp.com
11
+ */
12
+
13
+ namespace Fuel\Core;
14
+
15
+ /**
16
+ * The Asset class allows you to easily work with your apps assets.
17
+ * It allows you to specify multiple paths to be searched for the
18
+ * assets.
19
+ *
20
+ * You can configure the paths by copying the core/config/asset.php
21
+ * config file into your app/config folder and changing the settings.
22
+ *
23
+ * @package Fuel
24
+ * @subpackage Core
25
+ */
26
+ class Asset_Instance
27
+ {
28
+
29
+ /**
30
+ * @var array the asset paths to be searched
31
+ */
32
+ protected $_asset_paths = array(
33
+ 'css' => array(),
34
+ 'js' => array(),
35
+ 'img' => array(),
36
+ );
37
+
38
+ /**
39
+ * @var array the sub-folders to be searched
40
+ */
41
+ protected $_path_folders = array(
42
+ 'css' => 'css/',
43
+ 'js' => 'js/',
44
+ 'img' => 'img/',
45
+ );
46
+
47
+ /**
48
+ * @var string the URL to be prepended to all assets
49
+ */
50
+ protected $_asset_url = '/';
51
+
52
+ /**
53
+ * @var bool whether to append the file mtime to the url
54
+ */
55
+ protected $_add_mtime = true;
56
+
57
+ /**
58
+ * @var array holds the groups of assets
59
+ */
60
+ protected $_groups = array();
61
+
62
+ /**
63
+ * @var string prefix for generated output to provide proper indentation
64
+ */
65
+ protected $_ident = '';
66
+
67
+ /**
68
+ * @var bool if true, directly renders the output of no group name is given
69
+ */
70
+ protected $_auto_render = true;
71
+
72
+ /**
73
+ * @var bool if true the 'not found' exception will not be thrown and the asset is ignored.
74
+ */
75
+ protected $_fail_silently = false;
76
+
77
+ /**
78
+ * Parse the config and initialize the object instance
79
+ *
80
+ * @return void
81
+ */
82
+ public function __construct($config)
83
+ {
84
+ //global search path folders
85
+ isset($config['css_dir']) and $this->_path_folders['css'] = $this->_unify_path($config['css_dir']);
86
+ isset($config['js_dir']) and $this->_path_folders['js'] = $this->_unify_path($config['js_dir']);
87
+ isset($config['img_dir']) and $this->_path_folders['img'] = $this->_unify_path($config['img_dir']);
88
+
89
+ // global search paths
90
+ foreach ($config['paths'] as $path)
91
+ {
92
+ $this->add_path($path);
93
+ }
94
+
95
+ // per-type search paths
96
+ foreach ($config['folders'] as $type => $folders)
97
+ {
98
+ is_array($folders) or $folders = array($folders);
99
+
100
+ foreach ($folders as $path)
101
+ {
102
+ $this->add_path($path, $type);
103
+ }
104
+ }
105
+
106
+ $this->_add_mtime = $config['add_mtime'];
107
+ $this->_asset_url = $config['url'];
108
+ $this->_indent = str_repeat($config['indent_with'], $config['indent_level']);
109
+ $this->_auto_render = $config['auto_render'];
110
+ $this->_fail_silently = $config['fail_silently'];
111
+ }
112
+
113
+ /**
114
+ * Adds a new asset type to the list so we can load files of this type
115
+ *
116
+ * @param string new path type
117
+ * @param string optional default path
118
+ * @return object current instance
119
+ */
120
+ public function add_type($type, $path = null)
121
+ {
122
+ isset($this->_asset_paths[$type]) or $this->_asset_paths[$type] = array();
123
+ isset($this->_path_folders[$type]) or $this->_path_folders[$type] = $type.'/';
124
+
125
+ if ( ! is_null($path))
126
+ {
127
+ $path = $this->_unify_path($path);
128
+ $this->_asset_paths[$type][] = $path;
129
+ }
130
+
131
+ return $this;
132
+ }
133
+
134
+ /**
135
+ * Adds the given path to the front of the asset paths array. It adds paths
136
+ * in a way so that asset paths are used First in Last Out.
137
+ *
138
+ * @param string the path to add
139
+ * @param string optional path type (js, css or img)
140
+ * @return object current instance
141
+ */
142
+ public function add_path($path, $type = null)
143
+ {
144
+ is_null($type) and $type = $this->_path_folders;
145
+ empty($path) and $path = DOCROOT;
146
+
147
+ if( is_array($type))
148
+ {
149
+ foreach ($type as $key => $folder)
150
+ {
151
+ is_numeric($key) and $key = $folder;
152
+ $folder = $this->_unify_path($path).ltrim($this->_unify_path($folder),DS);
153
+ array_unshift($this->_asset_paths[$key], $folder);
154
+ }
155
+ }
156
+ else
157
+ {
158
+ // create the asset type if it doesn't exist
159
+ if ( ! isset($this->_asset_paths[$type]))
160
+ {
161
+ $this->_asset_paths[$type] = array();
162
+ $this->_path_folders[$type] = $type.'/';
163
+ }
164
+
165
+ $path = $this->_unify_path($path);
166
+ array_unshift($this->_asset_paths[$type], $path);
167
+ }
168
+ return $this;
169
+ }
170
+
171
+ /**
172
+ * Removes the given path from the asset paths array
173
+ *
174
+ * @param string the path to remove
175
+ * @param string optional path type (js, css or img)
176
+ * @return object current instance
177
+ */
178
+ public function remove_path($path, $type = null)
179
+ {
180
+ is_null($type) and $type = $this->_path_folders;
181
+
182
+ if( is_array($type))
183
+ {
184
+ foreach ($type as $key => $folder)
185
+ {
186
+ is_numeric($key) and $key = $folder;
187
+ $folder = $this->_unify_path($path).ltrim($this->_unify_path($folder),DS);
188
+ if (($found = array_search($folder, $this->_asset_paths[$key])) !== false)
189
+ {
190
+ unset($this->_asset_paths[$key][$found]);
191
+ }
192
+ }
193
+ }
194
+ else
195
+ {
196
+ $path = $this->_unify_path($path);
197
+ if (($key = array_search($path, $this->_asset_paths[$type])) !== false)
198
+ {
199
+ unset($this->_asset_paths[$type][$key]);
200
+ }
201
+ }
202
+
203
+ return $this;
204
+ }
205
+
206
+ /**
207
+ * Renders the given group. Each tag will be separated by a line break.
208
+ * You can optionally tell it to render the files raw. This means that
209
+ * all CSS and JS files in the group will be read and the contents included
210
+ * in the returning value.
211
+ *
212
+ * @param mixed the group to render
213
+ * @param bool whether to return the raw file or not
214
+ * @return string the group's output
215
+ */
216
+ public function render($group = null, $raw = false)
217
+ {
218
+ is_null($group) and $group = '_default_';
219
+
220
+ if (is_string($group))
221
+ {
222
+ isset($this->_groups[$group]) and $group = $this->_groups[$group];
223
+ }
224
+
225
+ is_array($group) or $group = array();
226
+
227
+ $css = '';
228
+ $js = '';
229
+ $img = '';
230
+ foreach ($group as $key => $item)
231
+ {
232
+ $type = $item['type'];
233
+ $filename = $item['file'];
234
+ $attr = $item['attr'];
235
+ $inline = $item['raw'];
236
+
237
+ // only do a file search if the asset is not a URI
238
+ if ( ! preg_match('|^(\w+:)?//|', $filename))
239
+ {
240
+ // and only if the asset is local to the applications base_url
241
+ if ( ! preg_match('|^(\w+:)?//|', $this->_asset_url) or strpos($this->_asset_url, \Config::get('base_url')) === 0)
242
+ {
243
+ if ( ! ($file = $this->find_file($filename, $type)))
244
+ {
245
+ if ($raw or $inline)
246
+ {
247
+ $file = $filename;
248
+ }
249
+ else
250
+ {
251
+ if ($this->_fail_silently)
252
+ {
253
+ continue;
254
+ }
255
+
256
+ throw new \FuelException('Could not find asset: '.$filename);
257
+ }
258
+ }
259
+ else
260
+ {
261
+ if ($raw or $inline)
262
+ {
263
+ $file = file_get_contents($file);
264
+ $inline = true;
265
+ }
266
+ else
267
+ {
268
+ $file = $this->_asset_url.$file.($this->_add_mtime ? '?'.filemtime($file) : '');
269
+ }
270
+ }
271
+ }
272
+ else
273
+ {
274
+ $file = $this->_asset_url.$this->_path_folders[$type].$filename;
275
+ if ($raw or $inline)
276
+ {
277
+ $file = file_get_contents($file);
278
+ $inline = true;
279
+ }
280
+ }
281
+ }
282
+ else
283
+ {
284
+ $file = $filename;
285
+ }
286
+
287
+ switch($type)
288
+ {
289
+ case 'css':
290
+ $attr['type'] = 'text/css';
291
+ if ($inline)
292
+ {
293
+ $css .= html_tag('style', $attr, PHP_EOL.$file.PHP_EOL).PHP_EOL;
294
+ }
295
+ else
296
+ {
297
+ if ( ! isset($attr['rel']) or empty($attr['rel']))
298
+ {
299
+ $attr['rel'] = 'stylesheet';
300
+ }
301
+ $attr['href'] = $file;
302
+
303
+ $css .= $this->_indent.html_tag('link', $attr).PHP_EOL;
304
+ }
305
+ break;
306
+ case 'js':
307
+ $attr['type'] = 'text/javascript';
308
+ if ($inline)
309
+ {
310
+ $js .= html_tag('script', $attr, PHP_EOL.$file.PHP_EOL).PHP_EOL;
311
+ }
312
+ else
313
+ {
314
+ $attr['src'] = $file;
315
+
316
+ $js .= $this->_indent.html_tag('script', $attr, '').PHP_EOL;
317
+ }
318
+ break;
319
+ case 'img':
320
+ $attr['src'] = $file;
321
+ $attr['alt'] = isset($attr['alt']) ? $attr['alt'] : '';
322
+
323
+ $img .= html_tag('img', $attr );
324
+ break;
325
+ }
326
+
327
+ }
328
+
329
+ // return them in the correct order
330
+ return $css.$js.$img;
331
+ }
332
+
333
+ // --------------------------------------------------------------------
334
+
335
+ /**
336
+ * CSS
337
+ *
338
+ * Either adds the stylesheet to the group, or returns the CSS tag.
339
+ *
340
+ * @access public
341
+ * @param mixed The file name, or an array files.
342
+ * @param array An array of extra attributes
343
+ * @param string The asset group name
344
+ * @return string|object Rendered asset or current instance when adding to group
345
+ */
346
+ public function css($stylesheets = array(), $attr = array(), $group = null, $raw = false)
347
+ {
348
+ static $temp_group = 1000000;
349
+
350
+ if ($group === null)
351
+ {
352
+ $render = $this->_auto_render;
353
+ $group = $render ? (string) (++$temp_group) : '_default_';
354
+ }
355
+ else
356
+ {
357
+ $render = false;
358
+ }
359
+
360
+ $this->_parse_assets('css', $stylesheets, $attr, $group, $raw);
361
+
362
+ if ($render)
363
+ {
364
+ return $this->render($group, $raw);
365
+ }
366
+
367
+ return $this;
368
+ }
369
+
370
+ // --------------------------------------------------------------------
371
+
372
+ /**
373
+ * JS
374
+ *
375
+ * Either adds the javascript to the group, or returns the script tag.
376
+ *
377
+ * @access public
378
+ * @param mixed The file name, or an array files.
379
+ * @param array An array of extra attributes
380
+ * @param string The asset group name
381
+ * @return string|object Rendered asset or current instance when adding to group
382
+ */
383
+ public function js($scripts = array(), $attr = array(), $group = null, $raw = false)
384
+ {
385
+ static $temp_group = 2000000;
386
+
387
+ if ( ! isset($group))
388
+ {
389
+ $render = $this->_auto_render;
390
+ $group = $render ? (string) (++$temp_group) : '_default_';
391
+ }
392
+ else
393
+ {
394
+ $render = false;
395
+ }
396
+
397
+ $this->_parse_assets('js', $scripts, $attr, $group, $raw);
398
+
399
+ if ($render)
400
+ {
401
+ return $this->render($group, $raw);
402
+ }
403
+
404
+ return $this;
405
+ }
406
+
407
+ // --------------------------------------------------------------------
408
+
409
+ /**
410
+ * Img
411
+ *
412
+ * Either adds the image to the group, or returns the image tag.
413
+ *
414
+ * @access public
415
+ * @param mixed The file name, or an array files.
416
+ * @param array An array of extra attributes
417
+ * @param string The asset group name
418
+ * @return string|object Rendered asset or current instance when adding to group
419
+ */
420
+ public function img($images = array(), $attr = array(), $group = null)
421
+ {
422
+ static $temp_group = 3000000;
423
+
424
+ if ( ! isset($group))
425
+ {
426
+ $render = $this->_auto_render;
427
+ $group = $render ? (string) (++$temp_group) : '_default_';
428
+ }
429
+ else
430
+ {
431
+ $render = false;
432
+ }
433
+
434
+ $this->_parse_assets('img', $images, $attr, $group);
435
+
436
+ if ($render)
437
+ {
438
+ return $this->render($group);
439
+ }
440
+
441
+ return $this;
442
+ }
443
+
444
+ // --------------------------------------------------------------------
445
+
446
+ /**
447
+ * Find File
448
+ *
449
+ * Locates a file in all the asset paths.
450
+ *
451
+ * @access public
452
+ * @param string The filename to locate
453
+ * @param string The sub-folder to look in (optional)
454
+ * @return mixed Either the path to the file or false if not found
455
+ */
456
+ public function find_file($file, $type, $folder = '')
457
+ {
458
+ foreach ($this->_asset_paths[$type] as $path)
459
+ {
460
+ empty($folder) or $folder = $this->_unify_path($folder);
461
+
462
+ if (is_file($newfile = $path.$folder.$this->_unify_path($file, null, false)))
463
+ {
464
+ strpos($newfile, DOCROOT) === 0 and $newfile = substr($newfile, strlen(DOCROOT));
465
+
466
+ // return the file found, make sure it uses forward slashes on Windows
467
+ return str_replace(DS, '/', $newfile);
468
+ }
469
+ }
470
+
471
+ return false;
472
+ }
473
+
474
+ // --------------------------------------------------------------------
475
+
476
+ /**
477
+ * Get File
478
+ *
479
+ * Locates a file in all the asset paths, and return it relative to the docroot
480
+ *
481
+ * @access public
482
+ * @param string The filename to locate
483
+ * @param string The sub-folder to look in (optional)
484
+ * @return mixed Either the path to the file or false if not found
485
+ */
486
+ public function get_file($file, $type, $folder = '')
487
+ {
488
+ if ($file = $this->find_file($file, $type, $folder))
489
+ {
490
+ return $this->_asset_url.$file;
491
+ }
492
+
493
+ return false;
494
+ }
495
+
496
+ // --------------------------------------------------------------------
497
+
498
+ /**
499
+ * Parse Assets
500
+ *
501
+ * Pareses the assets and adds them to the group
502
+ *
503
+ * @access private
504
+ * @param string The asset type
505
+ * @param mixed The file name, or an array files.
506
+ * @param array An array of extra attributes
507
+ * @param string The asset group name
508
+ * @return string
509
+ */
510
+ protected function _parse_assets($type, $assets, $attr, $group, $raw = false)
511
+ {
512
+ if ( ! is_array($assets))
513
+ {
514
+ $assets = array($assets);
515
+ }
516
+
517
+ foreach ($assets as $key => $asset)
518
+ {
519
+ // Prevent duplicate files in a group.
520
+ if (\Arr::get($this->_groups, "$group.$key.file") == $asset)
521
+ {
522
+ continue;
523
+ }
524
+
525
+ $this->_groups[$group][] = array(
526
+ 'type' => $type,
527
+ 'file' => $asset,
528
+ 'raw' => $raw,
529
+ 'attr' => (array) $attr
530
+ );
531
+ }
532
+ }
533
+
534
+ // --------------------------------------------------------------------
535
+
536
+ /**
537
+ * Unify the path
538
+ *
539
+ * make sure the directory separator in the path is correct for the
540
+ * platform used, is terminated with a directory separator, and all
541
+ * relative path references are removed
542
+ *
543
+ * @access private
544
+ * @param string The path
545
+ * @param mixed Optional directory separator
546
+ * @return string
547
+ */
548
+ protected function _unify_path($path, $ds = null, $trailing = true)
549
+ {
550
+ $ds === null and $ds = DS;
551
+
552
+ return rtrim(str_replace(array('\\', '/'), $ds, $path), $ds).($trailing ? $ds : '');
553
+ }
554
+
555
+ }
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/classes/cache/notfound.php ADDED
@@ -0,0 +1,16 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Part of the Fuel framework.
4
+ *
5
+ * @package Fuel
6
+ * @version 1.7
7
+ * @author Fuel Development Team
8
+ * @license MIT License
9
+ * @copyright 2010 - 2013 Fuel Development Team
10
+ * @link http://fuelphp.com
11
+ */
12
+
13
+ namespace Fuel\Core;
14
+
15
+ // Exception thrown when the Cache wasn't found
16
+ class CacheNotFoundException extends \OutOfBoundsException {}
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/classes/config/db.php ADDED
@@ -0,0 +1,154 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ namespace Fuel\Core;
4
+
5
+ /**
6
+ * DB config data parser
7
+ */
8
+ class Config_Db implements Config_Interface
9
+ {
10
+ protected $identifier;
11
+
12
+ protected $ext = '.db';
13
+
14
+ protected $vars = array();
15
+
16
+ protected $table;
17
+
18
+ /**
19
+ * Sets up the file to be parsed and variables
20
+ *
21
+ * @param string $file Config identifier name
22
+ * @param array $vars Variables to parse in the data retrieved
23
+ * @return void
24
+ */
25
+ public function __construct($identifier = null, $vars = array())
26
+ {
27
+ $this->identifier = $identifier;
28
+
29
+ $this->vars = array(
30
+ 'APPPATH' => APPPATH,
31
+ 'COREPATH' => COREPATH,
32
+ 'PKGPATH' => PKGPATH,
33
+ 'DOCROOT' => DOCROOT,
34
+ ) + $vars;
35
+
36
+ $this->table = \Config::get('config.table_name', 'config');
37
+ }
38
+
39
+ /**
40
+ * Loads the config file(s).
41
+ *
42
+ * @param bool $overwrite Whether to overwrite existing values
43
+ * @return array the config array
44
+ */
45
+ public function load($overwrite = false, $cache = true)
46
+ {
47
+ $config = array();
48
+
49
+ // try to retrieve the config from the database
50
+ try
51
+ {
52
+ $result = \DB::select('config')->from($this->table)->where('identifier', '=', $this->identifier)->execute();
53
+ }
54
+ catch (Database_Exception $e)
55
+ {
56
+ // strip the actual query from the message
57
+ $msg = $e->getMessage();
58
+ $msg = substr($msg, 0, strlen($msg) - strlen(strrchr($msg, ':')));
59
+
60
+ // and rethrow it
61
+ throw new \Database_Exception($msg);
62
+ }
63
+
64
+ // did we succeed?
65
+ if ($result->count())
66
+ {
67
+ empty($result[0]['config']) or $config = unserialize($this->parse_vars($result[0]['config']));
68
+ }
69
+
70
+ return $config;
71
+ }
72
+
73
+ /**
74
+ * Gets the default group name.
75
+ *
76
+ * @return string
77
+ */
78
+ public function group()
79
+ {
80
+ return $this->identifier;
81
+ }
82
+
83
+ /**
84
+ * Parses a string using all of the previously set variables. Allows you to
85
+ * use something like %APPPATH% in non-PHP files.
86
+ *
87
+ * @param string $string String to parse
88
+ * @return string
89
+ */
90
+ protected function parse_vars($string)
91
+ {
92
+ foreach ($this->vars as $var => $val)
93
+ {
94
+ $string = str_replace("%$var%", $val, $string);
95
+ }
96
+
97
+ return $string;
98
+ }
99
+
100
+ /**
101
+ * Replaces FuelPHP's path constants to their string counterparts.
102
+ *
103
+ * @param array $array array to be prepped
104
+ * @return array prepped array
105
+ */
106
+ protected function prep_vars(&$array)
107
+ {
108
+ static $replacements = false;
109
+
110
+ if ($replacements === false)
111
+ {
112
+ foreach ($this->vars as $i => $v)
113
+ {
114
+ $replacements['#^('.preg_quote($v).'){1}(.*)?#'] = "%".$i."%$2";
115
+ }
116
+ }
117
+
118
+ foreach ($array as $i => $value)
119
+ {
120
+ if (is_string($value))
121
+ {
122
+ $array[$i] = preg_replace(array_keys($replacements), array_values($replacements), $value);
123
+ }
124
+ elseif(is_array($value))
125
+ {
126
+ $this->prep_vars($array[$i]);
127
+ }
128
+ }
129
+ }
130
+
131
+ /**
132
+ * Formats the output and saved it to disc.
133
+ *
134
+ * @param $contents $contents config array to save
135
+ * @return bool DB result
136
+ */
137
+ public function save($contents)
138
+ {
139
+ // prep the contents
140
+ $this->prep_vars($contents);
141
+ $contents = serialize($contents);
142
+
143
+ // update the config in the database
144
+ $result = \DB::update($this->table)->set(array('config' => $contents, 'hash' => uniqid()))->where('identifier', '=', $this->identifier)->execute();
145
+
146
+ // if there wasn't an update, do an insert
147
+ if ($result === 0)
148
+ {
149
+ list($notused, $result) = \DB::insert($this->table)->set(array('identifier' => $this->identifier, 'config' => $contents, 'hash' => uniqid()))->execute();
150
+ }
151
+
152
+ return $result === 1;
153
+ }
154
+ }
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/.gitkeep ADDED
File without changes
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/byte_units.php ADDED
@@ -0,0 +1,44 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ /**
4
+ * Valid byte units => power of 2 that defines the unit's size
5
+ *
6
+ * @var array
7
+ */
8
+ return array(
9
+ 'B' => 0,
10
+ 'K' => 10,
11
+ 'Ki' => 10,
12
+ 'KB' => 10,
13
+ 'KiB' => 10,
14
+ 'M' => 20,
15
+ 'Mi' => 20,
16
+ 'MB' => 20,
17
+ 'MiB' => 20,
18
+ 'G' => 30,
19
+ 'Gi' => 30,
20
+ 'GB' => 30,
21
+ 'GiB' => 30,
22
+ 'T' => 40,
23
+ 'Ti' => 40,
24
+ 'TB' => 40,
25
+ 'TiB' => 40,
26
+ 'P' => 50,
27
+ 'Pi' => 50,
28
+ 'PB' => 50,
29
+ 'PiB' => 50,
30
+ 'E' => 60,
31
+ 'Ei' => 60,
32
+ 'EB' => 60,
33
+ 'EiB' => 60,
34
+ 'Z' => 70,
35
+ 'Zi' => 70,
36
+ 'ZB' => 70,
37
+ 'ZiB' => 70,
38
+ 'Y' => 80,
39
+ 'Yi' => 80,
40
+ 'YB' => 80,
41
+ 'YiB' => 80,
42
+ );
43
+
44
+ /* End of file lang/en/byte_units.php */
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/date.php ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ return array(
4
+ 'text' => ':time ago',
5
+
6
+ 'second' => ':t second',
7
+ 'seconds' => ':t seconds',
8
+
9
+ 'minute' => ':t minute',
10
+ 'minutes' => ':t minutes',
11
+
12
+ 'hour' => ':t hour',
13
+ 'hours' => ':t hours',
14
+
15
+ 'day' => ':t day',
16
+ 'days' => ':t days',
17
+
18
+ 'week' => ':t week',
19
+ 'weeks' => ':t weeks',
20
+
21
+ 'month' => ':t month',
22
+ 'months' => ':t months',
23
+
24
+ 'year' => ':t year',
25
+ 'years' => ':t years',
26
+
27
+ 'decade' => ':t decade',
28
+ 'decades' => ':t decades',
29
+ );
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/pagination.php ADDED
@@ -0,0 +1,7 @@
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ return array(
4
+ 'previous' => 'Previous',
5
+ 'next' => 'Next',
6
+ );
7
+
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/test.php ADDED
@@ -0,0 +1,17 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Part of the Fuel framework.
4
+ *
5
+ * @package Fuel
6
+ * @version 1.7
7
+ * @author Fuel Development Team
8
+ * @license MIT License
9
+ * @copyright 2010 - 2013 Fuel Development Team
10
+ * @link http://fuelphp.com
11
+ */
12
+
13
+
14
+ return array(
15
+ 'hello' => 'Hello there :name!'
16
+ );
17
+
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/upload.php ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ return array(
4
+ 'error_'.\Upload::UPLOAD_ERR_OK => 'The file uploaded with success',
5
+ 'error_'.\Upload::UPLOAD_ERR_INI_SIZE => 'The uploaded file exceeds the upload_max_filesize directive in php.ini',
6
+ 'error_'.\Upload::UPLOAD_ERR_FORM_SIZE => 'The uploaded file exceeds the MAX_FILE_SIZE directive that was specified in the HTML form',
7
+ 'error_'.\Upload::UPLOAD_ERR_PARTIAL => 'The uploaded file was only partially uploaded',
8
+ 'error_'.\Upload::UPLOAD_ERR_NO_FILE => 'No file was uploaded',
9
+ 'error_'.\Upload::UPLOAD_ERR_NO_TMP_DIR => 'Configured temporary upload folder is missing',
10
+ 'error_'.\Upload::UPLOAD_ERR_CANT_WRITE => 'Failed to write uploaded file to disk',
11
+ 'error_'.\Upload::UPLOAD_ERR_EXTENSION => 'Upload blocked by an installed PHP extension',
12
+ 'error_'.\Upload::UPLOAD_ERR_MAX_SIZE => 'The uploaded file exceeds the defined maximum size',
13
+ 'error_'.\Upload::UPLOAD_ERR_EXT_BLACKLISTED => 'Upload of files with this extension is not allowed',
14
+ 'error_'.\Upload::UPLOAD_ERR_EXT_NOT_WHITELISTED => 'Upload of files with this extension is not allowed',
15
+ 'error_'.\Upload::UPLOAD_ERR_TYPE_BLACKLISTED => 'Upload of files of this file type is not allowed',
16
+ 'error_'.\Upload::UPLOAD_ERR_TYPE_NOT_WHITELISTED => 'Upload of files of this file type is not allowed',
17
+ 'error_'.\Upload::UPLOAD_ERR_MIME_BLACKLISTED => 'Upload of files of this mime type is not allowed',
18
+ 'error_'.\Upload::UPLOAD_ERR_MIME_NOT_WHITELISTED => 'Upload of files of this mime type is not allowed',
19
+ 'error_'.\Upload::UPLOAD_ERR_MAX_FILENAME_LENGTH => 'The uploaded file name exceeds the defined maximum length',
20
+ 'error_'.\Upload::UPLOAD_ERR_MOVE_FAILED => 'Unable to move the uploaded file to it\'s final destination',
21
+ 'error_'.\Upload::UPLOAD_ERR_DUPLICATE_FILE => 'A file with the name of the uploaded file already exists',
22
+ 'error_'.\Upload::UPLOAD_ERR_MKDIR_FAILED => 'Unable to create the file\'s destination directory',
23
+ );
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/lang/en/validation.php ADDED
@@ -0,0 +1,20 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+
3
+ return array(
4
+ 'required' => 'The field :label is required and must contain a value.',
5
+ 'min_length' => 'The field :label has to contain at least :param:1 characters.',
6
+ 'max_length' => 'The field :label may not contain more than :param:1 characters.',
7
+ 'exact_length' => 'The field :label must contain exactly :param:1 characters.',
8
+ 'match_value' => 'The field :label must contain the value :param:1.',
9
+ 'match_pattern' => 'The field :label must match the pattern :param:1.',
10
+ 'match_field' => 'The field :label must match the field :param:1.',
11
+ 'valid_email' => 'The field :label must contain a valid email address.',
12
+ 'valid_emails' => 'The field :label must contain a list of valid email addresses.',
13
+ 'valid_url' => 'The field :label must contain a valid URL.',
14
+ 'valid_ip' => 'The field :label must contain a valid IP address.',
15
+ 'numeric_min' => 'The minimum numeric value of :label must be :param:1',
16
+ 'numeric_max' => 'The maximum numeric value of :label must be :param:1',
17
+ 'numeric_between' => 'The field :label must contain a numeric value between :param:1 and :param:2',
18
+ 'valid_string' => 'The valid string rule :rule(:param:1) failed for field :label',
19
+ 'required_with' => 'The field :label must contain a value if :param:1 contains a value.',
20
+ );
benchmark/NYU_CTF_Bench/development/2013/CSAW-Finals/web/historypeats/csaw/fuel/core/tests/cache/storage/redis.php ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ /**
3
+ * Part of the Fuel framework.
4
+ *
5
+ * @package Fuel
6
+ * @version 1.7
7
+ * @author Fuel Development Team
8
+ * @license MIT License
9
+ * @copyright 2010 - 2013 Fuel Development Team
10
+ * @link http://fuelphp.com
11
+ */
12
+
13
+ namespace Fuel\Core;
14
+
15
+ /**
16
+ * Cache_Storage_Redis class tests
17
+ *
18
+ * @group Core
19
+ * @group Cache
20
+ */
21
+ class Test_Cache_Storage_Redis extends TestCase
22
+ {
23
+ public function test_foo() {}
24
+ }