[OT]Ich wette Du verstehst mich sicher im Moment am besten, warum ich auch manchmal entnervt reinkomme, wenn etwas, was normal "selbstverständlich funktionieren sollte" nicht geht. - Hörst Dich jedenfalls auch gereizt an
[/OT]
Hab nun dieses in der MySql drinnen ...
|
Quellcode
|
1
2
3
4
|
information_schema
mysql
phpmyadmin
test
|
Für die phpmyadmin datenbank habe ich einen pma user erstellt und ihm die rechte für die Datenbank gegeben. Klappt trotzdem nicht
Schattenschlag, das dort in mysql die Testuser noch drin sind, sagt, das Du Dein MySQL noch nicht secured hast. Diese Testzugänge sollten entfernt werden, weil sie MySQL-Zugang OHNE JEGLICHES PW ermöglichen! Bei einer lokalen Installation ist das nicht so tragisch - Bei einem Produktionsserver kann es sehr schnell sehr tödlich sein.
Das "Securen" von MySQL erfolgt so:
|
Quellcode
|
1
2
|
/etc/init.d/mysql start
/usr/bin/mysql_secure_installation
|
Dann folgen eine Reihe von Fragen: Beispiel: Erreichbarkeit von Außen... usw. (Verneinen, es sei denn, Du willst, DEINE MySQL-Installation von anderen Hosts erreichbar wird - nicht zu empfehlen) / Entfernung der Testzugänge.../ - Ausserdem wird ein root-Pass vergeben. Dieses hat jedoch nichts mit dem Linux-root Deines Systems zu tun!
Übrigens, hier mal eine Reihe von Use-Flags, die php haben sollte:
|
Quellcode
|
1
|
dev-lang/php apache2 cdb cgi curl curlwrappers ftp fpm (wenn systemd, dann MUSS fpm gesetzt sein) gd gmp imap inifile intl mysql mysqli pdo sockets threads wddx xmlreader xmlrpc xmlwriter xpm zip
|
Viele erklären sich von selbst... - pdo - beispielsweise, ist wichtig für gewisse Webapps (ein Beispiel das Content-Management-System ModX) gd (Captcha-Funktionen) sockets (Um per socket verbinden zu können, statt tcp) usw...
BlowFish-Secret:
BlowFish ist für die Cookie-Auth von phpmyadmin per Webbrowser. Damit man Dir nicht die Session stiehlt Da kannst Du ein von Dir gewähltes PW eintragen, dann wird damit das Cookie verschlüsselt. Eingeben musst Du das nirgends, später. Empfehlenswerter (vor allem bei Serverbetrieben) ist http-auth. Das ist .htaccess-basiert.
Übrigens, die Config (config.inc.php) phpmyadmin's gibt die Möglichkeit, Passwörter zu speichern. Es ist eine beschissene Idee... Also auskommentieren.
Meine lokale phpmyadmin-config.inc.php sieht derzeit so aus:
|
Quellcode
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
|
<?php
/* vim: set expandtab sw=4 ts=4 sts=4: */
/**
* phpMyAdmin sample configuration, you can use it as base for
* manual configuration. For easier setup you can use setup/
*
* All directives are explained in Documentation.html and on phpMyAdmin
* wiki <http://wiki.phpmyadmin.net>.
*
* @package PhpMyAdmin
*/
/*
* This is needed for cookie based authentication to encrypt password in
* cookie
*/
$cfg['blowfish_secret'] = 'mein_cookie_auth_pass'; /* YOU MUST FILL IN THIS FOR COOKIE AUTH! */
/*
* Servers configuration
*/
$i = 0;
/*
* First server
*/
$i++;
/* Authentication type */
$cfg['Servers'][$i]['auth_type'] = 'cookie'; <- wenn Du http-auth verwendest, brauchst kein blowfish-pass weiter oben!
/* Server parameters */
$cfg['Servers'][$i]['host'] = 'localhost';
$cfg['Servers'][$i]['connect_type'] = 'tcp';
$cfg['Servers'][$i]['compress'] = false;
/* Select mysql if your server does not have mysqli */
$cfg['Servers'][$i]['extension'] = 'mysqli';
$cfg['Servers'][$i]['AllowNoPassword'] = false;
/*
* phpMyAdmin configuration storage settings.
*/
/* User used to manipulate with storage */
// $cfg['Servers'][$i]['controlhost'] = '';
// $cfg['Servers'][$i]['controluser'] = 'pma';
// $cfg['Servers'][$i]['controlpass'] = 'pmapass';
/* Storage database and tables */
$cfg['Servers'][$i]['pmadb'] = 'phpmyadmin';
$cfg['Servers'][$i]['bookmarktable'] = 'pma_bookmark';
$cfg['Servers'][$i]['relation'] = 'pma_relation';
$cfg['Servers'][$i]['table_info'] = 'pma_table_info';
$cfg['Servers'][$i]['table_coords'] = 'pma_table_coords';
$cfg['Servers'][$i]['pdf_pages'] = 'pma_pdf_pages';
$cfg['Servers'][$i]['column_info'] = 'pma_column_info';
$cfg['Servers'][$i]['history'] = 'pma_history';
$cfg['Servers'][$i]['table_uiprefs'] = 'pma_table_uiprefs';
$cfg['Servers'][$i]['tracking'] = 'pma_tracking';
$cfg['Servers'][$i]['designer_coords'] = 'pma_designer_coords';
$cfg['Servers'][$i]['userconfig'] = 'pma_userconfig';
$cfg['Servers'][$i]['recent'] = 'pma_recent';
/* Contrib / Swekey authentication */
// $cfg['Servers'][$i]['auth_swekey_config'] = '/etc/swekey-pma.conf';
/*
* End of servers configuration
*/
/*
* Directories for saving/loading files from server
*/
$cfg['UploadDir'] = '';
$cfg['SaveDir'] = '';
/**
* Defines whether a user should be displayed a "show all (records)"
* button in browse mode or not.
* default = false
*/
//$cfg['ShowAll'] = true;
/**
* Number of rows displayed when browsing a result set. If the result
* set contains more rows, "Previous" and "Next".
* default = 30
*/
//$cfg['MaxRows'] = 50;
/**
* Use graphically less intense menu tabs
* default = false
*/
//$cfg['LightTabs'] = true;
/**
* disallow editing of binary fields
* valid values are:
* false allow editing
* 'blob' allow editing except for BLOB fields
* 'all' disallow editing
* default = blob
*/
//$cfg['ProtectBinary'] = 'false';
/**
* Default language to use, if not browser-defined or user-defined
* (you find all languages in the locale folder)
* uncomment the desired line:
* default = 'en'
*/
//$cfg['DefaultLang'] = 'en';
//$cfg['DefaultLang'] = 'de';
/**
* default display direction (horizontal|vertical|horizontalflipped)
*/
//$cfg['DefaultDisplay'] = 'vertical';
/**
* How many columns should be used for table display of a database?
* (a value larger than 1 results in some information being hidden)
* default = 1
*/
//$cfg['PropertiesNumColumns'] = 2;
/**
* Set to true if you want DB-based query history.If false, this utilizes
* JS-routines to display query history (lost by window close)
*
* This requires configuration storage enabled, see above.
* default = false
*/
//$cfg['QueryHistoryDB'] = true;
/**
* When using DB-based query history, how many entries should be kept?
*
* default = 25
*/
//$cfg['QueryHistoryMax'] = 100;
/*
* You can find more configuration options in Documentation.html
* or here: http://wiki.phpmyadmin.net/pma/Config
*/
?>
|
Hab mir gerade eine Orig-Config angesehen, also eine unveränderte: Dort sind die Positionen:
$cfg['Servers'][$i]['pmadb'] = 'phpmyadmin';
$cfg['Servers'][$i]['bookmarktable'] = 'pma_bookmark';
$cfg['Servers'][$i]['relation'] = 'pma_relation';
$cfg['Servers'][$i]['table_info'] = 'pma_table_info';
$cfg['Servers'][$i]['table_coords'] = 'pma_table_coords';
$cfg['Servers'][$i]['pdf_pages'] = 'pma_pdf_pages';
$cfg['Servers'][$i]['column_info'] = 'pma_column_info';
$cfg['Servers'][$i]['history'] = 'pma_history';
$cfg['Servers'][$i]['table_uiprefs'] = 'pma_table_uiprefs';
$cfg['Servers'][$i]['tracking'] = 'pma_tracking';
$cfg['Servers'][$i]['designer_coords'] = 'pma_designer_coords';
$cfg['Servers'][$i]['userconfig'] = 'pma_userconfig';
$cfg['Servers'][$i]['recent'] = 'pma_recent';
kommentiert. Nachdem durch das Script "create_tables" (was Du gestern ausgeführt hast) die Tables erstellt wurden, muss man die auskommentieren. Damit phpmyadmin weiß, das es die Tables nun gibt. Sorry das ich gestern einen falschen Namen des Scripts nannte, ich war nicht zuhause und hatte leider keine Möglichkeit nachzusehen, wie sich das Script genaustens nennt. Ich war der Meinung, es liege in Scripts. Möglich das ich das mit Postfixadmin verwechselt habe.
Kleiner Nachtrag:
Das mit dem mysqli habe ich auch geschafft .. hatte mich in der make.conf verschrieben .... läuft nun auch fehlerlos
In die make.conf kommt nur dies hier:
|
Quellcode
|
1
2
|
PHP_TARGETS="php5-5"
PHP_INI_VERSION="production"
|
und als USE:
|
Quellcode
|
1
|
USE="... ... ... apache mysql php"
|