summaryrefslogtreecommitdiff
path: root/docs/systems/bugs.rst
blob: f815ae57e02807daf245cde0313c894d032874f9 (plain)
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
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
.. index::
   single: Systems; Bugs

====
Bugs
====

Purpose
=======

This system provides the public bug tracker for the CAcert community.

.. note:: There currently seems to be a problem for users signing up themselves
   for new accounts. Unless this is fixed by Debian, new accounts must be
   created by administrators. For more details ask the `support mailing list
   <cacert-support@lists.cacert.org>`_.

Application Links
-----------------

Bugtracker
   https://bugs.cacert.org/

Administration
==============

System Administration
---------------------

* Primary: :ref:`people_neo`
* Secondary: :ref:`people_jandd`

Application Administration
--------------------------

+----------------------+--------------------------------------------+
| Application          | Administrator(s)                           |
+======================+============================================+
| Mantis Administrator | :ref:`people_benbe`, :ref:`people_neo`,    |
|                      | :ref:`people_dirk`, :ref:`people_jandd`,   |
|                      | :ref:`people_ted`, :ref:`people_mario`,    |
|                      | :ref:`people_philipp`                      |
+----------------------+--------------------------------------------+
| Mantis Manager       | :ref:`people_marcus`, :ref:`people_ulrich` |
+----------------------+--------------------------------------------+

Contact
-------

* bugs-admin@cacert.org

Additional People
-----------------

:ref:`people_benbe` and :ref:`people_mario` have :program:`sudo` access on that
machine too.

Basics
======

Physical Location
-----------------

This system is located in an :term:`LXC` container on physical machine
:doc:`infra02`.

Logical Location
----------------

:IP Internet: :ip:v4:`213.154.225.232`
:IP Intranet: :ip:v4:`172.16.2.16`
:IP Internal: :ip:v4:`10.0.0.16`
:MAC address: :mac:`00:ff:fe:13:14:7a` (eth0)

.. seealso::

   See :doc:`../network`

DNS
---

.. index::
   single: DNS records; Bugs

======================== ======== ============================================
Name                     Type     Content
======================== ======== ============================================
bugs.cacert.org.         IN A     213.154.225.232
bugs.cacert.org.         IN SSHFP 1 1 4B4BC32C4E655559B43A370B77CAD4983E8C24F8
bugs.cacert.org.         IN SSHFP 2 1 7916E317983D8BC85D719BB793E5E46A6B4976B2
bugs.intra.cacert.org.   IN A     172.16.2.16
======================== ======== ============================================

.. seealso::

   See :wiki:`SystemAdministration/Procedures/DNSChanges`

Operating System
----------------

.. index::
   single: Debian GNU/Linux; Jessie
   single: Debian GNU/Linux; 8.4

* Debian GNU/Linux 8.4

Applicable Documentation
------------------------

This is it :-)

Services
========

Listening services
------------------

+----------+---------+---------+--------------------------------+
| Port     | Service | Origin  | Purpose                        |
+==========+=========+=========+================================+
| 22/tcp   | ssh     | ANY     | admin console access           |
+----------+---------+---------+--------------------------------+
| 25/tcp   | smtp    | local   | mail delivery to local MTA     |
+----------+---------+---------+--------------------------------+
| 80/tcp   | http    | ANY     | web server for bug tracker     |
+----------+---------+---------+--------------------------------+
| 443/tcp  | https   | ANY     | web server for bug tracker     |
+----------+---------+---------+--------------------------------+
| 5666/tcp | nrpe    | monitor | remote monitoring service      |
+----------+---------+---------+--------------------------------+
| 3306/tcp | mysql   | local   | MySQL database for bug tracker |
+----------+---------+---------+--------------------------------+

Running services
----------------

.. index::
   single: Apache
   single: MySQL
   single: Postfix
   single: cron
   single: nrpe
   single: openssh
   single: rsyslog

+--------------------+--------------------+----------------------------------------+
| Service            | Usage              | Start mechanism                        |
+====================+====================+========================================+
| openssh server     | ssh daemon for     | init script :file:`/etc/init.d/ssh`    |
|                    | remote             |                                        |
|                    | administration     |                                        |
+--------------------+--------------------+----------------------------------------+
| Apache httpd       | Webserver for bug  | init script                            |
|                    | tracker            | :file:`/etc/init.d/apache2`            |
+--------------------+--------------------+----------------------------------------+
| cron               | job scheduler      | init script :file:`/etc/init.d/cron`   |
+--------------------+--------------------+----------------------------------------+
| rsyslog            | syslog daemon      | init script                            |
|                    |                    | :file:`/etc/init.d/syslog`             |
+--------------------+--------------------+----------------------------------------+
| MySQL              | MySQL database     | init script                            |
|                    | server for bug     | :file:`/etc/init.d/mysql`              |
|                    | tracker            |                                        |
+--------------------+--------------------+----------------------------------------+
| Postfix            | SMTP server for    | init script                            |
|                    | local mail         | :file:`/etc/init.d/postfix`            |
|                    | submission         |                                        |
+--------------------+--------------------+----------------------------------------+
| Nagios NRPE server | remote monitoring  | init script                            |
|                    | service queried by | :file:`/etc/init.d/nagios-nrpe-server` |
|                    | :doc:`monitor`     |                                        |
+--------------------+--------------------+----------------------------------------+

Databases
---------

+-------+--------+--------------------+
| RDBMS | Name   | Used for           |
+=======+========+====================+
| MySQL | mantis | Mantis bug tracker |
+-------+--------+--------------------+

Connected Systems
-----------------

* :doc:`monitor`

Outbound network connections
----------------------------

* DNS (53) resolving nameservers 172.16.2.2 and 172.16.2.3
* :doc:`emailout` as SMTP relay
* ftp.nl.debian.org as Debian mirror
* security.debian.org for Debian security updates
* crl.cacert.org (rsync) for getting CRLs
* HTTP (80/tcp) to :doc:`git`

Security
========

.. sshkeys::
   :RSA:   59:41:a6:da:9f:64:87:85:76:6f:ad:d5:5f:a8:50:45
   :DSA:   17:ef:36:49:60:6e:bb:36:fd:ef:d9:77:90:59:00:a9
   :ECDSA: a2:ee:46:14:c0:31:53:2a:b3:d1:34:82:02:df:ab:bc

Non-distribution packages and modifications
-------------------------------------------

.. index::
   pair: non-distribution package; Mantis

* custom built `mantis`_ package by :ref:`people_benbe`

.. _mantis: https://www.mantisbt.org/

Risk assessments on critical packages
-------------------------------------

Mantis as a PHP application is vulnerable to common PHP problems. The system
has to be kept up-to-date with OS patches. The custom built mantis package has
to be updated when new releases are provided upstream.

Critical Configuration items
============================

Keys and X.509 certificates
---------------------------

.. sslcert:: bugs.cacert.org
   :certfile:   /etc/ssl/public/bugs.c.o.20160314.crt
   :keyfile:    /etc/ssl/private/bugs.c.o.20160314.key
   :serial:     028A72
   :expiration: Mar 14 13:12:13 2018 GMT
   :sha1fp:     4D:1F:14:B2:BB:C8:59:68:D0:CF:86:36:DA:2F:B2:58:A7:90:E5:85
   :issuer:     CAcert.org Class 3 Root

* :file:`/etc/ssl/public/bugs.c.o.20160314.crt.chain` contains the server
  certificate and the Class 3 CA certificate

* :file:`/etc/mantis/config_inc.php` contains the database settings for Mantis

.. index::
   pair: Mantis; configuration

Mantis configuration
--------------------

The Mantis bug tracker configuration is stored in the directory
:file:`/etc/mantis/`.

* :file:`config_local.php` the main configuration file, including custom bug states
* :file:`custom_constants_inc.php` defines custom constants. Required for the
  non-default bug states
* :file:`custom_strings_inc.php` defines custom string definitions. Required
  for the non-default bug states

.. note::

   Localisation for these could go here but currently I would avoid that so all
   developers have the same vocabulary.

   -- :ref:`people_neo` 2011-07-04 02:44:45

.. index::
   pair: Apache httpd; configuration

Apache httpd configuration
--------------------------

The Apache configuration in the directory :file:`/etc/apache2/` has been
changed to add some additional headers to improve client security:

.. literalinclude:: ../configdiff/bugs/apache/bugs-apache-config.diff
   :language: diff

The :index:`Mantis VirtualHost <pair: bugs.cacert.org; VirtualHost>` is
configured in :file:`/etc/apache2/sites-available/mantis` (shared
configuration) that includes configuration from the mantis package provided
:file:`/etc/apache2/conf.d/mantis` file,
:file:`/etc/apache2/sites-available/mantis-nossl.conf` (HTTP VirtualHost) and
:file:`/etc/apache2/sites-available/mantis-ssl.conf` (HTTPS VirtualHost).

.. index::
   pair: MySQL; configuration

MySQL configuration
-------------------

MySQL configuration is stored in the :file:`/etc/mysql/` directory.

.. index::
   pair: rsyslog; configuration

Rsyslog configuration
---------------------

Rsyslog has been configured to disable draining the kernel log:

.. code-block:: diff

   --- orig/etc/rsyslog.conf      2015-12-14 13:34:27.000000000 +0100
   +++ bugs/etc/rsyslog.conf  2015-03-03 22:22:44.385835152 +0100
   @@ -9,7 +9,7 @@
    #################

    $ModLoad imuxsock # provides support for local system logging
   -$ModLoad imklog   # provides kernel logging support
   +#$ModLoad imklog   # provides kernel logging support
    #$ModLoad immark  # provides --MARK-- message capability

    # provides UDP syslog reception

The :program:`postfix` package installed :file:`/etc/rsyslog.d/postfix.conf` to
add an additional logging socket in the Postfix chroot.


Tasks
=====

Planned
-------

.. todo:: provide the custom mantis package from a infrastructure Debian
   package repository
.. todo:: setup IPv6
.. todo:: setup X.509 authentication if possible :bug:`678`

Changes
=======

System Future
-------------

* No plans

Additional documentation
========================

.. seealso::

   * :wiki:`PostfixConfiguration`

References
----------

Mantis Bugtracker documentation
   https://www.mantisbt.org/documentation.php
Apache httpd documentation
   https://httpd.apache.org/docs/2.4/