Linux ns1.utparral.edu.mx 6.8.0-79-generic #79~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Fri Aug 15 16:54:53 UTC 2 x86_64
Apache/2.4.58 (Unix) OpenSSL/1.1.1w PHP/8.2.12 mod_perl/2.0.12 Perl/v5.34.1
: 10.10.1.9 | : 10.10.1.254
Cant Read [ /etc/named.conf ]
daemon
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
README
+ Create Folder
+ Create File
/
opt /
lampp /
htdocs /
phpMyAdmin /
libraries /
[ HOME SHELL ]
Name
Size
Permission
Action
certs
[ DIR ]
drwxrwxr-x
config
[ DIR ]
drwxrwxr-x
controllers
[ DIR ]
drwxrwxr-x
dbi
[ DIR ]
drwxrwxr-x
di
[ DIR ]
drwxrwxr-x
engines
[ DIR ]
drwxrwxr-x
gis
[ DIR ]
drwxrwxr-x
navigation
[ DIR ]
drwxrwxr-x
plugins
[ DIR ]
drwxrwxr-x
properties
[ DIR ]
drwxrwxr-x
rte
[ DIR ]
drwxrwxr-x
.1724597954
0
B
-rwxrwxr-x
.1724621370
0
B
-rwxrwxr-x
.1724621595
0
B
-rwxrwxr-x
.1724693108
0
B
-rwxrwxr-x
.1724693161
0
B
-rwxrwxr-x
.1724693163
0
B
-rwxrwxr-x
.1724716554
0
B
-rwxrwxr-x
.1724716619
0
B
-rwxrwxr-x
.1724995546
0
B
-rwxrwxr-x
.1725018452
0
B
-rwxrwxr-x
.1725018571
0
B
-rwxrwxr-x
.1725018746
0
B
-rwxrwxr-x
.1725030833
0
B
-rwxrwxr-x
.1725030838
0
B
-rwxrwxr-x
.1725030897
0
B
-rwxrwxr-x
.1725030901
0
B
-rwxrwxr-x
advisor.lib.php
1.58
KB
-rwxrwxr-x
Advisor.php
16.32
KB
-rwxrwxr-x
advisory_rules.txt
25.94
KB
-rwxrwxr-x
Bookmark.php
9.76
KB
-rwxrwxr-x
browse_foreigners.lib.php
9.63
KB
-rwxrwxr-x
central_columns.lib.php
49.24
KB
-rwxrwxr-x
Charsets.php
22.67
KB
-rwxrwxr-x
check_user_privileges.lib.php
11
KB
-rwxrwxr-x
common.inc.php
29.21
KB
-rwxrwxr-x
config.default.php
65.5
KB
-rwxrwxr-x
Config.php
55.12
KB
-rwxrwxr-x
config.values.php
10.24
KB
-rwxrwxr-x
Console.php
3.38
KB
-rwxrwxr-x
core.lib.php
29.45
KB
-rwxrwxr-x
create_addfield.lib.php
15.7
KB
-rwxrwxr-x
database_interface.inc.php
2.63
KB
-rwxrwxr-x
DatabaseInterface.php
95.6
KB
-rwxrwxr-x
db_common.inc.php
3.04
KB
-rwxrwxr-x
db_designer.lib.php
10.77
KB
-rwxrwxr-x
DbList.php
1.91
KB
-rwxrwxr-x
DbQbe.php
68.78
KB
-rwxrwxr-x
DbSearch.php
17.06
KB
-rwxrwxr-x
display_change_password.lib.php
6.15
KB
-rwxrwxr-x
display_create_table.lib.php
1.53
KB
-rwxrwxr-x
display_export.lib.php
35.53
KB
-rwxrwxr-x
display_git_revision.lib.php
2.88
KB
-rwxrwxr-x
display_import_ajax.lib.php
3.13
KB
-rwxrwxr-x
display_import.lib.php
24.38
KB
-rwxrwxr-x
DisplayResults.php
206.87
KB
-rwxrwxr-x
Encoding.php
8.93
KB
-rwxrwxr-x
ErrorHandler.php
16.41
KB
-rwxrwxr-x
error.inc.php
1.27
KB
-rwxrwxr-x
Error.php
12.87
KB
-rwxrwxr-x
error_report.lib.php
9.25
KB
-rwxrwxr-x
file_listing.lib.php
2.37
KB
-rwxrwxr-x
File.php
20.62
KB
-rwxrwxr-x
Font.php
4.24
KB
-rwxrwxr-x
Footer.php
10.29
KB
-rwxrwxr-x
Header.php
25.21
KB
-rwxrwxr-x
import.lib.php
49.9
KB
-rwxrwxr-x
inc.php
30.99
KB
-rwxrwxr-x
IndexColumn.php
4.46
KB
-rwxrwxr-x
index.lib.php
1.13
KB
-rwxrwxr-x
Index.php
23.38
KB
-rwxrwxr-x
information_schema_relations.lib.php
10.95
KB
-rwxrwxr-x
insert_edit.lib.php
112.42
KB
-rwxrwxr-x
ip_allow_deny.lib.php
8.09
KB
-rwxrwxr-x
LanguageManager.php
22.63
KB
-rwxrwxr-x
Language.php
4.21
KB
-rwxrwxr-x
language_stats.inc.php
1.5
KB
-rwxrwxr-x
Linter.php
5.09
KB
-rwxrwxr-x
ListAbstract.php
3.15
KB
-rwxrwxr-x
ListDatabase.php
4.63
KB
-rwxrwxr-x
Logging.php
1023
B
-rwxrwxr-x
Menu.php
21.36
KB
-rwxrwxr-x
Message.php
19.14
KB
-rwxrwxr-x
mime.lib.php
704
B
-rwxrwxr-x
mult_submits.inc.php
10.46
KB
-rwxrwxr-x
mult_submits.lib.php
20.45
KB
-rwxrwxr-x
normalization.lib.php
33.97
KB
-rwxrwxr-x
OpenDocument.php
8.52
KB
-rwxrwxr-x
operations.lib.php
71.3
KB
-rwxrwxr-x
OutputBuffering.php
3.59
KB
-rwxrwxr-x
parse_analyze.lib.php
2.18
KB
-rwxrwxr-x
Partition.php
9
KB
-rwxrwxr-x
PDF.php
3.92
KB
-rwxrwxr-x
plugin_interface.lib.php
19.69
KB
-rwxrwxr-x
pmd_common.php
24.1
KB
-rwxrwxr-x
RecentFavoriteTable.php
11.79
KB
-rwxrwxr-x
relation_cleanup.lib.php
13.84
KB
-rwxrwxr-x
relation.lib.php
68.74
KB
-rwxrwxr-x
replication_gui.lib.php
37.24
KB
-rwxrwxr-x
replication.inc.php
9.33
KB
-rwxrwxr-x
Response.php
12.05
KB
-rwxrwxr-x
Sanitize.php
14.1
KB
-rwxrwxr-x
SavedSearches.php
11.67
KB
-rwxrwxr-x
Scripts.php
6.59
KB
-rwxrwxr-x
select_server.lib.php
3.52
KB
-rwxrwxr-x
server_common.inc.php
1.24
KB
-rwxrwxr-x
server_common.lib.php
1.92
KB
-rwxrwxr-x
server_privileges.lib.php
171.6
KB
-rwxrwxr-x
server_status_advisor.lib.php
1.89
KB
-rwxrwxr-x
ServerStatusData.php
15.7
KB
-rwxrwxr-x
server_status.lib.php
9.84
KB
-rwxrwxr-x
server_status_monitor.lib.php
26.31
KB
-rwxrwxr-x
server_status_processes.lib.php
9.4
KB
-rwxrwxr-x
server_status_queries.lib.php
4.9
KB
-rwxrwxr-x
server_status_variables.lib.php
28.85
KB
-rwxrwxr-x
server_user_groups.lib.php
12.71
KB
-rwxrwxr-x
server_users.lib.php
1.32
KB
-rwxrwxr-x
session.lib.php
1.11
KB
-rwxrwxr-x
special_schema_links.lib.php
17.51
KB
-rwxrwxr-x
sql.lib.php
77.55
KB
-rwxrwxr-x
sql_query_form.lib.php
15.78
KB
-rwxrwxr-x
StorageEngine.php
13.51
KB
-rwxrwxr-x
string.lib.php
800
B
-rwxrwxr-x
stringMb.lib.php
1.85
KB
-rwxrwxr-x
stringNative.lib.php
6.82
KB
-rwxrwxr-x
SubPartition.php
3.52
KB
-rwxrwxr-x
sysinfo.lib.php
1.35
KB
-rwxrwxr-x
SysInfoLinux.php
1.92
KB
-rwxrwxr-x
SysInfo.php
800
B
-rwxrwxr-x
SysInfoSunOS.php
1.86
KB
-rwxrwxr-x
SysInfoWINNT.php
3.08
KB
-rwxrwxr-x
SystemDatabase.php
3.66
KB
-rwxrwxr-x
Table.php
86.78
KB
-rwxrwxr-x
tbl_columns_definition_form.inc.php
13.84
KB
-rwxrwxr-x
tbl_common.inc.php
1.71
KB
-rwxrwxr-x
tbl_info.inc.php
3.54
KB
-rwxrwxr-x
Template.php
4.42
KB
-rwxrwxr-x
ThemeManager.php
12.25
KB
-rwxrwxr-x
Theme.php
12.68
KB
-rwxrwxr-x
Tracker.php
28.76
KB
-rwxrwxr-x
tracking.lib.php
54.52
KB
-rwxrwxr-x
tracking.php
393
B
-rwxrwxr-x
transformations.lib.php
14.62
KB
-rwxrwxr-x
TypesMySQL.php
17.26
KB
-rwxrwxr-x
Types.php
6.08
KB
-rwxrwxr-x
URL.php
8.42
KB
-rwxrwxr-x
user_preferences.inc.php
2.41
KB
-rwxrwxr-x
user_preferences.lib.php
8.28
KB
-rwxrwxr-x
util.lib.php
749
B
-rwxrwxr-x
Util.php
169.69
KB
-rwxrwxr-x
vendor_config.php
2.07
KB
-rwxrwxr-x
VersionInformation.php
6.34
KB
-rwxrwxr-x
zip_extension.lib.php
5.81
KB
-rwxrwxr-x
ZipFile.php
6.63
KB
-rwxrwxr-x
Delete
Unzip
Zip
${this.title}
Close
Code Editor : DbSearch.php
<?php /* vim: set expandtab sw=4 ts=4 sts=4: */ /** * Handles Database Search * * @package PhpMyAdmin */ namespace PMA\libraries; use PMA\libraries\URL; use PMA\libraries\Sanitize; /** * Class to handle database search * * @package PhpMyAdmin */ class DbSearch { /** * Database name * * @access private * @var string */ private $_db; /** * Table Names * * @access private * @var array */ private $_tables_names_only; /** * Type of search * * @access private * @var array */ private $_searchTypes; /** * Already set search type * * @access private * @var integer */ private $_criteriaSearchType; /** * Already set search type's description * * @access private * @var string */ private $_searchTypeDescription; /** * Search string/regexp * * @access private * @var string */ private $_criteriaSearchString; /** * Criteria Tables to search in * * @access private * @var array */ private $_criteriaTables; /** * Restrict the search to this column * * @access private * @var string */ private $_criteriaColumnName; /** * Public Constructor * * @param string $db Database name */ public function __construct($db) { $this->_db = $db; // Sets criteria parameters $this->_setSearchParams(); } /** * Sets search parameters * * @return void */ private function _setSearchParams() { $this->_tables_names_only = $GLOBALS['dbi']->getTables($this->_db); $this->_searchTypes = array( '1' => __('at least one of the words'), '2' => __('all words'), '3' => __('the exact phrase'), '4' => __('as regular expression'), ); if (empty($_REQUEST['criteriaSearchType']) || ! is_string($_REQUEST['criteriaSearchType']) || ! array_key_exists( $_REQUEST['criteriaSearchType'], $this->_searchTypes ) ) { $this->_criteriaSearchType = 1; unset($_REQUEST['submit_search']); } else { $this->_criteriaSearchType = (int) $_REQUEST['criteriaSearchType']; $this->_searchTypeDescription = $this->_searchTypes[$_REQUEST['criteriaSearchType']]; } if (empty($_REQUEST['criteriaSearchString']) || ! is_string($_REQUEST['criteriaSearchString']) ) { $this->_criteriaSearchString = ''; unset($_REQUEST['submit_search']); } else { $this->_criteriaSearchString = $_REQUEST['criteriaSearchString']; } $this->_criteriaTables = array(); if (empty($_REQUEST['criteriaTables']) || ! is_array($_REQUEST['criteriaTables']) ) { unset($_REQUEST['submit_search']); } else { $this->_criteriaTables = array_intersect( $_REQUEST['criteriaTables'], $this->_tables_names_only ); } if (empty($_REQUEST['criteriaColumnName']) || ! is_string($_REQUEST['criteriaColumnName']) ) { unset($this->_criteriaColumnName); } else { $this->_criteriaColumnName = $GLOBALS['dbi']->escapeString( $_REQUEST['criteriaColumnName'] ); } } /** * Builds the SQL search query * * @param string $table The table name * * @return array 3 SQL queries (for count, display and delete results) * * @todo can we make use of fulltextsearch IN BOOLEAN MODE for this? * PMA_backquote * DatabaseInterface::freeResult * DatabaseInterface::fetchAssoc * $GLOBALS['db'] * explode * count * strlen */ private function _getSearchSqls($table) { // Statement types $sqlstr_select = 'SELECT'; $sqlstr_delete = 'DELETE'; // Table to use $sqlstr_from = ' FROM ' . Util::backquote($GLOBALS['db']) . '.' . Util::backquote($table); // Gets where clause for the query $where_clause = $this->_getWhereClause($table); // Builds complete queries $sql = array(); $sql['select_columns'] = $sqlstr_select . ' * ' . $sqlstr_from . $where_clause; // here, I think we need to still use the COUNT clause, even for // VIEWs, anyway we have a WHERE clause that should limit results $sql['select_count'] = $sqlstr_select . ' COUNT(*) AS `count`' . $sqlstr_from . $where_clause; $sql['delete'] = $sqlstr_delete . $sqlstr_from . $where_clause; return $sql; } /** * Provides where clause for building SQL query * * @param string $table The table name * * @return string The generated where clause */ private function _getWhereClause($table) { // Columns to select $allColumns = $GLOBALS['dbi']->getColumns($GLOBALS['db'], $table); $likeClauses = array(); // Based on search type, decide like/regex & '%'/'' $like_or_regex = (($this->_criteriaSearchType == 4) ? 'REGEXP' : 'LIKE'); $automatic_wildcard = (($this->_criteriaSearchType < 3) ? '%' : ''); // For "as regular expression" (search option 4), LIKE won't be used // Usage example: If user is searching for a literal $ in a regexp search, // he should enter \$ as the value. $criteriaSearchStringEscaped = $GLOBALS['dbi']->escapeString( $this->_criteriaSearchString ); // Extract search words or pattern $search_words = (($this->_criteriaSearchType > 2) ? array($criteriaSearchStringEscaped) : explode(' ', $criteriaSearchStringEscaped)); foreach ($search_words as $search_word) { // Eliminates empty values if (strlen($search_word) === 0) { continue; } $likeClausesPerColumn = array(); // for each column in the table foreach ($allColumns as $column) { if (! isset($this->_criteriaColumnName) || strlen($this->_criteriaColumnName) === 0 || $column['Field'] == $this->_criteriaColumnName ) { $column = 'CONVERT(' . Util::backquote($column['Field']) . ' USING utf8)'; $likeClausesPerColumn[] = $column . ' ' . $like_or_regex . ' ' . "'" . $automatic_wildcard . $search_word . $automatic_wildcard . "'"; } } // end for if (count($likeClausesPerColumn) > 0) { $likeClauses[] = implode(' OR ', $likeClausesPerColumn); } } // end for // Use 'OR' if 'at least one word' is to be searched, else use 'AND' $implode_str = ($this->_criteriaSearchType == 1 ? ' OR ' : ' AND '); if (empty($likeClauses)) { // this could happen when the "inside column" does not exist // in any selected tables $where_clause = ' WHERE FALSE'; } else { $where_clause = ' WHERE (' . implode(') ' . $implode_str . ' (', $likeClauses) . ')'; } return $where_clause; } /** * Displays database search results * * @return string HTML for search results */ public function getSearchResults() { $html_output = ''; // Displays search string $html_output .= '<br />' . '<table class="data">' . '<caption class="tblHeaders">' . sprintf( __('Search results for "<i>%s</i>" %s:'), htmlspecialchars($this->_criteriaSearchString), $this->_searchTypeDescription ) . '</caption>'; $num_search_result_total = 0; // For each table selected as search criteria foreach ($this->_criteriaTables as $each_table) { // Gets the SQL statements $newsearchsqls = $this->_getSearchSqls($each_table); // Executes the "COUNT" statement $res_cnt = intval($GLOBALS['dbi']->fetchValue($newsearchsqls['select_count'])); $num_search_result_total += $res_cnt; // Gets the result row's HTML for a table $html_output .= $this->_getResultsRow( $each_table, $newsearchsqls, $res_cnt ); } // end for $html_output .= '</table>'; // Displays total number of matches if (count($this->_criteriaTables) > 1) { $html_output .= '<p>'; $html_output .= sprintf( _ngettext( '<b>Total:</b> <i>%s</i> match', '<b>Total:</b> <i>%s</i> matches', $num_search_result_total ), $num_search_result_total ); $html_output .= '</p>'; } return $html_output; } /** * Provides search results row with browse/delete links. * (for a table) * * @param string $each_table One of the tables on which search was performed * @param array $newsearchsqls Contains SQL queries * @param integer $res_cnt Number of results found * * @return string HTML row */ private function _getResultsRow($each_table, $newsearchsqls, $res_cnt) { $this_url_params = array( 'db' => $GLOBALS['db'], 'table' => $each_table, 'goto' => 'db_sql.php', 'pos' => 0, 'is_js_confirmed' => 0, ); // Start forming search results row $html_output = '<tr class="noclick">'; // Displays results count for a table $html_output .= '<td>'; $html_output .= sprintf( _ngettext( '%1$s match in <strong>%2$s</strong>', '%1$s matches in <strong>%2$s</strong>', $res_cnt ), $res_cnt, htmlspecialchars($each_table) ); $html_output .= '</td>'; // Displays browse/delete link if result count > 0 if ($res_cnt > 0) { $this_url_params['db'] = htmlspecialchars($GLOBALS['db']); $this_url_params['table'] = htmlspecialchars($each_table); $browse_result_path = 'sql.php' . URL::getCommon($this_url_params); $html_output .= '<td><a name="browse_search" ' . ' class="ajax browse_results" href="' . $browse_result_path . '" ' . 'data-browse-sql="' . htmlspecialchars($newsearchsqls['select_columns']). '" ' . 'data-table-name="' . htmlspecialchars($each_table) . '" >' . __('Browse') . '</a></td>'; $delete_result_path = $browse_result_path; $html_output .= '<td><a name="delete_search" class="ajax delete_results"' . ' href="' . $delete_result_path . '"' . ' data-delete-sql="' . htmlspecialchars($newsearchsqls['delete']) . '"' . ' data-table-name="' . htmlspecialchars($each_table) . '" >' . __('Delete') . '</a></td>'; } else { $html_output .= '<td> </td>' . '<td> </td>'; }// end if else $html_output .= '</tr>'; return $html_output; } /** * Provides the main search form's html * * @return string HTML for selection form */ public function getSelectionForm() { $html_output = '<a id="db_search"></a>'; $html_output .= '<form id="db_search_form"' . ' class="ajax lock-page"' . ' method="post" action="db_search.php" name="db_search">'; $html_output .= URL::getHiddenInputs($GLOBALS['db']); $html_output .= '<fieldset>'; // set legend caption $html_output .= '<legend>' . __('Search in database') . '</legend>'; $html_output .= '<table class="formlayout">'; // inputbox for search phrase $html_output .= '<tr>'; $html_output .= '<td>' . __('Words or values to search for (wildcard: "%"):') . '</td>'; $html_output .= '<td><input type="text"' . ' name="criteriaSearchString" size="60"' . ' value="' . htmlspecialchars($this->_criteriaSearchString) . '" />'; $html_output .= '</td>'; $html_output .= '</tr>'; // choices for types of search $html_output .= '<tr>'; $html_output .= '<td class="right vtop">' . __('Find:') . '</td>'; $html_output .= '<td>'; $choices = array( '1' => __('at least one of the words') . Util::showHint( __('Words are separated by a space character (" ").') ), '2' => __('all words') . Util::showHint( __('Words are separated by a space character (" ").') ), '3' => __('the exact phrase'), '4' => __('as regular expression') . ' ' . Util::showMySQLDocu('Regexp') ); // 4th parameter set to true to add line breaks // 5th parameter set to false to avoid htmlspecialchars() escaping // in the label since we have some HTML in some labels $html_output .= Util::getRadioFields( 'criteriaSearchType', $choices, $this->_criteriaSearchType, true, false ); $html_output .= '</td></tr>'; // displays table names as select options $html_output .= '<tr>'; $html_output .= '<td class="right vtop">' . __('Inside tables:') . '</td>'; $html_output .= '<td rowspan="2">'; $html_output .= '<select name="criteriaTables[]" size="6"' . ' multiple="multiple">'; foreach ($this->_tables_names_only as $each_table) { if (in_array($each_table, $this->_criteriaTables)) { $is_selected = ' selected="selected"'; } else { $is_selected = ''; } $html_output .= '<option value="' . htmlspecialchars($each_table) . '"' . $is_selected . '>' . str_replace(' ', ' ', htmlspecialchars($each_table)) . '</option>'; } // end for $html_output .= '</select>'; $html_output .= '</td></tr>'; // Displays 'select all' and 'unselect all' links $alter_select = '<a href="#" ' . 'onclick="setSelectOptions(\'db_search\',' . ' \'criteriaTables[]\', true); return false;">' . __('Select all') . '</a> / '; $alter_select .= '<a href="#" ' . 'onclick="setSelectOptions(\'db_search\',' . ' \'criteriaTables[]\', false); return false;">' . __('Unselect all') . '</a>'; $html_output .= '<tr><td class="right vbottom">' . $alter_select . '</td></tr>'; // Inputbox for column name entry $html_output .= '<tr>'; $html_output .= '<td class="right">' . __('Inside column:') . '</td>'; $html_output .= '<td><input type="text" name="criteriaColumnName" size="60"' . 'value="' . (! empty($this->_criteriaColumnName) ? htmlspecialchars($this->_criteriaColumnName) : '') . '" /></td>'; $html_output .= '</tr>'; $html_output .= '</table>'; $html_output .= '</fieldset>'; $html_output .= '<fieldset class="tblFooters">'; $html_output .= '<input type="submit" name="submit_search" value="' . __('Go') . '" id="buttonGo" />'; $html_output .= '</fieldset>'; $html_output .= '</form>'; $html_output .= '<div id="togglesearchformdiv">' . '<a id="togglesearchformlink"></a></div>'; return $html_output; } /** * Provides div tags for browsing search results and sql query form. * * @return string div tags */ public function getResultDivs() { $html_output = '<!-- These two table-image and table-link elements display' . ' the table name in browse search results -->'; $html_output .= '<div id="table-info">'; $html_output .= '<a class="item" id="table-link" ></a>'; $html_output .= '</div>'; // div for browsing results $html_output .= '<div id="browse-results">'; $html_output .= '<!-- this browse-results div is used to load the browse' . ' and delete results in the db search -->'; $html_output .= '</div>'; $html_output .= '<br class="clearfloat" />'; $html_output .= '<div id="sqlqueryform">'; $html_output .= '<!-- this sqlqueryform div is used to load the delete' . ' form in the db search -->'; $html_output .= '</div>'; $html_output .= '<!-- toggle query box link-->'; $html_output .= '<a id="togglequerybox"></a>'; return $html_output; } }
Close