6a4168cfefe9718cacebf052bc6c4b16eefc231e
[ach-master.git] / src / practical_settings / DBs.tex
1 %%\subsection{Database Systems}
2 % This list is based on : http://en.wikipedia.org/wiki/Relational_database_management_system#Market_share
3
4 \subsubsection{Oracle}
5 \todo{write this}
6
7 \subsubsection{SQL Server}
8 \todo{write this}
9
10
11
12
13 \subsubsection{MySQL}
14
15 \begin{description}
16 \item[Tested with Version:] Debian 7.0 and MySQL 5.5
17
18 \item[Settings:] \mbox{}
19
20 \paragraph*{my.cnf}\mbox{}\\
21
22 \begin{lstlisting}[breaklines]
23 [mysqld]
24 ssl
25 ssl-ca=/etc/mysql/ssl/ca-cert.pem
26 ssl-cert=/etc/mysql/ssl/server-cert.pem
27 ssl-key=/etc/mysql/ssl/server-key.pem
28 ssl-cipher=EECDH+aRSA+AESGCM:EECDH+aRSA+SHA384:EECDH+aRSA+SHA256:EDH+CAMELLIA256:EECDH:EDH+aRSA:+SSLv3:!aNULL:!eNULL:!LOW:!3DES:!MD5:!EXP:!PSK:!SRP:!DSS:!RC4:!SEED:!AES128:!CAMELLIA128:!ECDSA:AES256-SHA
29 \end{lstlisting}
30
31 \item[Additional settings:]
32
33
34 \item[Justification for special settings (if needed):]
35
36 % in case you have the need for further justifications why you chose this and that setting or if the settings do not fit into the standard Variant A or Variant B schema, please document this here
37
38 \item[References:]
39 +{\small \url{https://dev.mysql.com/doc/refman/5.5/en/ssl-connections.html}}
40
41
42 % add any further references or best practice documents here
43
44 \item[How to test:]
45
46 After restarting the server run the following query to see if the ssl settings are correct:
47 \begin{lstlisting}[breaklines]
48 show variables like '%ssl%';
49 \end{lstlisting}
50
51
52 \end{description}
53
54
55
56
57
58
59 \subsubsection{DB2}
60 \todo{write this}
61
62
63
64
65
66 \subsubsection{Postgresql}
67
68 \begin{description}
69 \item[Tested with Version:] Debian 7.0 and PostgreSQL 9.1
70
71 \item[References:]
72
73 It's recommended to read 
74
75 {\small \url{http://www.postgresql.org/docs/current/static/runtime-config-connection.html#RUNTIME-CONFIG-CONNECTION-SECURITY}}
76 {\small \url{http://www.postgresql.org/docs/current/static/ssl-tcp.html}}
77 {\small \url{http://www.postgresql.org/docs/current/static/auth-pg-hba-conf.html}}
78
79 \item[Settings:] \mbox{}
80
81
82 To start in SSL mode the server.crt and server.key must exist in the server's data directory \$PGDATA. 
83
84 Starting with version 9.2, you have the possibility to set the path.
85
86 \begin{lstlisting}[breaklines]
87 ssl_key_file = '/your/path/server.key'
88 ssl_cert_file = '/your/path/server.crt'
89 ssl_ca_file = '/your/path/root.crt'
90 \end{lstlisting}
91
92 \paragraph*{postgresql.conf}\mbox{}\\
93
94 \begin{lstlisting}[breaklines]
95 #>=8.3
96 ssl = on 
97 ssl_ciphers = 'EECDH+aRSA+AESGCM:EECDH+aRSA+SHA384:EECDH+aRSA+SHA256:EDH+CAMELLIA256:EECDH:EDH+aRSA:+SSLv3:!aNULL:!eNULL:!LOW:!3DES:!MD5:!EXP:!PSK:!SRP:!DSS:!RC4:!SEED:!AES128:!CAMELLIA128:!ECDSA:AES256-SHA'
98 \end{lstlisting}
99
100
101
102 \item[How to test:]
103 To test your ssl settings, run psql with the sslmode parameter:
104 \begin{lstlisting}[breaklines]
105 psql "sslmode=require host=postgres-server dbname=database" your-username
106 \end{lstlisting}
107
108 \end{description}
109
110
111
112
113 \subsubsection{Informix}
114 \todo{write this}