Initial commit
This commit is contained in:
16
#pma/test/test_data/config.inc.php
Normal file
16
#pma/test/test_data/config.inc.php
Normal file
@ -0,0 +1,16 @@
|
||||
<?php
|
||||
/**
|
||||
* Minimal config file for test
|
||||
*
|
||||
* @package PhpMyAdmin-test
|
||||
*/
|
||||
$i = 0;
|
||||
|
||||
/* Server: localhost [1] */
|
||||
$i++;
|
||||
$cfg['Servers'][$i]['verbose'] = '';
|
||||
$cfg['Servers'][$i]['host'] = 'localhost';
|
||||
$cfg['Servers'][$i]['port'] = '';
|
||||
$cfg['Servers'][$i]['socket'] = '';
|
||||
$cfg['Servers'][$i]['connect_type'] = 'tcp';
|
||||
$cfg['Servers'][$i]['auth_type'] = 'cookie';
|
8
#pma/test/test_data/db_import.sql
Normal file
8
#pma/test/test_data/db_import.sql
Normal file
@ -0,0 +1,8 @@
|
||||
|
||||
--
|
||||
-- Table structure for table `test_table`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `test_table` (
|
||||
`val` int(11) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
1
#pma/test/test_data/db_test.csv
Normal file
1
#pma/test/test_data/db_test.csv
Normal file
@ -0,0 +1 @@
|
||||
"1","dbbase",,"ddd","SELECT * FROM `db_content` WHERE 1"
|
|
BIN
#pma/test/test_data/db_test.ods
Normal file
BIN
#pma/test/test_data/db_test.ods
Normal file
Binary file not shown.
1
#pma/test/test_data/db_test_ldi.csv
Normal file
1
#pma/test/test_data/db_test_ldi.csv
Normal file
@ -0,0 +1 @@
|
||||
"1","dbbase",,"ddd","SELECT * FROM `db_content` WHERE 1"
|
|
BIN
#pma/test/test_data/dresden_osm.shp.zip
Normal file
BIN
#pma/test/test_data/dresden_osm.shp.zip
Normal file
Binary file not shown.
150
#pma/test/test_data/exploit_test.sql
Normal file
150
#pma/test/test_data/exploit_test.sql
Normal file
@ -0,0 +1,150 @@
|
||||
-- phpMyAdmin SQL Dump
|
||||
-- version 3.5.0-dev
|
||||
-- https://www.phpmyadmin.net
|
||||
--
|
||||
-- Host: barclay
|
||||
-- Generation Time: Aug 06, 2011 at 04:53 PM
|
||||
-- Server version: 5.1.49-3-log
|
||||
-- PHP Version: 5.3.3-7+squeeze1
|
||||
|
||||
SET SQL_MODE="NO_AUTO_VALUE_ON_ZERO";
|
||||
SET time_zone = "+00:00";
|
||||
|
||||
|
||||
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||
/*!40101 SET NAMES utf8 */;
|
||||
|
||||
DROP DATABASE IF EXISTS `"><script>alert(200);</script>`;
|
||||
DROP DATABASE IF EXISTS `'><script>alert(201);</script>`;
|
||||
DROP DATABASE IF EXISTS `exploit_test`;
|
||||
|
||||
--
|
||||
-- Database: `"><script>alert(200);</script>`
|
||||
--
|
||||
CREATE DATABASE `"><script>alert(200);</script>` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
|
||||
|
||||
--
|
||||
-- Database: `'><script>alert(201);</script>`
|
||||
--
|
||||
CREATE DATABASE `'><script>alert(201);</script>` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
|
||||
|
||||
--
|
||||
-- Database: `exploit_test`
|
||||
--
|
||||
CREATE DATABASE `exploit_test` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
|
||||
USE `exploit_test`;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `"><script>alert(109);</script>`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `"><script>alert(109);</script>` (
|
||||
`id` int(2) NOT NULL,
|
||||
`foo` varchar(255) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
--
|
||||
-- Dumping data for table `"><script>alert(109);</script>`
|
||||
--
|
||||
|
||||
INSERT INTO `"><script>alert(109);</script>` (`id`, `foo`) VALUES
|
||||
(1, ''),
|
||||
(2, '');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `'; eval('alert(107)')`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `'; eval('alert(107)')` (
|
||||
`id` int(11) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `'><script>alert(106);</script>`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `'><script>alert(106);</script>` (
|
||||
`id` int(2) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `<script>alert(105);</script>`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `<script>alert(105);</script>` (
|
||||
`dsaf` int(4) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
--
|
||||
-- Dumping data for table `<script>alert(105);</script>`
|
||||
--
|
||||
|
||||
INSERT INTO `<script>alert(105);</script>` (`dsaf`) VALUES
|
||||
(1);
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `evil_column_names`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `evil_column_names` (
|
||||
`<script>alert(100);</script>` int(1) NOT NULL,
|
||||
`"><script>alert(101);</script>` int(2) NOT NULL,
|
||||
`'><script>alert(102);</script>` int(2) NOT NULL,
|
||||
`evil_comment` int(3) NOT NULL COMMENT '<script>alert(104);</script>'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
--
|
||||
-- Dumping data for table `evil_column_names`
|
||||
--
|
||||
|
||||
INSERT INTO `evil_column_names` (`<script>alert(100);</script>`, `"><script>alert(101);</script>`, `'><script>alert(102);</script>`, `evil_comment`) VALUES
|
||||
(1, 23, 45, 5),
|
||||
(2, 3, 77, 3);
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `evil_content`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `evil_content` (
|
||||
`text` varchar(255) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
--
|
||||
-- Dumping data for table `evil_content`
|
||||
--
|
||||
|
||||
INSERT INTO `evil_content` (`text`) VALUES
|
||||
('"><script>alert(301);</script>'),
|
||||
('''><script>alert(302);</script>'),
|
||||
('<script>alert(303);</script>'),
|
||||
('''; eval(''alert(304)'');');
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `evil_table_comment`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `evil_table_comment` (
|
||||
`id` int(1) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='"><script>alert(400);</script>';
|
||||
|
||||
|
||||
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
16
#pma/test/test_data/phpmyadmin.mediawiki
Normal file
16
#pma/test/test_data/phpmyadmin.mediawiki
Normal file
@ -0,0 +1,16 @@
|
||||
|
||||
<!--
|
||||
Table data for `pma_bookmarktest`
|
||||
-->
|
||||
|
||||
{| class="wikitable sortable" style="text-align:center;"
|
||||
! table header
|
||||
|+'''pma_bookmarktest'''
|
||||
|-
|
||||
| 1
|
||||
| dbbase
|
||||
|
|
||||
| ddd
|
||||
| SELECT * FROM `db_content` WHERE 1
|
||||
|}
|
||||
|
45
#pma/test/test_data/phpmyadmin_importXML_For_Testing.xml
Normal file
45
#pma/test/test_data/phpmyadmin_importXML_For_Testing.xml
Normal file
@ -0,0 +1,45 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<!--
|
||||
- phpMyAdmin XML Dump FOR testing
|
||||
- version 4.1-dev
|
||||
- https://www.phpmyadmin.net
|
||||
-
|
||||
- Host: 127.0.0.1
|
||||
- Generation Time: Jun 15, 2013 at 02:59 PM
|
||||
- Server version: 5.5.27-log
|
||||
- PHP Version: 5.4.7
|
||||
-->
|
||||
|
||||
<pma_xml_export version="1.0" xmlns:pma="https://www.phpmyadmin.net/some_doc_url/">
|
||||
<!--
|
||||
- Structure schemas
|
||||
-->
|
||||
<pma:structure_schemas>
|
||||
<pma:database name="phpmyadmintest" collation="utf8_bin" charset="utf8">
|
||||
<pma:table name="pma_bookmarktest">
|
||||
CREATE TABLE `pma_bookmarktest` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`dbase` varchar(255) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`user` varchar(255) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`label` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`query` text COLLATE utf8_bin NOT NULL,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM AUTO_INCREMENT=2 DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Bookmarks';
|
||||
</pma:table>
|
||||
</pma:database>
|
||||
</pma:structure_schemas>
|
||||
|
||||
<!--
|
||||
- Database: 'phpmyadmintest'
|
||||
-->
|
||||
<database name="phpmyadmintest">
|
||||
<!-- Table pma_bookmarktest -->
|
||||
<table name="pma_bookmarktest">
|
||||
<column name="id">1</column>
|
||||
<column name="dbase">pma_dbase</column>
|
||||
<column name="user"></column>
|
||||
<column name="label">pma_label</column>
|
||||
<column name="query">SELECT * FROM `db_content` WHERE 1</column>
|
||||
</table>
|
||||
</database>
|
||||
</pma_xml_export>
|
49
#pma/test/test_data/pma_bookmark.sql
Normal file
49
#pma/test/test_data/pma_bookmark.sql
Normal file
@ -0,0 +1,49 @@
|
||||
-- phpMyAdmin SQL Dump
|
||||
-- version 4.1-dev
|
||||
-- https://www.phpmyadmin.net
|
||||
--
|
||||
-- Host: 127.0.0.1
|
||||
-- Generation Time: Jun 25, 2013 at 05:44 PM
|
||||
-- Server version: 5.5.27-log
|
||||
-- PHP Version: 5.4.7
|
||||
|
||||
SET SQL_MODE = "NO_AUTO_VALUE_ON_ZERO";
|
||||
SET time_zone = "+00:00";
|
||||
|
||||
|
||||
/*!40101 SET @OLD_CHARACTER_SET_CLIENT=@@CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET @OLD_CHARACTER_SET_RESULTS=@@CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET @OLD_COLLATION_CONNECTION=@@COLLATION_CONNECTION */;
|
||||
/*!40101 SET NAMES utf8 */;
|
||||
|
||||
--
|
||||
-- Database: `db_test`
|
||||
--
|
||||
CREATE DATABASE IF NOT EXISTS `db_test` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
|
||||
USE `db_test`;
|
||||
|
||||
-- --------------------------------------------------------
|
||||
|
||||
--
|
||||
-- Table structure for table `pma_bookmark`
|
||||
--
|
||||
|
||||
CREATE TABLE IF NOT EXISTS `pma_bookmark` (
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`dbase` varchar(255) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`user` varchar(255) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`label` varchar(255) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`query` text COLLATE utf8_bin NOT NULL,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Bookmarks' AUTO_INCREMENT=2 ;
|
||||
|
||||
--
|
||||
-- Dumping data for table `pma_bookmark`
|
||||
--
|
||||
|
||||
INSERT INTO `pma_bookmark` (`id`, `dbase`, `user`, `label`, `query`) VALUES
|
||||
(1, 'dbbase', '', 'ddd', 0x53454c454354202a2046524f4d206064625f636f6e74656e74602057484552452031);
|
||||
|
||||
/*!40101 SET CHARACTER_SET_CLIENT=@OLD_CHARACTER_SET_CLIENT */;
|
||||
/*!40101 SET CHARACTER_SET_RESULTS=@OLD_CHARACTER_SET_RESULTS */;
|
||||
/*!40101 SET COLLATION_CONNECTION=@OLD_COLLATION_CONNECTION */;
|
9
#pma/test/test_data/server_import.sql
Normal file
9
#pma/test/test_data/server_import.sql
Normal file
@ -0,0 +1,9 @@
|
||||
--
|
||||
-- Database: `test_import1`
|
||||
--
|
||||
CREATE DATABASE IF NOT EXISTS `test_import1` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
|
||||
--
|
||||
-- Database: `test_import1`
|
||||
--
|
||||
CREATE DATABASE IF NOT EXISTS `test_import2` DEFAULT CHARACTER SET latin1 COLLATE latin1_swedish_ci;
|
||||
|
9
#pma/test/test_data/table_import.sql
Normal file
9
#pma/test/test_data/table_import.sql
Normal file
@ -0,0 +1,9 @@
|
||||
|
||||
--
|
||||
-- Dumping data for table `test_table`
|
||||
--
|
||||
|
||||
INSERT INTO `test_table` (`val`) VALUES
|
||||
(8),
|
||||
(9);
|
||||
|
BIN
#pma/test/test_data/test.bz2
Normal file
BIN
#pma/test/test_data/test.bz2
Normal file
Binary file not shown.
1
#pma/test/test_data/test.file
Normal file
1
#pma/test/test_data/test.file
Normal file
@ -0,0 +1 @@
|
||||
TEST FILE
|
BIN
#pma/test/test_data/test.gz
Normal file
BIN
#pma/test/test_data/test.gz
Normal file
Binary file not shown.
BIN
#pma/test/test_data/test.zip
Normal file
BIN
#pma/test/test_data/test.zip
Normal file
Binary file not shown.
BIN
#pma/test/test_data/timezone.shp.zip
Normal file
BIN
#pma/test/test_data/timezone.shp.zip
Normal file
Binary file not shown.
Reference in New Issue
Block a user