ed99bdd7cebc438107d8dfeedb25a0a607baa754
[gnucomo.git] / doc / manifest.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE doc SYSTEM "/usr/local/xslt/doc.dtd">
3 <doc style="main.css" xmlns:xlink="http://www.w3.org/1999/xlink">
4   <book>
5
6 <titlepage>
7    <title>GNUCOMO</title>
8    <subtitle>GNU COMPUTER MONITORING</subtitle>
9    <subtitle>A system for interactive system monitoring.</subtitle>
10    <subtitle>Development manifest</subtitle>
11
12    <author>Brenno J.S.A.A.F. de Winter, De Winter Information Solutions</author>
13    <author>Arjen Baart, Andromeda Technology &amp; Automation</author>
14    <date>December 6th, 2002.</date>
15    <docinfo>
16       <infoitem label="Version">0.22</infoitem>
17    </docinfo>
18
19 </titlepage>
20
21 <toc/>
22
23 <chapter>
24    <heading>About this document.</heading>
25
26 <para>
27 This document describes the technical specifications for the Gnucomo project.
28 It will describe the functionality achieved, design specifications and choices made.
29 The document will be the manifest for the developers to work in the same direction
30 and not run into unneeded disappointments.
31 </para>
32
33 <section>
34   <heading>History of the document.</heading>
35
36 <table cpos='lp{3cm}lp{5cm}'>
37   <thead>
38     <col>Version</col><col>Author</col><col>Date</col><col>Remarks</col>
39   </thead>
40   <row>
41     <col>0.l</col><col>Brenno de Winter</col><col>Jul 11, 2002</col>
42     <col>
43       Initial version
44     </col>
45   </row>
46   <row>
47     <col>0.11</col><col>Arjen Baart</col><col>Jul 12, 2002</col>
48     <col>
49       Additional guidelines and dataflow diagram.
50     </col>
51   </row>
52   <row>
53     <col>0.12</col><col>Brenno de Winter</col><col>Jul 15, 2002</col>
54     <col>
55       Database design added
56     </col>
57   </row>
58   <row>
59     <col>0.13</col><col>Arjen Baart</col><col>Jul 16, 2002</col>
60     <col>
61       Entity-relationship model added.
62     </col>
63   </row>
64   <row>
65     <col>0.14</col><col>Brenno de Winter</col><col>Jul 17, 2002</col>
66     <col>
67       Based on feedback. Small changes to the datamodel and finishing touches
68       in lay-out of the tables. Added some examples.
69     </col>
70   </row>
71   <row>
72     <col>0.15</col><col>Brenno de Winter, Arjen Baart</col><col>Jul 21, 2002</col>
73     <col>
74       Additional feedback processed, indexes added, ERD added and SQL-script created.
75     </col>
76   </row>
77   <row>
78     <col>0.16</col><col>Brenno de Winter</col><col>Aug 7, 2002</col>
79     <col>
80       Communication handling added.
81     </col>
82   </row>
83   <row>
84     <col>0.17</col><col>Brenno de Winter</col><col>Aug 11, 2002</col>
85     <col>
86       <para>* Description of the client-side for communications.</para>
87       <para>* Several updates to the database descriptions, drawings added.</para>
88       <para>* More work on the installation chapter.</para>
89       <para>* Created an extra field to the unprocessed_log table and added
90               a between the table service and unprocessed_log.</para>
91     </col>
92   </row>
93   <row>
94     <col>0.18</col><col>Brenno de Winter, Peter Roozemaal</col><col>Aug 15, 2002</col>
95     <col>
96       <para>* Review done by Peter Roozemaal: adjusted intro and several clarifications made</para>
97       <para>* Arjen Baart: Adjustments to database drawings</para>
98       <para>* New installation recommendations</para>
99     </col>
100   </row>
101   <row>
102     <col>0.19</col><col>Arjen Baart</col><col>Aug 27, 2002</col>
103     <col>
104       Conversion to XMLDoc
105     </col>
106   </row>
107   <row>
108     <col>0.20</col><col>Arjen Baart</col><col>Oct 20, 2002</col>
109     <col>
110       Minor layout improvements
111     </col>
112   </row>
113   <row>
114     <col>0.21</col><col>Arjen Baart</col><col>Nov 07, 2002</col>
115     <col>
116       Installation instructions added.
117       Combined chapters 4 through 7 into one chapter (4).
118     </col>
119   </row>
120   <row>
121     <col>0.22</col><col>Arjen Baart</col><col>Nov 15, 2002</col>
122     <col>
123       Added parameters of monitored objects.
124     </col>
125   </row>
126   <row>
127    <col>0.23</col><col>Brenno de Winter</col><col>Dec 6, 2002</col>
128    <col>
129      Added new elements to the database
130    </col>
131   </row>
132 </table>
133
134 </section>
135 </chapter>
136
137 <chapter>
138 <heading>Aim of the project.</heading>
139
140 <para>
141 The number of log-files in a system and the tools in general do not make
142 monitoring a system simple. Quite often there is so much information that
143 attention for logfiles seems to fade away. For that reason monitoring routers
144 and clients is often not an option. Instead of timely detection of problems,
145 logs more often are used to find out what went wrong. When a system is
146 under attack early signals can often easily be detected<footnote>Just as in
147 real life there a signals that things are not going in the right direction.
148 For the attacks on September 11th 2001 there were many signals available
149 that could to have led to early detection: warnings of several intelligence
150 agencies, warnings within the FBI, flight schools that report strange
151 customers that want to steer a plane and don't seem to care about take
152 off and landing, people opening accounts under fake names.</footnote>
153 and preventive measures could have been taken if the time was only available.
154 </para>
155
156 <para>
157 The Gnucomo project is meant to make pro-active monitoring of computers
158 and devices easier. It will contain a set of applications that will
159 retrieve all types of monitoring information from devices and place
160 it into a database. Devices can be server computers, desktop computers,
161 PBX'es or other systems. By running checks the manual process of
162 watching log files can be reduced. Also an intelligent script can
163 see things that a human being will easy overlook. Gnucomo won't
164 relieve an administrator of all manual work on log-files, but will
165 increase the changes on actual monitoring.
166 </para>
167 <para>
168 With all this data being available at one central location the gnucomo-server
169 acts as some kind of black box for computer systems. If something does
170 happen the evidence will be available at a remote location available
171 for exploration<footnote>This analogy is based on a remarkable anecdote:
172 One a trip to US I spoke to a 747-captain of Air France. While talking
173 over several subjects we touched security. When we went some deeper I
174 touched the subject gnucomo and he told me that Air France was doing
175 the very same with real black boxes. By sending all the data to Paris
176 errors can be detected earlier and be resolved. In any less fortunate
177 case the cause of the crash might be detected sooner (or fuller).
178 For me this was a signal there is a point in working gnucomo because
179 the analogy is valid.</footnote>. Forensics will be made easier.
180 Also the collected data is available from multiple locations make
181 it easier to found more about an attack. The change that you overlook
182 things will be reduced.
183 </para>
184 <para>
185 Based on the entered data all sorts of analysis will be performed to discover
186 abnormalities a normal maintenance tool or IDS wouldn't be looking at.
187 An example could be a website in Dutch that suddenly obtains a lot of
188 attention from Greek visitors (based on the location of their
189 IP<footnote>That IP could also warn for other things like: excessive
190 data traffic from wireless connections at times that you wouldn't be
191 expecting traffic at all, absence of traffic when you would be expecting
192 some traffic at least or even what article is liked in which part of the world,
193 what regions poses the highest threat to the security of the system (based
194 on the location of the IP address).</footnote>). These abnormalities will
195 be presented as user-friendly as possible to increase awareness of the
196 state of the system. By doing that the system can also be used for more
197 complex analysis. One than can look at long-term trends like hacking
198 attempts that take place, new exploits that are tried all of a sudden
199 or signs of distributed attacks or a certain pattern of attempts<footnote>A portscan
200 that last three days is hard to detect with a real-time IDS,
201 while gnucomo would discover this anyhow. With correct intelligence
202 one portscan from multiple IP-addresses can be related.</footnote>.
203 </para>
204 <para>
205 Also extra data will be gathered where ever possible to save time to
206 the administrator. If IP address attract attention of gnucomo the next
207 logical step would be to use tools like dig, whois and visiting arin-related
208 websites. This data will automatically be collected in an early stage and
209 stored in the database.
210 </para>
211 <para>
212 The results will be gathered in a warning system.
213 Those warnings will be presented to the administrative person
214 who is responsible for that particular machine or network.
215 Having multiple systems in the system can add to the intelligence that
216 can be gathered. The interface will be web-based and aimed at user-friendliness.
217 </para>
218 <para>
219 Since multiple systems can enter data into the Gnucomo database more
220 intelligent hardware and security detection can be done.
221 When things do go wrong Gnucomo contains as much information as
222 possible to figure out what happened and assist in the forensics.
223 Since research on the signals afterwards is broader more attention
224 will be given as much data as possible and do less filtering.
225 </para>
226 <para>
227 With the data in the database also policies can be checked automatically
228 retro-actively so that the security leaves some room to stretch some rules.
229 This may sound not logic, because one of the main functions of security is
230 to enforce rules. But some rules are made with the different meanings.
231 For instance: a rule may be that private browsing isn't allowed.
232 The background of such a rule might be to try and reduce the amount
233 of data traffic (too many people downloading mp3's, or people not
234 getting to work anymore). By monitoring that specific fact
235 (bandwidth spent on non-business related Internet use)
236 it's possible to be relaxed on that rule and enable many good-willing
237 users reading his/hers daily newspaper.
238 </para>
239 <para>
240 The scope of the project is clearly limited to monitoring and not to
241 offer automated maintenance or web-based maintenance.
242 There are other projects currently being able to provide that
243 functionality. We will focus on intelligence and user-friendliness
244 of representation of facts presented. A warning should trigger
245 an administrator to get up and do something using the tools he or she values the most.
246 </para>
247 <para>
248 Also we are not aiming to replace great tools like SNORT as a real-time IDS.
249 These tools can do thing, that in the beginning won't be a part of gnucomo
250 out of performance reasons. Also there is no need to duplicate what they
251 already did. If that energy is placed in intelligent we're very complimentary.
252 Gnucomo can however be a reality check on an existing NIDS (Network Intrusion
253 Detection System). For instance if warnings keep coming it may be time to
254 rethink the rules that have been set.
255 </para>
256
257 <para>
258 This evolves to the following list of functions gnucomo can provide:
259 </para>
260 <itemize>
261   <item> Intrusion detection </item>
262   <item> Detecting hacker attempts </item>
263   <item> Early detection of system failures </item>
264   <item> Exhaustion of system resources </item>
265   <item> Capacity planning for future expansion </item>
266   <item> Spotting bottlenecks in a system.  </item>
267   <item> Verifying system integrity </item>
268   <item> Assistance with troubleshooting </item>
269   <item> Perform post-mortem forensics </item>
270   <item> Incident response system.  </item>
271 </itemize>
272 </chapter>
273
274 <chapter>
275    <heading>Decisions for the overall system.</heading>
276
277 <para>
278 In order to get the project running we have to make some decisions before
279 we can start. Of course are the decisions always open for review,
280 but initially our main aim is to get a system running. This doesn't
281 mean that we allow a lesser architecture, but more that we create an
282 environment that will lead to results.
283 </para>
284 <para>
285 The following decisions apply to the system in general:
286 </para>
287 <itemize>
288   <item>
289     The major part of the system will be used for security features.
290     The solution itself has to be secure.
291   </item>
292   <item>
293     In general we strive to be as platform and application independent as possible.
294     However to achieve software to get ready and to assure progress some selections
295     will have to be made excluding options for applications<footnote>An example is
296     in the database. By using stored procedures and triggers MySQL cannot be used.
297     However the data integrity at that point is more important than the ability to
298     use MySQL.</footnote>. Where possible we will enable ports to other applications
299     and platforms.
300   </item>
301   <item>
302     The computers collecting the data will only be Linux machines,
303     with future support for other Unices. However it is not aim our
304     to port this part of the project to other platforms just now.
305   </item>
306   <item>
307     The database system will make heavy use of stored procedures and
308     triggers and thus lock out some less feature-full database.
309   </item>
310   <item>
311     Although we're not married to a database system initially this will be
312     PostgreSQL only so that we can build for results. The code however
313     shouldn't be build to deliberately lock outer systems.
314     Other database that might be interesting to add: DB2, Oracle
315     (if the rainfall of security advisories seems to be over) and Informix.
316   </item>
317   <item>
318     The interface for the user will be a web-interface written in PHP
319     with PostgreSQL-database access. Despite the fact that initially
320     this will be the preferred way to communicate with our system,
321     other interfaces are welcome and should be supported.
322   </item>
323   <item>
324     The technologies used for the daemons on the central site and remote
325     site are open for discussion. A decision is made when it is clear what
326     exactly will be needed to code.
327   </item>
328   <item>
329     The original logfiles on systems will not be harmed in any way,
330     but will be saved the way they presented to gnucomo.
331   </item>
332   <item>
333     In the database processed data as well as raw data will be stored.
334   </item>
335   <item>
336     Our main aim is to ease the life of the administrator when dealing with
337     the symptoms of a machine so that he doesn't miss important notifications.
338     The project will be made around detection. We won't focus on making a
339     maintenance applications but solely on monitoring, because other applications
340     like webmin or linuxconf do already deliver such functionality.
341     We are complementary to those applications. This doesn't mean that
342     the system cannot send SMS'es, e-mails or make alarms sound.
343   </item>
344   <item>
345     Any output of the logbook will be stored and sent within a certain
346     interval which can be set. By doing that the mechanism will not flood
347     the total mechanism and overload machines.
348   </item>
349   <item>
350     When applications for gnucomo we will try and do the non-server part
351     as platform independent as possible. This in order to prevent writing
352     a same application multiple times. For instance one for Unices, one
353     for Macintosh and one for Microsoft.
354   </item>
355   <item>
356     To ensure the quality of software and to prevent any unwanted functionality
357     rolling into the project all code will be reviewed by one of the lead members
358     before it is accepted. Since this project is aimed at throughput speed no
359     formal procedures will be enforced, but we promise not to let software in
360     that hasn't been checked.
361   </item>
362 </itemize>
363
364 </chapter>
365
366 <chapter>
367   <heading>Overall system Architecture</heading>
368
369 <para>
370 The overall systems aims to make maintenance data better accessible and by
371 doing that lowering the barrier to be on alert for intrusions,
372 system failure and other misery that can happen to computer systems.
373 Also more systems can be monitored and even focus can be placed on desktop computers,
374 something that nowadays rarely happens. Since the solution is only aimed at
375 monitoring (with some responses possible) other people can watch their system(s)
376 without being Administrator<footnote>This can be interesting for people using
377 this service and not doing their own maintenance (smaller companies).
378 If technical action needs to be taken a warning can be send to an administrator.
379 This saves costs and time.</footnote>.
380 </para>
381 <para>
382 The main system will know to sides:
383 </para>
384
385 <itemize>
386   <item> Central Application - server </item>
387   <item> Monitored System - client </item>
388 </itemize>
389
390 <para>
391 The project has been setup as a two sided system in order to be able to
392 guard many computers at the same time.
393 However it may be obvious that both sides of the application can very
394 well be installed on a single system.
395 </para>
396 <para>
397 To monitor a system, Gnucomo uses two kinds of input: <emph>event</emph> and
398 <emph>parameters</emph>. Events occur on a system while it is running and reflect
399 the transient behaviour of the system.
400 Parameters reflect the current state of the system.
401 The most obvious way to gather events from a monitored system is to read
402 the system log files.
403 Examples of events are IP packets that are rejected by the firewall or clients
404 that access the http daemon.
405 Parameters are obtained for example by reading configuration files or kernel
406 data structures.
407 Examples of parameters are the size and free space of a filesystem or
408 the users that are listed in the password file.
409 Both kinds of input are obtained actively or passively, i.e. by installing probe
410 agents in the system which regularly aquire the system's parameters or passively
411 by sending the output of programs to the Gnucomo server.
412 </para>
413 <para>
414 When signals<footnote>A signal can be the outcome of process that finished,
415 logbook entries, warnings from intrusion detection systems,
416 etc. </footnote> arrive they will be stored in a file.
417 When this file is delivered to a certain directory a daemon will detect
418 this and start the transfer of the file. The file will be transferred
419 to the central application or the client. This transfer will be triggered
420 immediately after a process has finished or with a certain time-interval
421 when it concerns a logbook. All output will be placed in a directory where
422 the daemon detects it and ensures the transport. For transport currently
423 only two mechanisms will be supported:
424 </para>
425 <itemize>
426   <item>
427     Encrypted file copy relying on the SSH protocol.
428     On Unix-based systems this will scp (secure copy).
429   </item>
430   <item>
431     E-Mail. The e-mail is encrypted and signed using gpg and then sent to the server.
432     Since the file format will identify the type-of-output the Subject-field of
433     the e-mail is not really needed.
434   </item>
435 </itemize>
436
437 <section>
438   <heading>Central Application: signal handler.</heading>
439
440 <para>
441 <para>
442
443   <picture src="architecture.png" eps="architecture"/>
444 </para>
445 <para>
446        Illustration 1 Basic overview of the processes on the server.
447 </para>
448
449 On one machine signals from the network will come in.
450 These signals can be logfiles, result files from applications,
451 remarks entered by the administrator or whatever.
452 Data delivery takes place into a certain directory.
453 A daemon detects that data has come in and will enter it into the database.
454 Once in the database stored procedures and triggers will recognize certain
455 behavior and generate alerts. The user responsible for the server will be
456 confronted with the alerts and can mark them, add comments to it or ignore them.
457 Also it will be possible to do intelligent analysis on not so logical relations
458 per computer or across computers<footnote>A good example could be a portscan
459 on a system that takes place during a week. Normal a simple portscan takes
460 place in a couple of minutes and will thus be easy to detect.
461 By taking a longer period such a scan is harder to detect. </footnote>. Such
462 scripts make detection possible, that is too time consuming to do during
463 processing of the data.
464 </para>
465 </section>
466
467 <section>
468   <heading>Data processing.</heading>
469
470 <para>The data processing has four tasks:</para>
471 <itemize>
472   <item>
473     Extracting data from e-mail and store it in the input-buffer.
474     This can be done by a daemon that checks the e-mail<footnote>It would be logical
475     to place an e-mail server like sendmail or postfix on the server.
476     In many cases the monitored computer will be featuring a SMTP daemon.
477     If a system is comprimised no evidence that comes through will be really
478     trustworthy. By sending it to another machine all evidence that is
479     available will have left the system the moment a hack takes place.</footnote>
480     with a certain interval extracts the e-mails and leave the content
481     in a file in the input buffer. This daemon has only rights to write
482     to the directory it has to write to. <emph>We may as well have the
483     email captured directly by a program with a
484     "gnucomo: |/usr/local/bin/gnucomo-input" - like alias.</emph>
485   </item>
486   <item>
487     Detect files in the input buffer decrypt the content and verify the signature.
488     Another daemon will see the log-files and starts checking if the origin is
489     correct (by verifying the signature) and decrypting the content.
490     The legible files will be processed by entering the data into the database.
491   </item>
492   <item>
493     The database will accept the data and perform a certain number of
494     checks as the data comes in. During the processing of the data
495     abnormalities will be detected and entered into a notification table.
496     The database system will also carry out more complex tasks on given
497     moments in time and enter them as well in the notification table.
498   </item>
499   <item>
500     The database system must be able to undertake action when high
501     alerts are being entered into the database.
502     This can be a couple of things to begin with:
503     send an e-mail or SMS. In a later stage other technologies may be added as well.
504     In this scheme we also make a possibility to escalate problems when no
505     action is taken in a certain amount of time.
506   </item>
507 </itemize>
508
509 <subsection>
510 <heading>System Parameters</heading>
511
512 <para>
513 Gnucomo maintains the operational parameters of a monitored system for a
514 number of reasons.
515 The most important reason is to create notifications when somthing about a
516 parameter changes while the parameter is not supposed to change.
517 Such a change may be intended by the system administrator, e.g. when a
518 package is upgraded, or there may be something wrong.
519 In any case, you will want to know about a change in your system when it happens.
520 Furthermore, a change history of a parameter's values will come in
521 handy when you want to look back in time and figure out
522 what happened in the past.
523 Another usefull application of parameters concerns the maintenance of a 
524 large number of similar systems.
525 When the parameters of each system are reported regularly to Gnucomo,
526 deviations from the 'standard' system configuration can be easily spotted.
527 </para>
528 <para>
529 Some properties of parameters are supposed to change regularly.
530 A changed value of such a property will of course not lead to any
531 notification.
532 On the other hand, the change history of these parameters may provide
533 interesting information about the monitored system.
534 This leads to the distiction between static and dynamic properties of parameters.
535 The difference between dynamic and static properties manifests itself mainly
536 in the change history of the parameter's property.
537 Dynamic properties typically have a change record once a day or even a couple
538 of times a day.
539 Change records for static properties are usually months apart.
540 </para>
541 <para>
542 The state of parameters is scanned or probed regularly on a client system
543 and reported to the Gnucomo server.
544 These reports can be created in a variety of ways.
545 For example, filesystems are reported with 'df', installled packages with 'rpm -qa',
546 users by reading /etc/passwd, etc.
547 Many other probing methods may be implemented.
548 Each report from a probe holds the current value of several parameters.
549 Gnucomo will check each property of these parameters against the stored knwon value.
550 If the property's value changed, the actual value in the database is updated
551 and a record is added to the change history of the parameter.
552 </para>
553 </subsection>
554 </section>
555
556 <section>
557   <heading>Web interface</heading>
558
559 <para>
560 The web interface will used to interact with the user.
561 The interface should be intuitive and easy to understand.
562 More important warnings should directly draw attention.
563 The user must be able to perform settings so that warnings
564 can be rated differently than the original settings.
565 </para>
566 <para>
567 The interface will do the following things:
568 </para>
569 <itemize>
570   <item>
571     Show a list of warnings that are currently open.
572   </item>
573   <item>
574     It must be possible to sort the list on all the fields shown.
575   </item>
576   <item>
577     Deliver detailed information (logbook entries) upon request that have led to the warning.
578   </item>
579   <item>
580     Undertake certain actions like sending
581     <reference href="mailto:abuse@internet-provider.net">abuse@internet-provider.net</reference>
582     e-mails with information.
583   </item>
584   <item>
585     Monitor actions on outstanding issues.
586   </item>
587 </itemize>
588 <para/>
589 </section>
590
591 <section>
592   <heading>Priority mechanism.</heading>
593 <para>
594 Each notification has a certain priority that requires a different handling
595 of the issue. How each priority will be dealt with is something that can
596 be set per server. The priority mechanism is a simple system of five
597 categories (can be more or less).
598 </para>
599 </section>
600
601 <section>
602   <heading>The dataflow diagram.</heading>
603 <para>The main dataflow will be as follows.</para>
604 <para>
605   <picture src="dataflow.png" eps="dataflow" scale="0.7"/>
606 </para>
607 <para/>
608 </section>
609
610 <section>
611   <heading>Sending messages to the central gnucomo system.</heading>
612
613 <para>
614 One of the main tasks is getting all the messages to the database.
615 Ultimately gnucomo will support multiple ways of receiving the data.
616 Basically anything goes, but two mechanisms will be supported in the project
617 to begin with:
618 </para>
619 <enumerate>
620     <item>
621       E-mail. Messages and elements from logfiles will be sent through e-mail.
622     </item>
623     <item>
624       File copy. Using technologies like scp or ftp (not preferred due to
625       the insecure nature) can place files directly in the receiving directory.
626     </item>
627 </enumerate>
628
629 <subsection>
630   <heading>Ensuring data integrity.</heading>
631 <para>&lt;TO BE DESCRIBED&gt;</para>
632 </subsection>
633
634 <subsection>
635   <heading>Directories and filenames on the server.</heading>
636
637 <para>
638 Files will be dealt with as if gnucomo were a user (actually there will
639 be a user gnucomo). The files will be placed in the <code>/home/gnucomo/</code> directory.
640 Only <code>/home/gnucomo/incoming/dropbox/</code> can be used to save data in
641 from external systems. All other directories are only available for the user gnucomo.
642 The filename will represent the data that is received. The details are seperated with
643 underscores. When data is sent by e-mail the filename will be written in the first
644 line of the e-mail. A typical filename looks like this:
645 </para>
646
647 <para>
648 <strong>3_messages_20020807235208_1.asc</strong>
649 </para>
650
651 <para>
652 the logic behind this is following:
653 </para>
654
655 <para>
656 <emph>urgency_typeofmessage_timestamp_objectid.typeoffile.</emph>
657 </para>
658
659 <table cpos='lp{10cm}'>
660   <thead>
661     <col>
662       <para>Part of filename</para>
663     </col>
664     <col>
665       <para>Explanation</para>
666     </col>
667   </thead>
668   <row>
669     <col>
670       <para>Urgency</para>
671     </col>
672     <col>
673       <para>This indicates the urgency of the file. The lower the number the higher
674             it will rank when an overview is given. Standard files are ranked value 3.
675             The ranking works as follows:</para>
676       <para>* 1 <strong>Urgent flash message.</strong> Something urgent needs to
677             be reported. This is only used for emergencies like serious alarms.</para>
678       <para>* 2 <strong>Rapid delivery.</strong> An important message has to get
679             through that is more important than normal delivery, but is not top
680             priority like an emergency.</para>
681       <para>* 3 <strong>Normal.</strong> This is used in most
682             case for normal messages.</para>
683       <para>* 4 <strong>Low priority.</strong> This is data would be useful
684             to place into the system as nice to have.</para>
685     </col>
686   </row>
687   <row>
688     <col>
689       <para>TypeOfMessage</para>
690     </col>
691     <col>
692       <para>This is an indicator what type of data is delivered to gnucomo.
693             There are several categories:</para>
694       <para>* <strong>cron.</strong> This data comes from the /var/log/cron-log (unix).</para>
695       <para>* <strong>httpaccess.</strong> This data comes from the normal http-log (Apache).</para>
696       <para>* <strong>httperror.</strong> This data comes from the http_error-log (Apache).</para>
697       <para>* <strong>maillog.</strong> This data comes from the /var/log/maillog (unix).</para>
698       <para>* <strong>messages.</strong> The data delivered here comes from
699             the /var/log/messages file (unix)</para>
700       <para>* <strong>text.</strong> This file contains a message in plaintext
701             generated by a gnucomo-client and can be anything.
702             It will be dealt with as plaintext.</para>
703     </col>
704   </row>
705   <row>
706     <col>
707       <para>Timestamp</para>
708     </col>
709     <col>
710       <para>The timestamp is made in war-log (YYYYMMDDHHMMSS) format.
711             The timestamp is generated on the client in GMT (to discover
712             discrepancies in timing).</para>
713     </col>
714   </row>
715   <row>
716     <col>
717       <para>Objectid</para>
718     </col>
719     <col>
720       <para>The objectid is the id that is used within the central
721             gnucomo system to recognize the client.
722             Based on this entry the database can link the data to the correct object.
723             Also gpg can obtain the correct e-mail address (by running a query
724             in the database) for verification of the signature of the crypted message.</para>
725     </col>
726   </row>
727   <row>
728     <col>
729       <para>TypeOfFile</para>
730     </col>
731     <col>
732       <para>Indicates the file type:</para>
733       <para>* <strong>asc.</strong> Plaintext ASCII</para>
734       <para>* <strong>gpg.</strong> gpg-crypted data.</para>
735       <para>* <strong>und.</strong> Undertermined data. When files
736             come in by e-mail it is not 100% sure if they are crypted
737             or not. These data has first to be analyzed before it is
738             moved to the correct queue. </para>
739     </col>
740   </row>
741 </table>
742
743 <subsubsection>
744   <heading>Directory for incoming data.</heading>
745
746 <para>
747 For incoming messages there will be separate directories
748 (<code>/home/gnucomo/incoming/</code>)for:
749 </para>
750 <enumerate>
751     <item>
752       Dropbox. This directory is ready to receive data from all sorts of systems.
753       This directory is world writeable (<strong><emph>but not deleteable!</emph></strong>):
754       <code>/home/gnucomo/incoming/dropbox/</code>
755     </item>
756     <item>
757       Encrypted messages. In this directory messages will be placed that are still
758       gpg-crypted. In this directory the files await decryption and verification of
759       the signature. This directory is: <code>/home/gnucomo/incoming/crypted/</code>
760     </item>
761     <item>
762       Decrypted with errors. During the decryption exercise anything can go wrong.
763       Decrypting can fail or the signature may show errors. If this happens the
764       original message is moved to a different directory:
765       <code>/home/gnucomo/incoming/cryptfail/</code>
766     </item>
767     <item>
768       Inbox. After successful decryption the decrypted message is moved to the inbox.
769       Data that is not encrypted can be moved here from the dropbox after certain
770       verifications. The directory is: <code>/home/gnucomo/incoming/inbox/</code>
771     </item>
772     <item>
773       Processed. After processing the data the file is stored in the directory
774       processed for further reference for a certain amount of time.
775       The directory is: <code>/home/gnucomo/incoming/processed/</code>
776     </item>
777     <item>
778       Archive. After a certain period the files will be archived.
779       Since not every system will archive everything this directory may
780       also be a symbolic link to <code>/dev/null</code>.
781       The used directory is: <code>/home/gnucomo/archive/</code>
782     </item>
783 </enumerate>
784 </subsubsection>
785
786 <subsubsection>
787    <heading>Directory for outgoing data.</heading>
788
789 <para>
790 For outgoing messages the directory <code>/home/gnucomo/outgoing</code> will
791 be used. This directory knows a couple of sub directories:
792 </para>
793
794 <enumerate>
795     <item>
796       Dropbox. This directory is used by the central gnucomo system to
797       place outgoing messages in.
798       The used directory is: <code>/home/gnucomo/outgoing/dropbox/</code>
799     </item>
800     <item>
801       Outbox. After processing the message (including signing and encrypting
802       when applicable) the messages are placed in the outbox:
803       <code>/home/gnucomo/outgoing/outbox/</code>
804     </item>
805     <item>
806       Processed. After processing the data the file is stored in the
807       directory processed for further reference for a certain amount
808       of time. After sending a message a confirmation will be made that
809       is saved as an incoming message.
810       The directory is: <code>/home/gnucomo/outgoing/processed/</code>
811     </item>
812     <item>
813       Archive. After a certain period the files will be archived.
814       Since not every system will archive everything this directory
815       may also be a symbolic link to <code>/dev/null</code>.
816       The used directory is: <code>/home/gnucomo/archive/</code>
817     </item>
818 </enumerate>
819
820 </subsubsection>
821
822 <subsubsection>
823    <heading>Overview. </heading>
824
825 <para>The total directory-structure looks like this:</para>
826
827 <verbatim>
828     /home/gnucomo/
829     /home/gnucomo/archive
830     /home/gnucomo/incoming
831     /home/gnucomo/incoming/crypted
832     /home/gnucomo/incoming/cryptfail
833     /home/gnucomo/incoming/dropbox
834     /home/gnucomo/incoming/inbox
835     /home/gnucomo/incoming/processed
836     /home/gnucomo/outgoing
837     /home/gnucomo/outgoing/dropbox
838     /home/gnucomo/outgoing/outbox
839     /home/gnucomo/outgoing/processed
840 </verbatim>
841
842 </subsubsection>
843 </subsection>
844
845 <subsection>
846   <heading>Directories on the client-side.</heading>
847
848 <para>
849 On the client-side the files that need to be transmitted will be placed in a
850 directory system as well. In the future this system may not be in use at all
851 devices (routers, certain MS Windows-machine, IP Telephones, etc.). For those
852 systems a different mechanism will become be described here.
853 Initially we focus on Linux systems that will enter data into the database.
854 </para>
855 <para>
856 The filename convention will be totally identical to the filename
857 convention on the server, since this the same mechanism.
858 </para>
859 <para>
860 To facilitate gnucomo client and server on one and the same machine
861 the gnucomo-client should have a different default user.
862 For this purpose the user <strong>gcm_client</strong> will be created.
863 </para>
864
865 <subsubsection>
866    <heading>Directory for incoming data.</heading>
867 <para>
868 For incoming messages there will be separate directories
869 (<code>/home/gnucomo/incoming/</code>)for:
870 </para>
871 <enumerate>
872     <item>
873       Dropbox. This directory is ready to receive data from all sorts of systems.
874       This directory is world writeable (<emph><strong>but not deleteable!</strong></emph>):
875       <code>/home/gcm_client/incoming/dropbox/</code>
876     </item>
877     <item>
878       Encrypted messages. In this directory messages will be placed that
879       are still gpg-crypted. In this directory the files await decryption
880       and verification of the signature.
881       This directory is: <code>/home/gcm_client/incoming/crypted/</code>
882     </item>
883     <item>
884       Decrypted with errors. During the decryption exercise anything can go wrong.
885       Decrypting can fail or the signature may show errors.
886       If this happens the original message is moved to a different directory:
887       <code>/home/gcm_client/incoming/cryptfail/</code>
888     </item>
889     <item>
890       Inbox. After successful decryption the decrypted message is moved
891       to the inbox. Data that is not encrypted can be moved here from
892       the dropbox after certain verifications. The directory is:
893       <code>/home/gcm_client/incoming/inbox/</code>
894     </item>
895     <item>
896       Processed. After processing the data the file is stored
897       in the directory processed for further reference for a
898       certain amount of time. The directory is:
899       <code>/home/gcm_client/incoming/processed/</code>
900     </item>
901 </enumerate>
902
903 </subsubsection>
904
905 <subsubsection>
906    <heading>Directory for outgoing data.</heading>
907
908 <para>
909 For outgoing messages the directory <code>/home/gcm_client/outgoing</code> will be used.
910 This directory knows a couple of sub directories:
911 </para>
912 <enumerate>
913     <item>
914       Dropbox. This directory is used by the central gnucomo system to place
915       outgoing messages in.
916       The used directory is: <code>/home/gcm_client/outgoing/dropbox/</code>
917     </item>
918     <item>
919       Outbox. After processing the message (including signing and
920       encrypting when applicable) the messages are placed in the outbox:
921       <code>/home/gcm_client/outgoing/outbox/</code>
922     </item>
923     <item>
924       Processed. After processing the data the file is stored in the
925       directory processed for further reference for a certain amount
926       of time. After sending a message a confirmation will be made
927       that is saved as an incoming message.
928       The directory is: <code>/home/gcm_client/outgoing/processed/</code>
929     </item>
930 </enumerate>
931 </subsubsection>
932
933 <subsubsection>
934   <heading>Overview. </heading>
935     <para>The total directory-structure looks like this:</para>
936
937 <verbatim>
938     /home/gcm_client/
939     /home/gcm_client/archive
940     /home/gcm_client /incoming
941     /home/gcm_client/incoming/crypted
942     /home/gcm_client/incoming/cryptfail
943     /home/gcm_client/incoming/dropbox
944     /home/gcm_client/incoming/inbox
945     /home/gcm_client/incoming/processed
946     /home/gcm_client/outgoing
947     /home/gcm_client/outgoing/dropbox
948     /home/gcm_client/outgoing/outbox
949     /home/gcm_client/outgoing/processed
950 </verbatim>
951 </subsubsection>
952 </subsection>
953 </section>
954
955 <section>
956       <heading>Getting data into the database.</heading>
957
958 <para>
959 The files in the /home/gnucomo/incoming/inbox/ should be stored in the database.
960 For this purpose there is a table <emph>unprocessed_log</emph>.
961 The data of the filename as well as the content of the file need
962 to be placed in one record.
963 </para>
964 <para>
965 There are some fields that have to be addressed immediately:
966 </para>
967 <enumerate>
968     <item>
969       Servicecode: The servicecode will be obtained out of the filename the
970       is the type_of_message-field in the filename.
971     </item>
972     <item>
973       Objectid: This data is given in the filename it can be found
974       in the <emph>objectid</emph>-part of the filename.
975     </item>
976     <item>
977       Logdata: The data is saved as follows: filename (unaltered)
978       &lt;CR&gt;textual data of the file.
979     </item>
980 </enumerate>
981 <para>
982 The daemon application that delivers the data is called <strong>gcm-input</strong>.
983 It performs the following steps with no extra functionality:
984 </para>
985
986 <enumerate>
987     <item>
988       <para>Detect if a file is available.</para>
989     </item>
990     <item>
991       <para>Write the data in the database.</para>
992     </item>
993 </enumerate>
994
995 <para>
996 To write the data in the database a database user gcm_input exists.
997 This user has only the right to enter data into the database.
998 There are no deletion, update or select-permissions.
999 </para>
1000
1001 </section>
1002 </chapter>
1003
1004 <chapter>
1005   <heading><label name='database'/>The database.</heading>
1006
1007 <para>
1008 The database is the heart of the system.
1009 It will contain all event-data of multiple computers.
1010 The intelligence that can be performed on the database will be placed there.
1011 To do this as integratedly as possible stored procedures and triggers will be used.
1012 To begin with we have selected checks to be performed that will be
1013 expanded throughout time.
1014 </para>
1015 <para>
1016 Since the gnucomo database and files contain sensitive data
1017 security measures have to be in place. Several database users
1018 will exist that have limited rights to perform a certain task
1019 ensuring some protection against unauthorized access.
1020 However these mechanisms on it's own will work fine, bad maintenance may still
1021 screw-up good security. Good database maintenance is needed.
1022 For the gnucomo the protection of the valid authentic nature of
1023 the data in the database has our highest priority.
1024 </para>
1025 <para>
1026 A <emph>table-name</emph> in this chapter is written in cursive writing.
1027 </para>
1028
1029 <section>
1030   <heading>Database conventions.</heading>
1031
1032 <para>
1033 The database will be built according the following conventions:
1034 </para>
1035 <itemize>
1036   <item>
1037     All names for tables, indexes and fields will be written in lower
1038     case and will be singular. Spaces in names are not allowed.
1039   </item>
1040   <item>
1041     If a table contains field referring to other tables the mother-tables are
1042     mentioned in alphabetical order with an underscore between the table-names.
1043     So <emph>object</emph> and <emph>user</emph>
1044     will make a third table <emph>object_user</emph>
1045   </item>
1046   <item>
1047     A data access user (being the interface) is not allowed to write to
1048     the log-entries and the warnings. To change the state of a warning
1049     a stored procedure will do so by having a different entry in a table.
1050     This should make it possible to discover who did what at which moment in time.
1051   </item>
1052   <item>
1053     The name of two related fields that make the relationship between two
1054     tables will be the same to avoid confusion.
1055   </item>
1056 </itemize>
1057 </section>
1058
1059 <section>
1060   <heading>Database design.</heading>
1061
1062 <para>
1063 In the design we anticipate to deliver an as best as possible database performance.
1064 That means that data that needs to be entered occasionally can be heavily indexed
1065 to increase performance. However data that is mainly stored will only be indexed
1066 marginally to have the best possible performance on data entry. If during one of
1067 the checks on data-entry a notification is made, the information related to that
1068 notification will be indexed very well to increase retrieval performance.
1069 What we will try to avoid is that the user interface will cause full table
1070 scan and affect the performance of the overall system dramatically.
1071 One of the techniques to increase performance on display is to work with views.
1072 So where it is feasible we will use them.
1073 </para>
1074
1075 <para>
1076 The following model pictures the database as described in the remainder
1077 of this chapter.
1078 </para>
1079 <para>
1080       <picture src="erd.png" eps="erd" scale="0.7"/>
1081 </para>
1082
1083 <para>
1084 In general the database must also be maintained well.
1085 So daily maintenance scripts should keep the performance good<footnote>PostgreSQL seems
1086 to have very good features to do proper maintenance and they have to be exploited to
1087 the full extend.</footnote>.
1088 </para>
1089
1090 </section>
1091 <section>
1092   <heading>Actual design.</heading>
1093
1094 <para>
1095 In this part of the chapter the tables will be explained and then described
1096 with all important elements. Per table a sub-chapter will be created.
1097 Each table will have a table design, indexes, relationships and the required data
1098 (for those tables where the data itself is relevant in the design or sample data
1099 (for those cases where no set data is needed). For the relationships beside a
1100 description the subset of the total schema has been incorporated in
1101 the document so that it is more clear what exactly is meant.
1102 Due to the complex nature of the design those drawings sometimes will seem funny.
1103 </para>
1104 <para>
1105 For the fieldtypes the types of PostgreSQL will be used.
1106 These values can be found in Chapter 3 of the PostgreSQL User Manual
1107 (<reference href="http://www.postgresql.org/">http://www.postgresql.org</reference>).
1108 </para>
1109 <para>
1110 For indexes primary keys are always <emph>unique</emph> and called
1111 primary key in the name. Since unique indexes within PostgreSQL only
1112 work on B-Tree indexes (which is default) we will use B-Tree for all indexes.
1113 In cases where an exception is made the used type of index will be indicated
1114 in the characteristics. A footnote will explain why a different type of
1115 index has been selected.
1116 </para>
1117
1118 <subsection>
1119 <heading>action</heading>
1120
1121 <para>
1122 This table stores the actions that are recognized by the system.
1123 Whenever a situation in the database has been raised (through the table notification)
1124 one expects steps to be taken to resolve these issues.
1125 All these steps are stored in this table.
1126 Each step beginning with detection until a case is closed can be traced back through this table.
1127 This will support the <strong>accountability</strong> (who is responsible for which action)
1128 and <strong>non-repudiation</strong> (being able to trace what exactly happened to each notification).
1129 In the table action all recognized actions that can be taken are stored.
1130 Several of the taken actions will lead to change in <emph>statuscode</emph>.
1131 When this is the case either the server-side of the interfaces or the gcm_daemon will perform this task. 
1132 This doesn't apply to all actions though.<footnote>A status NEW
1133 of a notification that cannot be dealt with automatically will
1134 <strong>not</strong> change before a user looked at it.</footnote>.
1135 Actions take place through background processes and the interface.
1136 Each action known by the system will be delivered by the software.
1137 This table mainly is used for retrieval so indexing will be done as much as possible.
1138 </para>
1139
1140 <subsubsection>
1141   <heading>The fields.</heading>
1142
1143 <para>
1144 The table below describes the fields:
1145 </para>
1146 <para/>
1147 <para>
1148 <table cpos='lllp{6cm}'>
1149   <thead>
1150     <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
1151     <col>
1152       Remarks
1153     </col>
1154   </thead>
1155   <row>
1156     <col> actionid </col> <col> Bigserial </col> <col> 8 </col>
1157     <col>
1158       Autonumber bigint (eight bit). Unique identifyer to refer to when this action is taken.
1159     </col>
1160   </row>
1161   <row>
1162     <col> actionname </col> <col> Text </col> <col> <para/> </col>
1163     <col>
1164       Short descriptive name for the type of action.
1165     </col>
1166   </row>
1167   <row>
1168     <col> statuscode </col> <col> Varchar </col> <col> 3 </col>
1169     <col>
1170       New status that will be given to a notification when this action takes place.
1171       If the action occurs the status in the notification can change because of this.
1172       The statuscode will indicate what the new status has to be.
1173       If this field is left empty no change to the status will occur.
1174     </col>
1175   </row>
1176   <row>
1177     <col> description </col> <col> Text </col> <col> <para/> </col>
1178     <col>
1179       A longer description (without limit) on the action.
1180     </col>
1181   </row>
1182 </table>
1183 </para>
1184
1185 </subsubsection>
1186
1187 <subsubsection>
1188   <heading>The indexes.</heading>
1189
1190 <para>
1191 Indices for this table are:
1192 </para>
1193     <table cpos='lll'>
1194       <thead>
1195         <col> Indexname </col> <col> Field </col> <col> Characteristics </col>
1196       </thead>
1197       <row>
1198         <col> act_pk </col> <col> actionID </col> <col> Primary key </col>
1199       </row>
1200       <row>
1201         <col> act_actionname </col> <col> actionname </col> <col> Unique </col>
1202       </row>
1203       <row>
1204         <col> act_statuscode </col> <col> statuscode </col> <col> <para/> </col>
1205       </row>
1206     </table>
1207     <para/>
1208
1209 </subsubsection>
1210 <subsubsection>
1211   <heading>The relationships.</heading>
1212
1213 <para>
1214 Relationships with other tables:
1215 </para>
1216     <table cpos='llp{7cm}'>
1217       <thead>
1218         <col> Fieldname </col> <col> Remote Table </col> <col> Remarks </col>
1219       </thead>
1220       <row>
1221         <col> actionid </col> <col> action_notification_user </col>
1222         <col>
1223           Each action that takes placed will be stored. The Actionid will bring
1224           classification to the individual records (that reflect what it means if the action-occurred).
1225           This relationship has to be enforced.
1226         </col>
1227       </row>
1228     </table>
1229     <para>In the model this looks like this:</para>
1230     <para>
1231       <picture src="erd-action.png" eps="erd-action"/>
1232     </para>
1233 </subsubsection>
1234
1235 <subsubsection>
1236   <heading>Default data in table.</heading>
1237
1238 <para>
1239 The data in this table is standard for the system and part of the design.
1240 The user cannot change this or add value to it.
1241 </para>
1242
1243 <table cpos='p{1cm}p{2cm}p{1.5cm}p{6cm}'>
1244   <thead>
1245     <col>Actionid</col><col>Actionname</col><col>Statuscode</col>
1246     <col>
1247       Description
1248     </col>
1249   </thead>
1250   <row>
1251     <col>1</col><col>Entry in the system</col><col>NEW</col>
1252     <col>
1253       This indicates that a notification is entered into the system. The status is a <strong>NEW</strong>.
1254     </col>
1255   </row>
1256   <row>
1257     <col>2</col><col>Displayed to user</col><col>OPN</col>
1258     <col>
1259       The notification has been displayed to the user.
1260       It is not guaranteed that the user has read the notification,
1261       but he/she should be aware of it.
1262       The status will now be changed to <strong>OPEN</strong> if the current
1263       status is <strong>NEW</strong>.
1264     </col>
1265   </row>
1266   <row>
1267     <col>3</col><col>Remarks added</col><col>PEN</col>
1268     <col>
1269       Remarks have been added to the notification. The status has now been
1270       changed to <strong>PENDING</strong>.
1271     </col>
1272   </row>
1273   <row>
1274     <col>4</col><col>Priority changed manually</col><col>PEN</col>
1275     <col>
1276       The priority of the notification has been changed by the user.
1277       The new status is now <strong>PENDING</strong>.
1278     </col>
1279   </row>
1280   <row>
1281     <col>5</col><col>Priority changed automatically</col><col>PEN</col>
1282     <col>
1283       The priority of the notification has been changed by the system.
1284       If the status is not <strong>OPEN</strong> or <strong>NEW</strong> the new
1285       status is become <strong>PENDING</strong>.
1286     </col>
1287   </row>
1288   <row>
1289     <col>6</col><col>Action taken</col><col>PEN</col>
1290     <col>
1291       A action has been taken. The status is now <strong>PENDING</strong>.
1292     </col>
1293   </row>
1294   <row>
1295     <col>7</col><col>Assignment to user</col><col>PEN</col>
1296     <col>
1297       A notification has been explicitly assigned to another user.
1298       The status is now <strong>PENDING</strong>.
1299     </col>
1300   </row>
1301   <row>
1302     <col>8</col><col>More information or research needed.</col><col>INV</col>
1303     <col>
1304       The notification is relevant and will be handled, however more information
1305       or research will be needed. The status is <strong>UNDER INVESTIGATION</strong>.
1306     </col>
1307   </row>
1308   <row>
1309     <col>9</col><col>Make output reference.</col><col>REF</col>
1310     <col>
1311       Automated output from an object has been sent to gnucomo.
1312       The input has been identified as a valid reference for future.
1313       Status is now <strong>REFERENCE</strong><footnote>A reference is used to
1314       find differences in output. This feature must reduce the number of wrongful alerts.
1315       Only if a change has taken place a notification is generated.
1316       First time reports will always generate a notification.
1317       By signing this off the system will be silent again.</footnote>.
1318     </col>
1319   </row>
1320   <row>
1321     <col>10</col><col>Job output no longer reference.</col><col>CLS</col>
1322     <col>
1323       By making a newer job output reference this output has been obsoleted.
1324       Since once it was a reference the notification can be closed.
1325       The new status for the notification is now <strong>CLOSED</strong>.
1326     </col>
1327   </row>
1328   <row>
1329     <col>11</col><col>Action taken please verify.</col><col>VRF</col>
1330     <col>
1331       An action has been taken and things should have been resolved.
1332       Before the notification can be closed a verification has to be done.
1333       New status is now <strong>VERIFY</strong>.
1334     </col>
1335   </row>
1336   <row>
1337     <col>12</col><col>Action not accepted.</col><col>PEN</col>
1338     <col>
1339       A check has been done and the results were not good.
1340       New verification is needed.
1341       New status is now <strong>PENDING</strong>.
1342     </col>
1343   </row>
1344   <row>
1345     <col>13</col><col>Action verified</col><col>CLS</col>
1346     <col>
1347       The verification for the action has been done and the action is approved.
1348       The new status is now <strong>CLOSED</strong>.
1349     </col>
1350   </row>
1351   <row>
1352     <col>14</col><col>E-mail sent</col>
1353       <col>OPN<footnote>Only if the status is <strong>NEW</strong>.</footnote></col>
1354     <col>
1355       An e-mail has been sent.
1356     </col>
1357   </row>
1358   <row>
1359     <col>15</col><col> SMS sent </col>
1360       <col>OPN<footnote>Only if the status is <strong>NEW</strong>.</footnote></col>
1361     <col>
1362       A SMS has been sent.
1363     </col>
1364   </row>
1365   <row>
1366     <col>16</col><col>Fax sent</col>
1367       <col>OPN<footnote>Only if the status is <strong>NEW</strong>.</footnote></col>
1368     <col>
1369       A fax has been sent.
1370     </col>
1371   </row>
1372   <row>
1373     <col>17</col><col>Log-entries shown</col><col>XXXX</col>
1374     <col>
1375       The log entries have been shown. No changes to the status made.
1376     </col>
1377   </row>
1378   <row>
1379     <col>18</col><col>Notification closed</col><col>CLS</col>
1380     <col>
1381       Notification has been closed.
1382     </col>
1383   </row>
1384   <row>
1385     <col>19</col><col>Notification reopened</col><col>OPN</col>
1386     <col>
1387       Notification has been re-opened
1388     </col>
1389   </row>
1390 </table>
1391 </subsubsection>
1392
1393 </subsection>
1394
1395 <subsection>
1396    <heading>Action_user.</heading>
1397
1398 <para>
1399 This table stores each actual action taken.
1400 Where the action basically stores the type of actions that can be taken,
1401 this table says 'at this point in time for this notification this action was taken'.
1402 Using this table it is traceable who did what at which moment in time.
1403 The table is very important for later use if
1404 something goes wrong, but is also relevant for the interface.
1405 All steps of a in the process of a notification can be traced using this table.
1406 There will be a lot of entries here, but retrieval is more crucial for
1407 performance than data entry. So indexing on logic fields is very relevant.
1408 Processing might be slower, but that's worth the price.
1409 </para>
1410
1411 <subsubsection>
1412   <heading>The fields.</heading>
1413
1414 <para>
1415 The table below describes the fields:
1416 </para>
1417
1418 <table cpos='lllp{6cm}'>
1419   <thead>
1420     <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
1421     <col>
1422       Remarks
1423     </col>
1424   </thead>
1425   <row>
1426     <col> actionstepid </col> <col> Bigserial </col> <col> 8 </col>
1427     <col>
1428       Autonumber bigint (eight bit). A unique identifyer to indicate each step in the process.
1429     </col>
1430   </row>
1431   <row>
1432     <col> actionid </col> <col> Bigint </col> <col> 8 </col>
1433     <col>
1434       Reference to the action that is being registered here. This field refers to the actual action taken.
1435     </col>
1436   </row>
1437   <row>
1438     <col> username </col> <col> Text </col> <col> <para/> </col>
1439     <col>
1440       The username of the user that is involved in the action. This field refers to the table <strong>usr</strong>
1441     </col>
1442   </row>
1443   <row>
1444     <col> notificationid </col> <col> Bigint </col> <col> 8 </col>
1445     <col>
1446       Reference to the notification. This will link the action to the notification.
1447     </col>
1448   </row>
1449   <row>
1450     <col> timestamp </col> <col> Timestamp </col> <col> <para/> </col>
1451     <col>
1452       The time when the action has been entered into the system.
1453       This is the time without the timezone<footnote>The timestamp without
1454       time has been selected, since this is the system time.
1455       To have the system functioning without any physical borders one
1456       of the settings on the system is time in GMT (UTC).
1457       This ensures also the added value of the system log.</footnote>.
1458       This will be automatically added when the record is added into the database.
1459     </col>
1460   </row>
1461   <row>
1462     <col> statuscode </col> <col> Varchar </col> <col> 3 </col>
1463     <col>
1464       The status of the Notification AFTER this action has been taken.
1465     </col>
1466   </row>
1467   <row>
1468     <col> remarks </col> <col> Text </col> <col> <para/> </col>
1469     <col>
1470       Remarks entered by the user if it concerns a manual action
1471       or the text of automatically generated warnings.
1472     </col>
1473   </row>
1474 </table>
1475
1476 </subsubsection>
1477
1478 <subsubsection>
1479   <heading>The indexes.</heading>
1480
1481 <para>
1482 The table is indexed on the following fields:
1483 </para>
1484
1485 <table cpos='lll'>
1486   <thead>
1487     <col> Indexname </col> <col> Field </col> <col> Characteristics </col>
1488   </thead>
1489   <row>
1490     <col> anu_pk (action_user_actionstepid_key) </col> <col> actionstepid </col>
1491     <col> Primary key </col>
1492   </row>
1493   <row>
1494     <col> anu_actionid </col> <col> actionid </col> <col> <para/> </col>
1495   </row>
1496   <row>
1497     <col> anu_username </col> <col> username </col> <col> <para/> </col>
1498   </row>
1499   <row>
1500     <col> anu_notificationid </col> <col> notificationid </col> <col> <para/> </col>
1501   </row>
1502   <row>
1503     <col> anu_timestamp </col> <col> timestamp </col> <col> <para/> </col>
1504   </row>
1505   <row>
1506     <col> anu_statuscode </col> <col> statuscode </col> <col> <para/> </col>
1507   </row>
1508 </table>
1509 </subsubsection>
1510
1511 <subsubsection>
1512   <heading>The relationships.</heading>
1513
1514 <para>
1515 Relationships with other tables:
1516 </para>
1517 <table cpos='llp{7cm}'>
1518   <thead>
1519     <col> Fieldname </col> <col> Remote Table </col>
1520     <col> Remarks </col>
1521   </thead>
1522   <row>
1523     <col> actionid </col> <col> action </col>
1524     <col>
1525       Indicates the action that has been taken. The relationship has to be enforced.
1526     </col>
1527   </row>
1528   <row>
1529     <col> notificationid </col> <col> notification </col>
1530     <col>
1531       Each action that takes place is registered in this table.
1532       By using the notification the relevant notification. The relationship has to be enforced.
1533     </col>
1534   </row>
1535   <row>
1536     <col> username </col> <col> user </col>
1537     <col>
1538       Each step in the process has to be related to the user.
1539       If the system itself generates an action the user will be
1540       <strong>gnucomo</strong><footnote>This implies that the system
1541       automatically has an username gnucomo.</footnote>.
1542     </col>
1543   </row>
1544 </table>
1545
1546 <para>
1547 In the model this looks like this:
1548 </para>
1549 <para>
1550 <picture src="erd-anu.png" eps="erd-anu"/>
1551 </para>
1552
1553 </subsubsection>
1554
1555 <subsubsection>
1556   <heading>Sample data.</heading>
1557
1558 <para>
1559 Since no data is delivered automatically a couple of sample records are shown here.
1560 </para>
1561
1562     <table cpos='p{1cm}p{1cm}p{1cm}lllp{4cm}'>
1563       <thead>
1564         <col> Actionstepid </col> <col> Actionid </col> <col> Notificationid </col>
1565         <col> Username </col> <col> Timestamp </col> <col> Status </col>
1566         <col> Remarks </col>
1567       </thead>
1568       <row>
1569         <col> 1 </col> <col> 1 </col> <col> 1 </col> <col> Gnucomo </col>
1570         <col> 2002-07-14 16:14:09 </col> <col> NEW </col>
1571         <col>
1572           Gnucomo detected a portscan
1573         </col>
1574       </row>
1575       <row>
1576         <col> 2 </col> <col> 5 </col> <col> 1 </col> <col> Gnucomo </col>
1577         <col> 2002-07-14 16:14:09 </col> <col> NEW </col>
1578         <col>
1579           Priority set to: 3
1580         </col>
1581       </row>
1582       <row>
1583         <col> 3 </col> <col> 5 </col> <col> 1 </col> <col> Gnucomo </col>
1584         <col> 2002-07-14 16:14:09 </col> <col> OPN </col>
1585         <col>
1586           <para>Automatic e-mail to user:
1587       <reference href="mailto:brenno@dewinter.com">brenno@dewinter.com</reference>:</para>
1588           <para>Gnucomo detected a portscan on system
1589       <reference href="http://gnucomo.dewinter.com/">gnucomo.dewinter.com</reference></para>
1590         </col>
1591       </row>
1592       <row>
1593         <col> 4 </col> <col> 2 </col> <col> 1 </col> <col> Brenno </col>
1594         <col> 2002-07-14 16:18:09 </col> <col> OPN </col>
1595         <col>
1596           Notification shown through webinterface.
1597         </col>
1598       </row>
1599       <row>
1600         <col> 5 </col> <col> 17 </col> <col> 1 </col> <col> Brenno </col>
1601         <col> 2002-07-14 16:18:12 </col> <col> PEN </col>
1602         <col>
1603           <para/>
1604         </col>
1605       </row>
1606       <row>
1607         <col> 6 </col> <col> 4 </col> <col> 1 </col> <col> Brenno </col>
1608         <col> 2002-07-14 16:20:37 </col> <col> PEN </col>
1609         <col>
1610           Priority set to: 1
1611         </col>
1612       </row>
1613       <row>
1614         <col> 7 </col> <col> 3 </col> <col> 1 </col> <col> Brenno </col>
1615         <col> 2002-07-1416:21:58 </col> <col> PEN </col>
1616         <col>
1617           After reviewing the logs I see a portscan. On very specific ports. More analysis needed.
1618         </col>
1619       </row>
1620       <row>
1621         <col> 8 </col> <col> 3 </col> <col> 1 </col> <col> Brenno </col>
1622         <col> 2002-07-14 16:24:59 </col> <col> PEN </col>
1623         <col>
1624           Services tables learns me that all services are aimed at Windows-based services.
1625       Attempts for platform specific expoits.
1626         </col>
1627       </row>
1628       <row>
1629         <col> 9 </col> <col> 4 </col> <col> 1 </col> <col> Brenno </col>
1630         <col> 2002-07-14 16:25:03 </col> <col> PEN </col>
1631         <col>
1632           Priority set to: 4
1633         </col>
1634       </row>
1635       <row>
1636         <col> 10 </col> <col> 2 </col> <col> 1 </col> <col> Brenno </col>
1637         <col> 2002-07-14 16:30:09 </col> <col> PEN </col>
1638         <col>
1639           Notification shown through webinterface.
1640         </col>
1641       </row>
1642       <row>
1643         <col> 11 </col> <col> 3 </col> <col> 1 </col> <col> Brenno </col>
1644         <col> 2002-07-14 16:31:48 </col> <col> PEN </col>
1645         <col>
1646           Portscan has finished and no other action seems to take place now.
1647         </col>
1648       </row>
1649       <row>
1650         <col> 12 </col> <col> 18 </col> <col> 1 </col> <col> Brenno </col>
1651         <col> 2002-07-14 16:43:03 </col> <col> CLS </col>
1652         <col>
1653           <para/>
1654         </col>
1655       </row>
1656     </table>
1657     </subsubsection>
1658 </subsection>
1659
1660 <subsection>
1661 <heading>history</heading>
1662 <para>
1663 The history table records all changes to properties of parameters.
1664 </para>
1665
1666 <subsubsection>
1667 <heading>The fields</heading>
1668 <para>
1669 The fields of the <emph>history</emph> table are listed below:
1670 </para>
1671 <table cpos='lllp{6cm}'>
1672       <thead>
1673         <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
1674         <col> Remarks </col>
1675       </thead>
1676       <row>
1677         <col>paramid</col><col>bigint</col><col>8</col>
1678         <col>The parameter to which this history belongs. Refers to the parameter table</col>
1679       </row>
1680       <row>
1681         <col>modified</col><col>timestamp</col><col> </col>
1682         <col>Time at which the property value or parameter changed</col>
1683       </row>
1684       <row>
1685         <col>change_nature</col><col>enum</col><col> </col>
1686         <col>Parameter created to destroyed; property value changed</col>
1687       </row>
1688       <row>
1689         <col>changed_property</col><col>text</col><col> </col>
1690         <col>Name of the parameter's property that changed.</col>
1691       </row>
1692       <row>
1693         <col>new_value</col><col>text</col><col> </col>
1694         <col>The new actual value of the property at the time of modification</col>
1695       </row>
1696       <row>
1697         <col>remark</col><col>text</col><col> </col>
1698         <col>A short explanation of why the property changed</col>
1699       </row>
1700 </table>
1701
1702 <para>
1703 Each time something about a parameter changes, this is recorded in the
1704 change history of the paraneter.
1705 When such a change happens, one of three things may occur to a parameter,
1706 as stated in the 'change_nature' field:
1707
1708 <enumerate>
1709 <item>A new parameter is created.</item>
1710 <item>The value of one of the properties was altered.</item>
1711 <item>The parameter is removed.</item>
1712 </enumerate>
1713
1714 When  a parameter is created or destroyed, the fields 'changed_property' and
1715 'new_value' are irrelevant.
1716 </para>
1717
1718 </subsubsection>
1719 </subsection>
1720
1721 <subsection>
1722   <heading>log &amp; log_adv. </heading>
1723
1724 <para>
1725 To store the log-data there are two tables in use that have a one-on-one relationship.
1726 The logic behind this is the difference between raw-always needed data and the somewhat
1727 processed data to support basic retrieval.
1728 The last category isn't always used and when it's used it is redundant.
1729 Also the raw log is very important to the integrity of the system.
1730 For these reasons the processed data has been physically separated in a
1731 second table called <emph>log_adv</emph>.
1732 If needed a view will be available that combines the two tables.
1733 Despite the load indexing on <emph>log_adv</emph> will be done thoroughly.
1734 </para>
1735 </subsection>
1736
1737 <subsection>
1738   <heading>log.</heading>
1739
1740 <subsubsection>
1741   <heading>The fields of log.</heading>
1742
1743 <para>
1744 The fields in log are focussed around the raw data arriving from log-files and output
1745 from processes that deliver status information.
1746 The log table is the one and only place used to automatically deliver data to the gnucomo-system.
1747 This makes the facts very traceable and ensures that there is one point where the data isn't
1748 yet fragmented (usefull if new insights are usefull). The log table also provides the
1749 integrity of the data as it was delivered. The data will be needed to provide 
1750 a link to other tables in the system that handle processed derrivates of the
1751 original data (added intelligence).
1752 </para>
1753
1754 <table cpos='lllp{6cm}'>
1755   <thead>
1756     <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
1757     <col>
1758       Remarks
1759     </col>
1760   </thead>
1761   <row>
1762     <col> logid </col> <col> Bigserial </col> <col> 8 </col>
1763     <col>
1764       Autonumber bigint (eight bit)
1765     </col>
1766   </row>
1767   <row>
1768     <col> objectid </col> <col> Bigint </col> <col> 8 </col>
1769     <col>
1770       Reference to the object that submitted this log entry
1771     </col>
1772   </row>
1773   <row>
1774     <col> original_filename </col> <col> Text </col> <col> <para/> </col>
1775     <col>
1776       This field refers to the filename that contained this entry.
1777       The original entries as received by the gnucomo-server (flat files).
1778       The files are sent in batches, which makes it very hard to find where the
1779       original logline is. This will enable to see the files to detect
1780       bugs in gnucomo if any occur.
1781       It may well be that in a later stage this functionality becomes obsolete.
1782     </col>
1783   </row>
1784   <row>
1785     <col> servicecode </col> <col> Text </col> <col> <para/> </col>
1786     <col>
1787       This field explains what service was recognized (for instance 'kernel, 'httpd' or 'smtp')
1788       this make later processing easier.
1789     </col>
1790   </row>
1791   <row>
1792     <col> type_of_logid </col> <col> Bigint </col> <col> 8 </col>
1793     <col>
1794       Reference to the table type_of_log that contains information on what
1795       type of log/report we have here (how gnucomo recognized it).
1796     </col>
1797   </row>
1798   <row>
1799     <col> object_timestamp </col> <col> Timestamp </col> <col> 8 </col>
1800     <col>
1801       Timestamp of the moment the data was written into the log-file itself.
1802       This is the time on the remote system. 
1803     </col>
1804   </row>
1805   <row>
1806     <col> timestamp </col> <col> Timestamp </col> <col> <para/> </col>
1807     <col>
1808       The time when the action has been entered into the system.
1809       This is the time without the timezone<footnote>The timestamp without time
1810       has been selected, since this is the system time.
1811       To have the system functioning without any physical borders one of
1812       the settings on the system is time in GMT (UTC).
1813       This ensures also the added value of the system log.</footnote>.
1814       This will be generated upon entry into the database.
1815     </col>
1816   </row>
1817   <row>
1818     <col> rawdata </col> <col> TEXT </col> <col> <para/> </col>
1819     <col>
1820       The raw log data as it was handed to gnucomo. 
1821     </col>
1822   </row>
1823   <row>
1824     <col>processed</col><col>BOOLEAN </col> <col> <para/> </col>
1825     <col>This record is a flag (true or false).
1826       If a record that has been entered into the log-table has been processed
1827       (mostly into several log_adv-tables) this flag is set to true.
1828       The flag indicates that gcm_daemon processed the record.
1829       This doesn't nescessarily mean that they have been used.
1830       By default the setting is false.
1831       So the flag helps in the detection of new arrivals in the log-table.</col>
1832   </row>
1833   <row>
1834    <col>recognized</col><col>BOOLEAN</col> <col><para/> </col>
1835    <col>This record is a flag (true or false).
1836       If the processing by gcm_daemon of this particular record has been done the flag
1837       will only be set to true when gcm_daemon could process the record.
1838       If there was no support for this particular entry the status remains false.
1839       The main aim of this functionality is relevant when a new version of the daemon is present.
1840       Unrecognized records will then be transferred to unprocessed again and a
1841       new attempt will be made to process these records.</col>
1842   </row>
1843 </table>
1844 </subsubsection>
1845
1846 <subsubsection>
1847   <heading>The indexes.</heading>
1848
1849 <para>
1850 The indices of the table:
1851 </para>
1852
1853 <table cpos='lll'>
1854   <thead>
1855     <col> Indexname </col> <col> Field </col> <col> Characteristics </col>
1856   </thead>
1857   <row>
1858     <col> log_pk (log_logid_key) </col> <col> logid </col> <col> Primary key </col>
1859   </row>
1860   <row>
1861     <col> log_objectid </col> <col> objectid </col> <col> <para/> </col>
1862   </row>
1863   <row>
1864     <col> log_original_filename </col> <col> original_filename </col> <col> <para/> </col>
1865   </row>
1866   <row>
1867     <col> log_servicecode </col> <col> servicecode </col> <col> <para/> </col>
1868   </row>
1869   <row>
1870     <col> log_type_of_logid </col> <col> type_of_logid </col> <col> <para/> </col>
1871   </row>
1872   <row>
1873     <col> log_object_timestamp </col> <col> object_timestamp </col> <col> <para/> </col>
1874   </row>
1875   <row>
1876     <col> log_timestamp </col> <col> timestamp </col> <col> <para/> </col>
1877   </row>
1878 </table>
1879 </subsubsection>
1880
1881 <subsubsection>
1882   <heading>The relationships.</heading>
1883
1884 <para>
1885 Relationships with other tables:
1886 </para>
1887
1888 <table cpos='llp{6cm}'>
1889   <thead>
1890     <col> Fieldname </col> <col> Remote Table </col>
1891     <col>
1892       Remarks
1893     </col>
1894   </thead>
1895   <row>
1896     <col> objectid </col> <col> object </col>
1897     <col>
1898       This make the link from what object the logline came
1899     </col>
1900   </row>
1901   <row>
1902     <col> type_of_logid </col> <col> type_of_log </col>
1903     <col>
1904       Each logbook has a certain type of reporting.
1905       This explains what type of log was received (and thus which rules for detection was applied).
1906     </col>
1907   </row>
1908   <row>
1909     <col> systemuser </col> <col> user </col>
1910     <col>
1911       Links a registered user of an object to this log
1912       entry<footnote>Upon entry of an object most of the times the
1913       passwd-file (UNIX-systems) or the userlist will serve as the entrypoint of users.
1914       Non existing users will be added and will have to be verified by an
1915       administrator before this entry become definite.</footnote>.
1916     </col>
1917   </row>
1918 </table>
1919
1920 <para>In the model this looks like this:</para>
1921     
1922 <para>
1923   <picture src="erd-log.png" eps="erd-log"/>
1924 </para>
1925
1926     
1927 </subsubsection>
1928 <subsubsection>
1929 <heading>Log_adv</heading>
1930 <para>
1931 As soon as new data is detected in the log-table processing takes place.
1932 If the data is recognized by the gcm_daemon one or more log_adv records
1933 will be written where data is separated. Due to the high diversity multiple
1934 types of the log_adv table will be created.
1935 All of them will be an inheritance of the log_adv-table.
1936 </para>
1937 </subsubsection>
1938 <subsubsection>
1939   <heading>The fields of log_adv.</heading>
1940
1941 <para>
1942 The fields of the table <emph>log_adv</emph> are shown below:
1943 </para>
1944
1945 <table cpos='lllp{6cm}'>
1946   <thead>
1947     <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
1948     <col>
1949       Remarks
1950     </col>
1951   </thead>
1952   <row>
1953     <col>log_advid</col><col>Bigint autonumber</col><col>8</col>
1954     <col>Since some records can generate several log_adv records a unique identifyer is needed.
1955           This record provides that.
1956     </col>
1957   </row>
1958   <row>
1959     <col> logid </col> <col> Bigint </col> <col> 8 </col>
1960     <col>
1961       Bigint (eight bit) 1-to-1 relationship with log
1962     </col>
1963   </row>
1964 </table>
1965
1966 </subsubsection>
1967
1968 <subsubsection>
1969   <heading>The indexes.</heading>
1970
1971 <para>
1972 The table is indexed on the following fields:
1973 </para>
1974
1975 <table cpos='lll'>
1976   <thead>
1977     <col> Indexname </col> <col> Field </col> <col> Characteristics </col>
1978   </thead>
1979   <row>
1980     <col> loa_logid </col> <col> logid </col> <col> Primary key </col>
1981   </row>
1982   <row>
1983     <col> loa_source_ip </col> <col> source_ip </col> <col> <para/> </col>
1984   </row>
1985   <row>
1986     <col> loa_destination_ip </col> <col> destination_ip </col> <col> <para/> </col>
1987   </row>
1988   <row>
1989     <col> loa_mac_address </col> <col> mac_address </col> <col> <para/> </col>
1990   </row>
1991   <row>
1992     <col> loa_packetlength </col> <col> packetlength </col> <col> <para/> </col>
1993   </row>
1994   <row>
1995     <col> loa_protocol </col> <col> protocol </col> <col> <para/> </col>
1996   </row>
1997   <row>
1998     <col> loa_source_port </col> <col> source_port </col> <col> <para/> </col>
1999   </row>
2000   <row>
2001     <col> loa_destination_port </col> <col> destination_port </col> <col> <para/> </col>
2002   </row>
2003   <row>
2004     <col> loa_messageid </col> <col> messageid </col> <col> <para/> </col>
2005   </row>
2006   <row>
2007     <col> loa_system_username </col> <col> system_username </col> <col> <para/> </col>
2008   </row>
2009   <row>
2010     <col> networkdevice </col> <col> networkdevice </col> <col> <para/> </col>
2011   </row>
2012 </table>
2013 </subsubsection>
2014
2015 <subsubsection>
2016   <heading>The relationships.</heading>
2017
2018 <para>
2019 There is only one relation with this table.
2020 </para>
2021
2022 <table cpos='llp{6cm}'>
2023   <thead>
2024     <col> Fieldname </col> <col> Remote Table </col>
2025     <col>
2026       Remarks
2027     </col>
2028   </thead>
2029   <row>
2030     <col> Logid </col> <col> Log </col>
2031     <col>
2032       This will make a link to the table <emph>log</emph>. The relationship is a one-on-one relationship.
2033     </col>
2034   </row>
2035 </table>
2036 </subsubsection>
2037
2038 <subsubsection>
2039   <heading>Sample data combined from log and log_adv.</heading>
2040
2041 <para>
2042 The sample data derrived here has been gathered in logs.
2043 Since the tablestructure is very long the representation is somewhat different:
2044 </para>
2045
2046 <table cpos='lp{8cm}'>
2047   <thead>
2048     <col> Fieldname </col> <col> Value.  </col>
2049   </thead>
2050   <row>
2051     <col> Logid </col> <col> 1 </col>
2052   </row>
2053   <row>
2054     <col> Objectid </col> <col> 1 </col>
2055   </row>
2056   <row>
2057     <col> Original_filename </col> <col> 7f0100.messages.20020714231801 </col>
2058   </row>
2059   <row>
2060     <col> Rawdata </col>
2061     <col>
2062       Jul 14 18:16:42 webber kernel: IN=eth0 OUT= MAC=00:60:67:36:61:a5:00:90:69:60:c0:5d:08:00 SRC=193.79.237.146 DST=212.204.216.11 LEN=40 TOS=0x00 PREC=0x00 TTL=245 id=19308 DF PROTO=TCP SPT=36375 DPT=113 WINDOW=8760 RES=0x00 RST URGP=0
2063     </col>
2064   </row>
2065   <row>
2066     <col> Type_of_logid </col> <col> 1 </col>
2067   </row>
2068   <row>
2069     <col> Timestamp </col> <col> 2002-07-14 23:29:01 </col>
2070   </row>
2071   <row>
2072     <col> Object_timestamp </col> <col> 2002-07-14 18:16:42 </col>
2073   </row>
2074   <row>
2075     <col> Source_ip </col> <col> 193.79.237.146 </col>
2076   </row>
2077   <row>
2078     <col> Destination_ip </col> <col> 212.204.216.11 </col>
2079   </row>
2080   <row>
2081     <col> Mac_address </col> <col> 00:60:67:36:61:a5:00:90:69:60:c0:5d:08:00 </col>
2082   </row>
2083   <row>
2084     <col> Packetlength </col> <col> 40 </col>
2085   </row>
2086   <row>
2087     <col> Protocol </col> <col> TCP </col>
2088   </row>
2089   <row>
2090     <col> Source_port </col> <col> 36375 </col>
2091   </row>
2092   <row>
2093     <col> Destination_port </col> <col> 113 </col>
2094   </row>
2095   <row>
2096     <col> Messageid </col> <col> <para/> </col>
2097   </row>
2098   <row>
2099     <col> Systemuser </col> <col> <para/> </col>
2100   </row>
2101   <row>
2102     <col> Networkdevice </col> <col> eth0 </col>
2103   </row>
2104 </table>
2105 </subsubsection>
2106 </subsection>
2107
2108 <subsection>
2109   <heading>log_notification. </heading>
2110
2111 <para>
2112 In the log_notification the logbook entries that have caused an alert to occur are saved.
2113 When this table is used something has been detected.
2114 As this is clearly an intermediate table we anticipate to design checks where
2115 multiple entries in a log-file can lead to one notification.
2116 For forensics indexing will be focussed on retrieval speed.
2117 </para>
2118
2119 <subsubsection>
2120   <heading>The fields.</heading>
2121
2122 <para>
2123 The fields are listed below:
2124 </para>
2125
2126 <table cpos='lllp{6cm}'>
2127   <thead>
2128     <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
2129     <col>
2130       Remarks
2131     </col>
2132   </thead>
2133   <row>
2134     <col> notificationid </col> <col> Bigint </col> <col> 8 </col>
2135     <col>
2136       Reference to the notification
2137     </col>
2138   </row>
2139   <row>
2140     <col> logid </col> <col> Bigint </col> <col> 8 </col>
2141     <col>
2142       Reference to the logbook
2143     </col>
2144   </row>
2145 </table>
2146
2147 </subsubsection>
2148 <subsubsection>
2149   <heading>The indexes.</heading>
2150
2151 <para>
2152 The table is indexed on the following fields:
2153 </para>
2154 <table cpos='lll'>
2155   <thead>
2156     <col> Indexname </col> <col> Field </col> <col> Characteristics </col>
2157   </thead>
2158   <row>
2159     <col> lon_pk </col> <col>notificationid </col> <col>Primary key </col>
2160   </row>
2161   <row>
2162     <col> <para/> </col> <col>logid </col> <col>Primary key (second field) </col>
2163   </row>
2164   <row>
2165     <col>lon_notificationid </col> <col> notificationid </col> <col> <para/> </col>
2166   </row>
2167   <row>
2168     <col> lon_logid </col> <col>logid </col> <col> <para/> </col>
2169   </row>
2170 </table>
2171 </subsubsection>
2172
2173 <subsubsection>
2174   <heading>The relationships.</heading>
2175
2176 <para>
2177 Relationships with other tables:
2178 </para>
2179
2180 <table cpos='llp{8cm}'>
2181   <thead>
2182     <col> Fieldname </col> <col> Remote Table </col>
2183     <col>
2184       Remarks
2185     </col>
2186   </thead>
2187   <row>
2188     <col> Logid </col> <col> Log </col>
2189     <col>
2190       Indicates the log-entry that was on of the triggers that led to the notification.
2191     </col>
2192   </row>
2193   <row>
2194     <col> NotificationID </col> <col> Notification </col>
2195     <col>
2196       Indicates the notification where the entry in the log was a trigger.
2197     </col>
2198   </row>
2199 </table>
2200
2201 <para>In the model this look like this:</para>
2202 <para>
2203   <picture src="erd-lognotif.png" eps="erd-lognotif"/>
2204 </para>
2205 </subsubsection>
2206
2207 <subsubsection>
2208   <heading>Sample data.</heading>
2209 <para>
2210 Some sample data:
2211 </para>
2212
2213 <table cpos='ll'>
2214   <thead>
2215     <col> LogID </col> <col> NotificationID </col>
2216   </thead>
2217   <row>
2218     <col> 4 </col> <col> 1 </col>
2219   </row>
2220   <row>
2221     <col> 5 </col> <col> 1 </col>
2222   </row>
2223   <row>
2224     <col> 8 </col> <col> 1 </col>
2225   </row>
2226   <row>
2227     <col> 9 </col> <col> 1 </col>
2228   </row>
2229   <row>
2230     <col> 5 </col> <col> 2 </col>
2231   </row>
2232   <row>
2233     <col> 6 </col> <col> 2 </col>
2234   </row>
2235   <row>
2236     <col> 11 </col> <col> 2 </col>
2237   </row>
2238 </table>
2239 </subsubsection>
2240 </subsection>
2241
2242 <subsection>
2243   <heading>notification. </heading>
2244
2245 <para>
2246 In this table all detected issues per object will be written.
2247 Issues are entered based on immediate detection, periodical detection or manually.
2248 Since this table is mostly used to work from in the interface being in control is crucial.
2249 When systems function properly more retrieval than data entry will take place.
2250 Also data retrieval will be done in all sorts of ways. Indexing must be huge to facilitate that.
2251 </para>
2252
2253 <subsubsection>
2254   <heading>The fields.</heading>
2255
2256 <para>
2257 The fields of the <emph>notification</emph> table are:
2258 </para>
2259
2260 <table cpos='lllp{6cm}'>
2261   <thead>
2262     <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
2263     <col>
2264       Remarks
2265     </col>
2266   </thead>
2267   <row>
2268     <col> notificationid </col> <col> Bigserial </col> <col> 8 </col>
2269     <col>
2270       Autonumber
2271     </col>
2272   </row>
2273   <row>
2274     <col> objectid </col> <col> Bigint </col> <col> 8 </col>
2275     <col>
2276       Reference to the <emph>object</emph>
2277     </col>
2278   </row>
2279   <row>
2280     <col> type_of_notification_id </col> <col> Bigint </col> <col> 8 </col>
2281     <col>
2282       Reference to the <emph>type_of_notification</emph> indicating what
2283       type of notification we have here and what basic rules apply.
2284     </col>
2285   </row>
2286   <row>
2287     <col> timestamp </col> <col> Timestamp </col> <col> <para/> </col>
2288     <col>
2289       Timestamp that this notification was created.
2290     </col>
2291   </row>
2292   <row>
2293     <col> statuscode </col> <col> Varchar </col> <col> 3 </col>
2294     <col>
2295       The status the actual status a notification has.
2296     </col>
2297   </row>
2298   <row>
2299     <col> priority </col> <col> Int </col> <col> 4 </col>
2300     <col>
2301       The priority that is given to this issue<footnote>Basically there will be
2302       five priority levels. The rule is that the lower the number gets the more
2303       urgent the issue is. At the moment the priority level is set by the system
2304       pre-defined actions will take place.</footnote>.
2305     </col>
2306   </row>
2307   <row>
2308     <col> escalation_count_timestamp </col> <col> Timestamp </col> <col> <para/> </col>
2309     <col>
2310       Timestamp since the last escalation took place<footnote>The system offers
2311       the possibility to automatically escalate issue if no action has been
2312       taken within a certain amount of time.
2313       Based on the status and the type of notification escalation can take place.</footnote>.
2314     </col>
2315   </row>
2316   <row>
2317     <col> repeat_notification_timestamp </col> <col> Timestamp </col> <col> <para/> </col>
2318     <col>
2319       Timestamp at which moment in time a repeat notification should occur<footnote>After
2320       this time has passed a notification is being resent.
2321       After a resent automatically a new time is set for another resent.
2322       If any actions takes place (except automated entries of course)
2323       the time is emptied so that an administrator will no longer be bothered by the system.</footnote>.
2324     </col>
2325   </row>
2326   <row>
2327     <col> securitylevel_view </col> <col> Int </col> <col> 4 </col>
2328     <col>
2329       The securitylevel that is needed to view this entry.
2330     </col>
2331   </row>
2332   <row>
2333     <col> securitylevel_add </col> <col> Int </col> <col> 4 </col>
2334     <col>
2335       Securitylevel to add information to this item or to undertake action
2336     </col>
2337   </row>
2338   <row>
2339     <col> securitylevel_close </col> <col> Int </col> <col> 4 </col>
2340     <col>
2341       The securitylevel needed to be able to close this notification.
2342     </col>
2343   </row>
2344 </table>
2345 </subsubsection>
2346
2347 <subsubsection>
2348   <heading>The indexes.</heading>
2349
2350 <para>
2351 The indices are:
2352 </para>
2353 <table cpos='lll'>
2354   <thead>
2355     <col> Indexname </col> <col> Field </col> <col> Characteristics </col>
2356   </thead>
2357   <row>
2358     <col> not_pk (notification_notificationid_key) </col> <col> notificationid </col>
2359     <col> Primary key </col>
2360   </row>
2361   <row>
2362     <col> not_objectid </col> <col> objectid </col> <col> <para/> </col>
2363   </row>
2364   <row>
2365     <col> not_type_of_notificationid </col> <col> type_of_notificationid </col>
2366     <col> <para/> </col>
2367   </row>
2368   <row>
2369     <col> not_timestamp </col> <col> timestamp </col> <col> <para/> </col>
2370   </row>
2371   <row>
2372     <col> not_statuscode </col> <col> statuscode </col> <col> <para/> </col>
2373   </row>
2374   <row>
2375     <col> not_priority </col> <col> priority </col> <col> <para/> </col>
2376   </row>
2377   <row>
2378     <col> not_escalation_count_timestamp </col> <col> escalation_count_timestamp </col>
2379     <col> <para/> </col>
2380   </row>
2381   <row>
2382     <col>
2383       <para>not_repeat_notification_timestamp</para>
2384       <para>(not_repeat_notification_timesta)</para>
2385     </col>
2386     <col> repeat_notification_timestamp </col> <col> <para/> </col>
2387   </row>
2388 </table>
2389 </subsubsection>
2390
2391 <subsubsection>
2392   <heading>The relationships.</heading>
2393
2394 <para>
2395 Relationships with other tables:
2396 </para>
2397
2398 <table cpos='llp{8cm}'>
2399   <thead>
2400     <col> Fieldname </col> <col> Remote Table </col> <col> Remarks </col>
2401   </thead>
2402   <row>
2403     <col> Logid </col> <col> Log </col>
2404     <col>
2405       Indicates the log-entry that was on of the triggers that led to the notification.
2406     </col>
2407   </row>
2408   <row>
2409     <col> NotificationID </col> <col> Notification </col>
2410     <col>
2411       Indicates the notification where the entry in the log was a trigger.
2412     </col>
2413   </row>
2414 </table>
2415
2416 <para>In the model this look like this:</para>
2417 <para>
2418   <picture src="erd-notif.png" eps="erd-notif"/>
2419 </para>
2420 </subsubsection>
2421
2422 <subsubsection>
2423   <heading>Sample data.</heading>
2424
2425 <para>
2426 The following data is an example of a notification placed in the database.
2427 </para>
2428 <table cpos='ll'>
2429   <thead>
2430     <col> Fieldname </col> <col> Data </col>
2431   </thead>
2432   <row>
2433     <col> Notificationid </col> <col> 1 </col>
2434   </row>
2435   <row>
2436     <col> ObjectID </col> <col> 1 </col>
2437   </row>
2438   <row>
2439     <col> Type_of_notification_id </col> <col> 1 </col>
2440   </row>
2441   <row>
2442     <col> Timestamp </col> <col> 17-07-2002 16:07 </col>
2443   </row>
2444   <row>
2445     <col> Statuscode </col> <col> NEW </col>
2446   </row>
2447   <row>
2448     <col> Priority </col> <col> 3 </col>
2449   </row>
2450   <row>
2451     <col> Escalation_count_timestamp </col> <col> 17-07-2002 16:07 </col>
2452   </row>
2453   <row>
2454     <col> Repeat_notification_timestamp </col> <col> 17-07-2002 20:48PM </col>
2455   </row>
2456   <row>
2457     <col> Securitylevel_view </col> <col> 3 </col>
2458   </row>
2459   <row>
2460     <col> Securitylevel_add </col> <col> 3 </col>
2461   </row>
2462   <row>
2463     <col> Securitylevel_close </col> <col> 4 </col>
2464   </row>
2465 </table>
2466 </subsubsection>
2467 </subsection>
2468
2469 <subsection>
2470   <heading>object</heading>
2471
2472 <para>
2473 The <emph>object</emph> table contains general information on the objects being monitored.
2474 The table object will more be used for retrieval, since adding objects will be an
2475 occasional process. Anything that for some reason can be indexed ought to be indexed.
2476 </para>
2477
2478 <subsubsection>
2479   <heading>The fields.</heading>
2480
2481 <para>
2482 The fields are:
2483 </para>
2484 <table cpos='lllp{6cm}'>
2485   <thead>
2486     <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
2487     <col>
2488       Remarks
2489     </col>
2490   </thead>
2491   <row>
2492     <col> objectid </col> <col> Bigserial </col> <col> 8 </col>
2493     <col>
2494       Autonumbering code for the computer or device.
2495     </col>
2496   </row>
2497   <row>
2498     <col> objectname </col> <col> Text </col> <col> <para/> </col>
2499     <col>
2500       The hostname of the object
2501     </col>
2502   </row>
2503   <row>
2504     <col> objectcode </col> <col> Text </col> <col> <para/> </col>
2505     <col>
2506       Unique identifier (if existent) on the system<footnote>In Linux this will
2507       typically be the <emph>hostid</emph>.</footnote>.
2508     </col>
2509   </row>
2510   <row>
2511     <col> scp_enabled </col> <col> Boolean </col> <col> <para/> </col>
2512     <col>
2513       Can communication occur through scp (T = Yes / F = No)
2514     </col>
2515   </row>
2516   <row>
2517     <col> scp_inet </col> <col> Inet </col> <col> <para/> </col>
2518     <col>
2519       IP Address of the object for scp-data transfer.
2520     </col>
2521   </row>
2522   <row>
2523     <col> mail_enabled </col> <col> Boolean </col> <col> <para/> </col>
2524     <col>
2525       Can communication occur through e-mail (T = Yes/F = No).
2526     </col>
2527   </row>
2528   <row>
2529     <col> mail_from </col> <col> Text </col> <col> <para/> </col>
2530     <col>
2531       The e-mail address where e-mail will come from.
2532     </col>
2533   </row>
2534   <row>
2535     <col> sms_enabled </col> <col> Boolean </col> <col> <para/> </col>
2536     <col>
2537       Can communication occur through SMS (T = Yes/F = No).
2538     </col>
2539   </row>
2540   <row>
2541     <col> sms_number </col> <col> Text </col> <col> <para/> </col>
2542     <col>
2543       The SMS-number to send a notification to.
2544     </col>
2545   </row>
2546   <row>
2547     <col> fax_enabled </col> <col> Boolean </col> <col> <para/> </col>
2548     <col>
2549       Can communication occur through Fax (T = Yes/F = No).
2550     </col>
2551   </row>
2552   <row>
2553     <col> fax_number </col> <col> Text </col> <col> <para/> </col>
2554     <col>
2555       The fax-number to send a notification to.
2556     </col>
2557   </row>
2558   <row>
2559     <col>
2560       object_description
2561     </col>
2562     <col>
2563       Text
2564     </col>
2565     <col>
2566       <para/>
2567     </col>
2568     <col>
2569       Description of the object. What type of system is it
2570     </col>
2571   </row>
2572   <row>
2573     <col> object_owner </col> <col> Text </col> <col> <para/> </col>
2574     <col>
2575       Owner-details
2576     </col>
2577   </row>
2578   <row>
2579     <col> physical_location </col> <col> Text </col> <col> <para/> </col>
2580     <col>
2581       Physical address and when applicable entry-details needed to get to the object.
2582     </col>
2583   </row>
2584   <row>
2585     <col> timezone </col> <col> Text </col> <col> <para/> </col>
2586     <col>
2587       The timezone where this object is located<footnote>For objects that
2588       move around like PDA's and laptops the timezone can be the place where
2589       a person is stationed or better GMT.</footnote>.
2590     </col>
2591   </row>
2592   <row>
2593     <col> remark </col> <col> Text </col> <col> <para/> </col>
2594     <col>
2595       Additional remarks that shouldn't be in the previous TEXT fields.
2596     </col>
2597   </row>
2598 </table>
2599 </subsubsection>
2600
2601 <subsubsection>
2602   <heading>The indexes.</heading>
2603
2604 <para>
2605 The <emph>object</emph> table is indexed on the following fields:
2606 </para>
2607
2608 <table cpos='lll'>
2609   <thead>
2610     <col> Indexname </col> <col> Field </col> <col> Characteristics </col>
2611   </thead>
2612   <row>
2613     <col> obj_pk (object_objectid_key) </col> <col> objectid </col> <col> Primary key </col>
2614   </row>
2615   <row>
2616     <col> obj_objectname </col> <col> objectname </col> <col> Unique </col>
2617   </row>
2618   <row>
2619     <col> obj_objectcode </col> <col> objectcode </col> <col> Unique </col>
2620   </row>
2621   <row>
2622     <col> obj_mail_from </col> <col> mail_from </col> <col> <para/> </col>
2623   </row>
2624 </table>
2625 </subsubsection>
2626
2627 <subsubsection>
2628   <heading>The relationships.</heading>
2629
2630 <para>
2631 The relationships with other tables are listed below:
2632 </para>
2633
2634 <table cpos='llp{8cm}'>
2635   <thead>
2636     <col> Fieldname </col> <col> Remote Table </col> <col> Remarks </col>
2637   </thead>
2638   <row>
2639     <col> ObjectID </col> <col> Log (adv) </col>
2640     <col> Reference to processed log-entries </col>
2641   </row>
2642   <row>
2643     <col> <para/> </col> <col> Notification </col>
2644     <col>
2645       Reference to the table <emph>notification</emph> that contains the notifications
2646       that have been created.
2647     </col>
2648   </row>
2649   <row>
2650     <col> <para/> </col> <col> Object_issue </col>
2651     <col>
2652       Reference to the <emph>object_issue</emph> that indicates how notifications have to be handled .
2653     </col>
2654   </row>
2655   <row>
2656     <col> <para/> </col> <col> Object_priority </col>
2657     <col>
2658       Reference to the <emph>object_priority</emph> table that indicates how a
2659       certain level of priority has to be dealt with.
2660     </col>
2661   </row>
2662   <row>
2663     <col> <para/> </col> <col> Object_system_user </col>
2664     <col>
2665       Reference to a list of system user to discover abnormalities in user behaviour.
2666     </col>
2667   </row>
2668   <row>
2669     <col> <para/> </col> <col> Object_user </col>
2670     <col> Reference to the <emph>object_user</emph> </col>
2671   </row>
2672   <row>
2673     <col> <para/> </col> <col> Unprocessed_log </col>
2674     <col>
2675       Reference to the entries that have not been processed at all.
2676     </col>
2677   </row>
2678 </table>
2679
2680 <para>In the relationshipmodel this looks like this:</para>
2681 <para>
2682   <picture src="erd-object.png" eps="erd-object"/>
2683 </para>
2684 </subsubsection>
2685
2686 <subsubsection>
2687   <heading>Sample data.</heading>
2688 <para>
2689 There is no preset data and therefor it's an example has been created.
2690 The table has quite some fields so the example has the fieldname in the
2691 left column and the data in the right column.
2692 </para>
2693 <table cpos='lp{6cm}'>
2694       <thead>
2695         <col> Fieldname </col>
2696         <col> Sample data </col>
2697       </thead>
2698       <row>
2699         <col> Objectid </col>
2700         <col> 1 </col>
2701       </row>
2702       <row>
2703         <col> Objectname </col>
2704         <col> webber.dewinter.com </col>
2705       </row>
2706       <row>
2707         <col> Objectcode </col>
2708         <col> 7f0100 </col>
2709       </row>
2710       <row>
2711         <col> Scp_enabled </col>
2712         <col> T </col>
2713       </row>
2714       <row>
2715         <col> Scp_inet </col>
2716         <col> 192.168.221.212 </col>
2717       </row>
2718       <row>
2719         <col> Mail_enabled </col>
2720         <col> T </col>
2721       </row>
2722       <row>
2723         <col> Mail_from </col>
2724         <col> <reference href="mailto:gnucomo@maintenance.dewinter.com">gnucomo@maintenance.dewinter.com</reference> </col>
2725       </row>
2726       <row>
2727         <col> Sms_enabled </col>
2728         <col> T </col>
2729       </row>
2730       <row>
2731         <col> Sms_number </col>
2732         <col> 06-XXXXXXXX </col>
2733       </row>
2734       <row>
2735         <col> Fax_enabled </col>
2736         <col> T </col>
2737       </row>
2738       <row>
2739         <col> Fax_number </col>
2740         <col> 0318-XXXXXX </col>
2741       </row>
2742       <row>
2743         <col> Object_description </col>
2744         <col> 19 inch 4 units, AMD-300 with two 27Gb disks (RAID-0), 256Mb memory </col>
2745       </row>
2746       <row>
2747         <col> Object_owner </col>
2748         <col>
2749           <para>Brenno de Winter</para>
2750           <para>De Winter Information Solutions</para>
2751           <para>Your street here 32</para>
2752           <para>9999 XX YOUR CITY</para>
2753           <para>THE NETHERLANDS</para>
2754           <para>Phone: +31 XXX XXX XXX</para>
2755         </col>
2756       </row>
2757       <row>
2758         <col> Physical_location </col>
2759         <col>
2760           <para>Internet Provider XYZ</para>
2761           <para>Your street here 38</para>
2762           <para>9999 XX YOUR CITY</para>
2763           <para>THE NETHERLANDS</para>
2764           <para>Phone: +31 XXX XXX XXX</para>
2765           
2766           <para>Dataroom. System: Q7845</para>
2767         </col>
2768       </row>
2769       <row>
2770         <col> Remark </col>
2771         <col>
2772           <para>A replacement system is available at the office location.
2773                The following persons have been authorized to enter the data room at the ISP:</para>
2774           <para>* Arjen Baart</para>
2775           <para>* Peter Busser</para>
2776           <para>* Brenno de Winter</para>
2777         </col>
2778       </row>
2779     </table>
2780     <para/>
2781 </subsubsection>
2782 </subsection>
2783
2784 <subsection>
2785   <heading>object_issue. </heading>
2786 <para>
2787 This table will store the policy on a certain issue like the priority being
2788 recognized and special actions to take.
2789 Since policies are utilized by the systems continuously all other process will rely on this index,
2790 while users will change the values occasionally.
2791 </para>
2792
2793 <subsubsection>
2794   <heading>The fields.</heading>
2795
2796 <para>
2797 The fields of <emph>object_issue</emph>:
2798 </para>
2799
2800 <table cpos='lllp{6cm}'>
2801       <thead>
2802         <col>
2803           <para>Fieldname</para>
2804         </col>
2805         <col>
2806           <para>Fieldtype</para>
2807         </col>
2808         <col>
2809           <para>Size</para>
2810         </col>
2811         <col>
2812           <para>Remarks</para>
2813         </col>
2814       </thead>
2815       <row>
2816         <col>
2817           <para>objectid</para>
2818         </col>
2819         <col>
2820           <para>Bigint</para>
2821         </col>
2822         <col>
2823           <para>8</para>
2824         </col>
2825         <col>
2826           <para>Reference to the object</para>
2827         </col>
2828       </row>
2829       <row>
2830         <col>
2831           <para>type_of_notificationid</para>
2832         </col>
2833         <col>
2834           <para>Bigint</para>
2835         </col>
2836         <col>
2837           <para>8</para>
2838         </col>
2839         <col>
2840           <para>Reference to the <emph>type_of_notification</emph> indicating
2841            what type of notification we have here and what basic rules apply.</para>
2842         </col>
2843       </row>
2844       <row>
2845         <col>
2846           <para>default_priority</para>
2847         </col>
2848         <col>
2849           <para>Int</para>
2850         </col>
2851         <col>
2852           <para>4</para>
2853         </col>
2854         <col>
2855           <para>The priority that will be set automatically when this type of
2856            notification is entered into the system.</para>
2857         </col>
2858       </row>
2859       <row>
2860         <col>
2861           <para>escalation</para>
2862         </col>
2863         <col>
2864           <para>Boolean</para>
2865         </col>
2866         <col>
2867           <para/>
2868         </col>
2869         <col>
2870           <para>Will the system perform automatic escalation (T = Yes / F = No)</para>
2871         </col>
2872       </row>
2873       <row>
2874         <col>
2875           <para>escalation_time</para>
2876         </col>
2877         <col>
2878           <para>Time</para>
2879         </col>
2880         <col>
2881           <para/>
2882         </col>
2883         <col>
2884           <para>The time after which a higher priority is awarded to the notification.</para>
2885         </col>
2886       </row>
2887       <row>
2888         <col>
2889           <para>max_priority</para>
2890         </col>
2891         <col>
2892           <para>Int</para>
2893         </col>
2894         <col>
2895           <para/>
2896         </col>
2897         <col>
2898           <para>The maximum priority given to this type of notification.</para>
2899         </col>
2900       </row>
2901       <row>
2902         <col>
2903           <para>adjusted_setting</para>
2904         </col>
2905         <col>
2906           <para>Text</para>
2907         </col>
2908         <col>
2909           <para/>
2910         </col>
2911         <col>
2912           <para>Some checks can have a special settings (for instance alert
2913            after 5 failed login attempts instead of 3).</para>
2914         </col>
2915       </row>
2916 </table>
2917 </subsubsection>
2918
2919 <subsubsection>
2920   <heading>The indexes.</heading>
2921
2922 <para>
2923 These are the indices:
2924 </para>
2925 <table cpos='lll'>
2926       <thead>
2927         <col>
2928           <para>Indexname</para>
2929         </col>
2930         <col>
2931           <para>Field</para>
2932         </col>
2933         <col>
2934           <para>Characteristics</para>
2935         </col>
2936       </thead>
2937       <row>
2938         <col>
2939           <para>obi_pk</para>
2940         </col>
2941         <col>
2942           <para>objectid</para>
2943         </col>
2944         <col>
2945           <para>Primary key</para>
2946         </col>
2947       </row>
2948       <row>
2949         <col>
2950           <para/>
2951         </col>
2952         <col>
2953           <para>type_of_notification_id</para>
2954         </col>
2955         <col>
2956           <para>Primary key</para>
2957         </col>
2958       </row>
2959       <row>
2960         <col>
2961           <para>obi_objectid</para>
2962         </col>
2963         <col>
2964           <para>Objectid</para>
2965         </col>
2966         <col>
2967           <para/>
2968         </col>
2969       </row>
2970       <row>
2971         <col>
2972           <para>obi_type_of_notificationid</para>
2973         </col>
2974         <col>
2975           <para>type_of_notification_id</para>
2976         </col>
2977         <col>
2978           <para/>
2979         </col>
2980       </row>
2981     </table>
2982     </subsubsection>
2983
2984 <subsubsection>
2985    <heading>The relationships.</heading>
2986
2987 <para>
2988 Relationships with other tables:
2989 </para>
2990
2991 <table cpos='llp{6cm}'>
2992       <thead>
2993         <col>
2994           <para>Fieldname</para>
2995         </col>
2996         <col>
2997           <para>Remote Table</para>
2998         </col>
2999         <col>
3000           <para>Remarks</para>
3001         </col>
3002       </thead>
3003       <row>
3004         <col>
3005           <para>ObjectID</para>
3006         </col>
3007         <col>
3008           <para>Object</para>
3009         </col>
3010         <col>
3011           <para>Reference to the <emph>object</emph> (which object does this apply to).</para>
3012         </col>
3013       </row>
3014       <row>
3015         <col>
3016           <para>Type_of_issueid</para>
3017         </col>
3018         <col>
3019           <para>Type_of_issue</para>
3020         </col>
3021         <col>
3022           <para>Reference to the type of issue.</para>
3023         </col>
3024       </row>
3025     </table>
3026
3027 <para>In the model this look like this:</para>
3028 <para>
3029     <picture src="erd-objissue.png" eps="erd-objissue"/>
3030 </para>
3031
3032 </subsubsection>
3033 <subsubsection>
3034   <heading>Sample data.</heading>
3035
3036 <para>
3037 Some sample data:
3038 </para>
3039 <table cpos='lllllll'>
3040       <thead>
3041         <col>
3042           <para>Objectid</para>
3043         </col>
3044         <col>
3045           <para>Type_of_notification_id</para>
3046         </col>
3047         <col>
3048           <para>Default Priority</para>
3049         </col>
3050         <col>
3051           <para>Escalation</para>
3052         </col>
3053         <col>
3054           <para>Escalation_time</para>
3055         </col>
3056         <col>
3057           <para>Max_priority</para>
3058         </col>
3059         <col>
3060           <para>Adjusted_setting</para>
3061         </col>
3062       </thead>
3063       <row>
3064         <col>
3065           <para>1</para>
3066         </col>
3067         <col>
3068           <para>1</para>
3069         </col>
3070         <col>
3071           <para>3</para>
3072         </col>
3073         <col>
3074           <para>T</para>
3075         </col>
3076         <col>
3077           <para>00:15:00</para>
3078         </col>
3079         <col>
3080           <para>1</para>
3081         </col>
3082         <col>
3083           <para/>
3084         </col>
3085       </row>
3086       <row>
3087         <col>
3088           <para>1</para>
3089         </col>
3090         <col>
3091           <para>2</para>
3092         </col>
3093         <col>
3094           <para>4</para>
3095         </col>
3096         <col>
3097           <para>T</para>
3098         </col>
3099         <col>
3100           <para>00:30:00</para>
3101         </col>
3102         <col>
3103           <para>2</para>
3104         </col>
3105         <col>
3106           <para/>
3107         </col>
3108       </row>
3109       <row>
3110         <col>
3111           <para>1</para>
3112         </col>
3113         <col>
3114           <para>3</para>
3115         </col>
3116         <col>
3117           <para>5</para>
3118         </col>
3119         <col>
3120           <para>F</para>
3121         </col>
3122         <col>
3123           <para/>
3124         </col>
3125         <col>
3126           <para/>
3127         </col>
3128         <col>
3129           <para>7</para>
3130         </col>
3131       </row>
3132       <row>
3133         <col>
3134           <para>2</para>
3135         </col>
3136         <col>
3137           <para>1</para>
3138         </col>
3139         <col>
3140           <para>4</para>
3141         </col>
3142         <col>
3143           <para>T</para>
3144         </col>
3145         <col>
3146           <para>00:45:00</para>
3147         </col>
3148         <col>
3149           <para>2</para>
3150         </col>
3151         <col>
3152           <para/>
3153         </col>
3154       </row>
3155       <row>
3156         <col>
3157           <para>2</para>
3158         </col>
3159         <col>
3160           <para>3</para>
3161         </col>
3162         <col>
3163           <para>5</para>
3164         </col>
3165         <col>
3166           <para>F</para>
3167         </col>
3168         <col>
3169           <para/>
3170         </col>
3171         <col>
3172           <para/>
3173         </col>
3174         <col>
3175           <para>8</para>
3176         </col>
3177       </row>
3178     </table>
3179 </subsubsection>
3180 </subsection>
3181
3182 <subsection>
3183   <heading>object_priority.</heading>
3184
3185 <para>
3186 This table stores per object how a certain level of priority is being dealt with.
3187 What policies do apply. This table is mostly used for retrieval, so firm indexing is logic.
3188 </para>
3189
3190 <subsubsection>
3191   <heading>The fields.</heading>
3192
3193 <para>
3194 The fields are listed below:
3195 </para>
3196 <table cpos='lllp{6cm}'>
3197       <thead>
3198         <col>
3199           <para>Fieldname</para>
3200         </col>
3201         <col>
3202           <para>Fieldtype</para>
3203         </col>
3204         <col>
3205           <para>Size</para>
3206         </col>
3207         <col>
3208           <para>Remarks</para>
3209         </col>
3210       </thead>
3211       <row>
3212         <col>
3213           <para>objectid</para>
3214         </col>
3215         <col>
3216           <para>Bigint</para>
3217         </col>
3218         <col>
3219           <para>8</para>
3220         </col>
3221         <col>
3222           <para>Reference to the object</para>
3223         </col>
3224       </row>
3225       <row>
3226         <col>
3227           <para>priorityid</para>
3228         </col>
3229         <col>
3230           <para>Int</para>
3231         </col>
3232         <col>
3233           <para>4</para>
3234         </col>
3235         <col>
3236           <para>Priority.</para>
3237         </col>
3238       </row>
3239       <row>
3240         <col>
3241           <para>send_mail</para>
3242         </col>
3243         <col>
3244           <para>Boolean</para>
3245         </col>
3246         <col>
3247           <para/>
3248         </col>
3249         <col>
3250           <para>Send an e-mail if this priority is set? Yes = T / No = F</para>
3251         </col>
3252       </row>
3253       <row>
3254         <col>
3255           <para>send_sms</para>
3256         </col>
3257         <col>
3258           <para>Boolean</para>
3259         </col>
3260         <col>
3261           <para/>
3262         </col>
3263         <col>
3264           <para>Send a sms message if this priority is set? Yes = T / No = F</para>
3265         </col>
3266       </row>
3267       <row>
3268         <col>
3269           <para>send_fax</para>
3270         </col>
3271         <col>
3272           <para>Boolean</para>
3273         </col>
3274         <col>
3275           <para/>
3276         </col>
3277         <col>
3278           <para>Send a fax if this priority is set? Yes = T / No = F</para>
3279         </col>
3280       </row>
3281       <row>
3282         <col>
3283           <para>repeat_notification</para>
3284         </col>
3285         <col>
3286           <para>Boolean</para>
3287         </col>
3288         <col>
3289           <para/>
3290         </col>
3291         <col>
3292           <para>Repeat this notification if no action occurs since the notification. Yes = T / No = F</para>
3293         </col>
3294       </row>
3295       <row>
3296         <col>
3297           <para>interval_for_repeat</para>
3298         </col>
3299         <col>
3300           <para>Time</para>
3301         </col>
3302         <col>
3303           <para/>
3304         </col>
3305         <col>
3306           <para>Time interval that is set to wait for a response.</para>
3307         </col>
3308       </row>
3309     </table>
3310     </subsubsection>
3311
3312 <subsubsection>
3313   <heading>The indexes.</heading>
3314
3315 <para>
3316 Indices of the <emph>object_priority</emph> table:
3317 </para>
3318
3319 <table cpos='lll'>
3320       <thead>
3321         <col>
3322           <para>Indexname</para>
3323         </col>
3324         <col>
3325           <para>Field</para>
3326         </col>
3327         <col>
3328           <para>Characteristics</para>
3329         </col>
3330       </thead>
3331       <row>
3332         <col>
3333           <para>obi_pk</para>
3334         </col>
3335         <col>
3336           <para>objectid</para>
3337         </col>
3338         <col>
3339           <para>Primary key</para>
3340         </col>
3341       </row>
3342       <row>
3343         <col>
3344           <para/>
3345         </col>
3346         <col>
3347           <para>priorityid</para>
3348         </col>
3349         <col>
3350           <para>Primary key</para>
3351         </col>
3352       </row>
3353       <row>
3354         <col>
3355           <para>obi_objectid</para>
3356         </col>
3357         <col>
3358           <para>Objectid</para>
3359         </col>
3360         <col>
3361           <para/>
3362         </col>
3363       </row>
3364       <row>
3365         <col>
3366           <para>obi_type_of_notification_id</para>
3367         </col>
3368         <col>
3369           <para>type_of_notification_id</para>
3370         </col>
3371         <col>
3372           <para/>
3373         </col>
3374       </row>
3375     </table>
3376 </subsubsection>
3377
3378 <subsubsection>
3379   <heading>The relationships.</heading>
3380
3381 <para>
3382 Relationships with other tables:
3383 </para>
3384
3385 <table cpos='llp{6cm}'>
3386       <thead>
3387         <col>
3388           <para>Fieldname</para>
3389         </col>
3390         <col>
3391           <para>Remote Table</para>
3392         </col>
3393         <col>
3394           <para>Remarks</para>
3395         </col>
3396       </thead>
3397       <row>
3398         <col>
3399           <para>ObjectID</para>
3400         </col>
3401         <col>
3402           <para>Object</para>
3403         </col>
3404         <col>
3405           <para>Reference to the object (which object does this apply to).</para>
3406         </col>
3407       </row>
3408       <row>
3409         <col>
3410           <para>Priorityid</para>
3411         </col>
3412         <col>
3413           <para>Priority</para>
3414         </col>
3415         <col>
3416           <para>Reference to the priority.</para>
3417         </col>
3418       </row>
3419     </table>
3420
3421 <para>
3422 In the model this look like this:
3423 </para>
3424 <para>
3425 <picture src="erd-objprior.png" eps="erd-objprior"/>
3426 </para>
3427 </subsubsection>
3428 </subsection>
3429
3430 <subsection>
3431   <heading>object_service</heading>
3432
3433 <para>
3434 The object service table indicates which services can be expected on the system.
3435 If input fails to show up a notification can be generated.
3436 </para>
3437
3438 <subsubsection>
3439   <heading>The fields.</heading>
3440
3441 <para>
3442 The fields are listed below:
3443 </para>
3444
3445 <table cpos='lllp{6cm}'>
3446       <thead>
3447         <col>
3448           <para>Fieldname</para>
3449         </col>
3450         <col>
3451           <para>Fieldtype</para>
3452         </col>
3453         <col>
3454           <para>Size</para>
3455         </col>
3456         <col>
3457           <para>Remarks</para>
3458         </col>
3459       </thead>
3460       <row>
3461         <col>
3462           <para>objectid</para>
3463         </col>
3464         <col>
3465           <para>Bigint</para>
3466         </col>
3467         <col>
3468           <para>8</para>
3469         </col>
3470         <col>
3471           <para>Reference to the object</para>
3472         </col>
3473       </row>
3474       <row>
3475         <col>
3476           <para>servicecode</para>
3477         </col>
3478         <col>
3479           <para>Text</para>
3480         </col>
3481         <col>
3482           <para/>
3483         </col>
3484         <col>
3485           <para>Reference to service.</para>
3486         </col>
3487       </row>
3488       <row>
3489         <col>
3490           <para>expected_interval</para>
3491         </col>
3492         <col>
3493           <para>Bigint</para>
3494         </col>
3495         <col>
3496           <para>8</para>
3497         </col>
3498         <col>
3499           <para>The expected interval in minutes between two log entries.
3500           If this gives a time-out a notification is generated<footnote>To avoid many
3501           false positives it may be wise to give the system always 1 or 2 minutes extra time.
3502           If for some reason a connection is slow or a mail-daemon restarted
3503           the effect would generate tuns of notifications.</footnote>.
3504           The following values can be considered the most common:</para>
3505           <para>* 60 hourly entries</para>
3506           <para>* 120 two hourly entries</para>
3507           <para>* 240 four hourly entries</para>
3508           <para>* 480 eight hourly entries</para>
3509           <para>* 920 twelve hourly entries</para>
3510           <para>* 1840 daily entries</para>
3511           <para>* 12880 weekly entries</para>
3512         </col>
3513       </row>
3514       <row>
3515         <col>
3516           <para>last_entry</para>
3517         </col>
3518         <col>
3519           <para>Timestamp</para>
3520         </col>
3521         <col>
3522           <para/>
3523         </col>
3524         <col>
3525           <para>The timestamp of the last entry (for detecting exceeded interval).
3526           This field could be derived from the log-table as well, but the
3527           redundance gives a performance on detection that is useful, since a
3528           check should run every minute.</para>
3529         </col>
3530       </row>
3531       <row>
3532         <col>
3533           <para>default_priority</para>
3534         </col>
3535         <col>
3536           <para>Int</para>
3537         </col>
3538         <col>
3539           <para>4</para>
3540         </col>
3541         <col>
3542           <para>Priority given if this service didn't occur.</para>
3543         </col>
3544       </row>
3545       <row>
3546         <col>
3547           <para>maximum_priority</para>
3548         </col>
3549         <col>
3550           <para>Int</para>
3551         </col>
3552         <col>
3553           <para>4</para>
3554         </col>
3555         <col>
3556           <para>Maximum priority (in case of escalation)</para>
3557         </col>
3558       </row>
3559       <row>
3560         <col>
3561           <para>accepted</para>
3562         </col>
3563         <col>
3564           <para>Boolean</para>
3565         </col>
3566         <col>
3567           <para/>
3568         </col>
3569         <col>
3570           <para>If a service hasn't been set, the application user should
3571           indicate that this is valid (logs shouldn't just appear).
3572           New entries will be added automatically but still have to be verified.</para>
3573         </col>
3574       </row>
3575     </table>
3576 </subsubsection>
3577
3578 <subsubsection>
3579   <heading>The indexes.</heading>
3580
3581 <para>
3582 The table is indexed on the following fields:
3583 </para>
3584 <table cpos='lll'>
3585       <thead>
3586         <col>
3587           <para>Indexname</para>
3588         </col>
3589         <col>
3590           <para>Field</para>
3591         </col>
3592         <col>
3593           <para>Characteristics</para>
3594         </col>
3595       </thead>
3596       <row>
3597         <col>
3598           <para>obs_pk</para>
3599         </col>
3600         <col>
3601           <para>objectid</para>
3602         </col>
3603         <col>
3604           <para>Primary key</para>
3605         </col>
3606       </row>
3607       <row>
3608         <col>
3609           <para/>
3610         </col>
3611         <col>
3612           <para>servicecode</para>
3613         </col>
3614         <col>
3615           <para>Primary key</para>
3616         </col>
3617       </row>
3618       <row>
3619         <col>
3620           <para>obs_objectid</para>
3621         </col>
3622         <col>
3623           <para>objectid</para>
3624         </col>
3625         <col>
3626           <para/>
3627         </col>
3628       </row>
3629       <row>
3630         <col>
3631           <para>obs_servicecode</para>
3632         </col>
3633         <col>
3634           <para>servicecode</para>
3635         </col>
3636         <col>
3637           <para/>
3638         </col>
3639       </row>
3640       <row>
3641         <col>
3642           <para>obs_accepted</para>
3643         </col>
3644         <col>
3645           <para>accepted</para>
3646         </col>
3647         <col>
3648           <para/>
3649         </col>
3650       </row>
3651     </table>
3652 </subsubsection>
3653
3654 <subsubsection>
3655    <heading>The relationships.</heading>
3656
3657 <para>
3658 Relationships with other tables:
3659 </para>
3660
3661 <table cpos='llp{8cm}'>
3662       <thead>
3663         <col>
3664           <para>Fieldname</para>
3665         </col>
3666         <col>
3667           <para>Remote Table</para>
3668         </col>
3669         <col>
3670           <para>Remarks</para>
3671         </col>
3672       </thead>
3673       <row>
3674         <col>
3675           <para>objectID</para>
3676         </col>
3677         <col>
3678           <para>Object</para>
3679         </col>
3680         <col>
3681           <para>Reference to the object (which object does this apply to).</para>
3682         </col>
3683       </row>
3684       <row>
3685         <col>
3686           <para>servicecode</para>
3687         </col>
3688         <col>
3689           <para>Service</para>
3690         </col>
3691         <col>
3692           <para>Reference to the service table. </para>
3693         </col>
3694       </row>
3695     </table>
3696
3697 <para>In the model this look like this:</para>
3698 <para>
3699   <picture src="erd-objservice.png" eps="erd-objservice"/>
3700 </para>
3701 </subsubsection>
3702 </subsection>
3703
3704 <subsection>
3705   <heading>object_system_user</heading>
3706
3707 <para>
3708 This table will derive a list of users that can be identified based
3709 on the log-files in the system. This table is filled during data entry.
3710 But the filling of the table is dependent on the fact if the user has been entered before.
3711 So during the processing the read will be done more than the data entry and
3712 that makes heavy indexing logic.
3713 </para>
3714 <subsubsection>
3715   <heading>The fields.</heading>
3716
3717 <para>
3718 The fields of <emph>object_system_user</emph> are listed below:
3719 </para>
3720
3721 <table cpos='lllp{6cm}'>
3722       <thead>
3723         <col>
3724           <para>Fieldname</para>
3725         </col>
3726         <col>
3727           <para>Fieldtype</para>
3728         </col>
3729         <col>
3730           <para>Size</para>
3731         </col>
3732         <col>
3733           <para>Remarks</para>
3734         </col>
3735       </thead>
3736       <row>
3737         <col>
3738           <para>objectid</para>
3739         </col>
3740         <col>
3741           <para>Bigint</para>
3742         </col>
3743         <col>
3744           <para>8</para>
3745         </col>
3746         <col>
3747           <para>Reference to the object</para>
3748         </col>
3749       </row>
3750       <row>
3751         <col>
3752           <para>system_username</para>
3753         </col>
3754         <col>
3755           <para>Text</para>
3756         </col>
3757         <col>
3758           <para/>
3759         </col>
3760         <col>
3761           <para>Username on the object/system.</para>
3762         </col>
3763       </row>
3764       <row>
3765         <col>
3766           <para>can_login</para>
3767         </col>
3768         <col>
3769           <para>Boolean</para>
3770         </col>
3771         <col>
3772           <para/>
3773         </col>
3774         <col>
3775           <para>Can this user login (T = Yes / F = No)?</para>
3776         </col>
3777       </row>
3778       <row>
3779         <col>
3780           <para>can_be_root</para>
3781         </col>
3782         <col>
3783           <para>Boolean</para>
3784         </col>
3785         <col>
3786           <para/>
3787         </col>
3788         <col>
3789           <para>Can this user become root (T = Yes / F = No)?</para>
3790         </col>
3791       </row>
3792     </table>
3793     </subsubsection>
3794
3795 <subsubsection>
3796   <heading>The indexes.</heading>
3797
3798 <para>
3799 The table is indexed on the following fields:
3800 </para>
3801 <table cpos='lll'>
3802       <thead>
3803         <col>
3804           <para>Indexname</para>
3805         </col>
3806         <col>
3807           <para>Field</para>
3808         </col>
3809         <col>
3810           <para>Characteristics</para>
3811         </col>
3812       </thead>
3813       <row>
3814         <col>
3815           <para>osu_pk</para>
3816         </col>
3817         <col>
3818           <para>objectid</para>
3819         </col>
3820         <col>
3821           <para>Primary key</para>
3822         </col>
3823       </row>
3824       <row>
3825         <col>
3826           <para/>
3827         </col>
3828         <col>
3829           <para>system_username</para>
3830         </col>
3831         <col>
3832           <para>Primary key</para>
3833         </col>
3834       </row>
3835       <row>
3836         <col>
3837           <para>osu_objectid</para>
3838         </col>
3839         <col>
3840           <para>objectid</para>
3841         </col>
3842         <col>
3843           <para/>
3844         </col>
3845       </row>
3846       <row>
3847         <col>
3848           <para>osu_system_username</para>
3849         </col>
3850         <col>
3851           <para>system_username</para>
3852         </col>
3853         <col>
3854           <para/>
3855         </col>
3856       </row>
3857     </table>
3858     </subsubsection>
3859
3860 <subsubsection>
3861   <heading>The relationships.</heading>
3862
3863 <para>
3864 Relationships with other tables:
3865 </para>
3866 <table cpos='llp{8cm}'>
3867       <thead>
3868         <col>
3869           <para>Fieldname</para>
3870         </col>
3871         <col>
3872           <para>Remote Table</para>
3873         </col>
3874         <col>
3875           <para>Remarks</para>
3876         </col>
3877       </thead>
3878       <row>
3879         <col>
3880           <para>ObjectID</para>
3881         </col>
3882         <col>
3883           <para>Object</para>
3884         </col>
3885         <col>
3886           <para>Reference to the object (which object does this apply to).</para>
3887         </col>
3888       </row>
3889       <row>
3890         <col>
3891           <para>System_username</para>
3892         </col>
3893         <col>
3894           <para>Log</para>
3895         </col>
3896         <col>
3897           <para>Log entries can refer to the system username.</para>
3898         </col>
3899       </row>
3900     </table>
3901     <para>In the model this look like this:</para>
3902     <para/>
3903
3904     <para>
3905       <picture src="erd-objsysusr.png" eps="erd-objsysusr"/>
3906     </para>
3907     </subsubsection>
3908 </subsection>
3909
3910 <subsection>
3911   <heading>object_user</heading>
3912
3913 <para>
3914 This table will enable users to get access to the information belonging to an object.
3915 Also this table is mainly used for data retrieval and will rely on the indexes.
3916 </para>
3917 <subsubsection>
3918   <heading>The fields.</heading>
3919
3920 <para>
3921 The fields of <emph>object_user</emph> are listed below:
3922 </para>
3923
3924 <table cpos='lllp{6cm}'>
3925       <thead>
3926         <col>
3927           <para>Fieldname</para>
3928         </col>
3929         <col>
3930           <para>Fieldtype</para>
3931         </col>
3932         <col>
3933           <para>Size</para>
3934         </col>
3935         <col>
3936           <para>Remarks</para>
3937         </col>
3938       </thead>
3939       <row>
3940         <col>
3941           <para>Objectid</para>
3942         </col>
3943         <col>
3944           <para>Bigint</para>
3945         </col>
3946         <col>
3947           <para>8</para>
3948         </col>
3949         <col>
3950           <para>Reference to the <emph>object</emph></para>
3951         </col>
3952       </row>
3953       <row>
3954         <col>
3955           <para>Username</para>
3956         </col>
3957         <col>
3958           <para>Text</para>
3959         </col>
3960         <col>
3961           <para/>
3962         </col>
3963         <col>
3964           <para>Username in gnucomo. A reference to <emph>user</emph>.</para>
3965         </col>
3966       </row>
3967       <row>
3968         <col>
3969           <para>Security_level</para>
3970         </col>
3971         <col>
3972           <para>Int</para>
3973         </col>
3974         <col>
3975           <para/>
3976         </col>
3977         <col>
3978           <para>The security-level granted to this user.</para>
3979         </col>
3980       </row>
3981     </table>
3982 </subsubsection>
3983
3984 <subsubsection>
3985   <heading>The indexes.</heading>
3986 <para>
3987 The indices of the <emph>object_user</emph> table:
3988 </para>
3989 <table cpos='lll'>
3990       <thead>
3991         <col>
3992           <para>Indexname</para>
3993         </col>
3994         <col>
3995           <para>Field</para>
3996         </col>
3997         <col>
3998           <para>Characteristics</para>
3999         </col>
4000       </thead>
4001       <row>
4002         <col>
4003           <para>ous_pk</para>
4004         </col>
4005         <col>
4006           <para>objectid</para>
4007         </col>
4008         <col>
4009           <para>Primary key</para>
4010         </col>
4011       </row>
4012       <row>
4013         <col>
4014           <para/>
4015         </col>
4016         <col>
4017           <para>username</para>
4018         </col>
4019         <col>
4020           <para>Primary key</para>
4021         </col>
4022       </row>
4023       <row>
4024         <col>
4025           <para>ous_objectid</para>
4026         </col>
4027         <col>
4028           <para>objectid</para>
4029         </col>
4030         <col>
4031           <para/>
4032         </col>
4033       </row>
4034       <row>
4035         <col>
4036           <para>ous_username</para>
4037         </col>
4038         <col>
4039           <para>username</para>
4040         </col>
4041         <col>
4042           <para/>
4043         </col>
4044       </row>
4045       <row>
4046         <col>
4047           <para>ous_security_level</para>
4048         </col>
4049         <col>
4050           <para>ous_security_level</para>
4051         </col>
4052         <col>
4053           <para/>
4054         </col>
4055       </row>
4056     </table>
4057 </subsubsection>
4058
4059 <subsubsection>
4060   <heading>The relationships.</heading>
4061
4062 <para>
4063 Relationships with other tables:
4064 </para>
4065
4066 <table cpos='llp{8cm}'>
4067       <thead>
4068         <col>
4069           <para>Fieldname</para>
4070         </col>
4071         <col>
4072           <para>Remote Table</para>
4073         </col>
4074         <col>
4075           <para>Remarks</para>
4076         </col>
4077       </thead>
4078       <row>
4079         <col>
4080           <para>objectID</para>
4081         </col>
4082         <col>
4083           <para>object</para>
4084         </col>
4085         <col>
4086           <para>Reference to the object (which object does this apply to).</para>
4087         </col>
4088       </row>
4089       <row>
4090         <col>
4091           <para>username</para>
4092         </col>
4093         <col>
4094           <para>user</para>
4095         </col>
4096         <col>
4097           <para>Reference to the user.</para>
4098         </col>
4099       </row>
4100     </table>
4101
4102     <para>In the model this look like this:</para>
4103     <picture src="erd-objusr.png" eps="erd-objusr"/>
4104
4105 </subsubsection>
4106 </subsection>
4107
4108 <subsection>
4109 <heading>parameter</heading>
4110 <para>
4111 The parameter table stores the operational parameters of a monitored object.
4112 The parameters of an object describe the object's resources and configurations.
4113 For each object, a large set of parameters can be defined. They range from
4114 anything like file systems and installed packages to the system's users.
4115 </para>
4116
4117 <subsubsection>
4118 <heading>The fields</heading>
4119 <para>
4120 The fields of the <emph>parameter</emph> table are listed below:
4121 </para>
4122 <table cpos='lllp{6cm}'>
4123       <thead>
4124         <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
4125         <col> Remarks </col>
4126       </thead>
4127       <row>
4128         <col>paramid</col><col>bigserial</col><col>8</col>
4129         <col>Uniquely identifies the parameter. Used in property and history tables.</col>
4130       </row>
4131       <row>
4132         <col>objectid</col><col>bigint</col><col>8</col>
4133         <col>The object of which this is a parameter. Refers to the object table.</col>
4134       </row>
4135       <row>
4136         <col>name</col><col>text</col><col> </col>
4137         <col>Name of the parameter to identify the resource</col>
4138       </row>
4139       <row>
4140         <col>class</col><col>text</col><col> </col>
4141         <col>Similar parameters are in the same class</col>
4142       </row>
4143       <row>
4144         <col>description</col><col>text</col><col> </col>
4145         <col>A verbose description of the parameter</col>
4146       </row>
4147       
4148 </table>
4149
4150 <para>
4151 The combination of objectid, name and class must be unique.
4152 </para>
4153
4154 </subsubsection>
4155 <subsubsection>
4156 <heading>Sample data</heading>
4157
4158 <para>
4159 The table below lists a few examples of parameters
4160 </para>
4161 <table cpos='lllll'>
4162    <thead>
4163       <col>paramid</col><col>objectid</col><col>name</col><col>class</col><col>description</col>
4164    </thead>
4165    <row>
4166       <col>1</col><col>1</col><col>/</col><col>filesystem</col><col>The root filesystem</col>
4167    </row>
4168    <row>
4169       <col>2</col><col>1</col><col>/home</col><col>filesystem</col><col>Our users' homedirs</col>
4170    </row>
4171    <row>
4172       <col>3</col><col>1</col><col>glibc</col><col>package</col><col>The standard C library</col>
4173    </row>
4174    <row>
4175       <col>4</col><col>1</col><col>arjen</col><col>user</col><col>Arjen Baart</col>
4176    </row>
4177 </table>
4178 </subsubsection>
4179 </subsection>
4180
4181 <subsection>
4182   <heading>priority</heading>
4183
4184 <para>
4185 The priority table contains information on the levels that are recognized by the system.
4186 Mainly data retrieval so depending on indexing.
4187 It needs to be said that most likely only a couple of states will exist<footnote>By default
4188 we will use five states, but many states can be given to enable all
4189 types of differentiation.</footnote>.
4190 </para>
4191
4192 <subsubsection>
4193   <heading>The fields.</heading>
4194
4195 <para>
4196 The fields of the <emph>priority</emph> table are listed below:
4197 </para>
4198
4199 <table cpos='lllp{6cm}'>
4200       <thead>
4201         <col>
4202           <para>Fieldname</para>
4203         </col>
4204         <col>
4205           <para>Fieldtype</para>
4206         </col>
4207         <col>
4208           <para>Size</para>
4209         </col>
4210         <col>
4211           <para>Remarks</para>
4212         </col>
4213       </thead>
4214       <row>
4215         <col>
4216           <para>priority</para>
4217         </col>
4218         <col>
4219           <para>Int</para>
4220         </col>
4221         <col>
4222           <para>4</para>
4223         </col>
4224         <col>
4225           <para>Priority</para>
4226         </col>
4227       </row>
4228       <row>
4229         <col>
4230           <para>send_mail</para>
4231         </col>
4232         <col>
4233           <para>Boolean</para>
4234         </col>
4235         <col>
4236           <para/>
4237         </col>
4238         <col>
4239           <para>Send an e-mail if this priority is set? Yes = T / No = F</para>
4240         </col>
4241       </row>
4242       <row>
4243         <col>
4244           <para>send_sms</para>
4245         </col>
4246         <col>
4247           <para>Boolean</para>
4248         </col>
4249         <col>
4250           <para/>
4251         </col>
4252         <col>
4253           <para>Send a sms message if this priority is set? Yes = T / No = F</para>
4254         </col>
4255       </row>
4256       <row>
4257         <col>
4258           <para>send_fax</para>
4259         </col>
4260         <col>
4261           <para>Boolean</para>
4262         </col>
4263         <col>
4264           <para/>
4265         </col>
4266         <col>
4267           <para>Send a fax if this priority is set? Yes = T / No = F</para>
4268         </col>
4269       </row>
4270       <row>
4271         <col>
4272           <para>repeat_notification</para>
4273         </col>
4274         <col>
4275           <para>Boolean</para>
4276         </col>
4277         <col>
4278           <para/>
4279         </col>
4280         <col>
4281           <para>Repeat this notification if no action occurs since the notification. Yes = T / No = F</para>
4282         </col>
4283       </row>
4284       <row>
4285         <col>
4286           <para>interval_for_repeat</para>
4287         </col>
4288         <col>
4289           <para>Time</para>
4290         </col>
4291         <col>
4292           <para/>
4293         </col>
4294         <col>
4295           <para>Time interval that is set to wait for a response.</para>
4296         </col>
4297       </row>
4298     </table>
4299 </subsubsection>
4300
4301 <subsubsection>
4302   <heading>The indexes.</heading>
4303
4304 <para>
4305 The table is indexed on the following fields:
4306 </para>
4307
4308 <table cpos='lll'>
4309       <thead>
4310         <col>
4311           <para>Indexname</para>
4312         </col>
4313         <col>
4314           <para>Field</para>
4315         </col>
4316         <col>
4317           <para>Characteristics</para>
4318         </col>
4319       </thead>
4320       <row>
4321         <col>
4322           <para>pri_pk</para>
4323         </col>
4324         <col>
4325           <para>priority</para>
4326         </col>
4327         <col>
4328           <para>Primary key</para>
4329         </col>
4330       </row>
4331     </table>
4332 </subsubsection>
4333
4334 <subsubsection>
4335   <heading>The relationships.</heading>
4336
4337 <para>
4338 Relationships with other tables:
4339 </para>
4340 <table cpos='llp{8cm}'>
4341       <thead>
4342         <col>
4343           <para>Fieldname</para>
4344         </col>
4345         <col>
4346           <para>Remote Table</para>
4347         </col>
4348         <col>
4349           <para>Remarks</para>
4350         </col>
4351       </thead>
4352       <row>
4353         <col>
4354           <para>priority</para>
4355         </col>
4356         <col>
4357           <para>object_priority</para>
4358         </col>
4359         <col>
4360           <para>Reference to the object (which object does this apply to). </para>
4361         </col>
4362       </row>
4363     </table>
4364
4365     <para>In the model this look like this:</para>
4366     <para>
4367       <picture src="erd-prior.png" eps="erd-prior"/>
4368     </para>
4369 </subsubsection>
4370 </subsection>
4371
4372 <subsection>
4373 <heading>property</heading>
4374 <para>
4375 The property table stores the actual values of the properties of
4376 operational parameters of a monitored object.
4377 </para>
4378
4379 <subsubsection>
4380 <heading>The fields</heading>
4381 <para>
4382 The fields of the <emph>property</emph> table are listed below:
4383 </para>
4384 <table cpos='lllp{6cm}'>
4385       <thead>
4386         <col> Fieldname </col> <col> Fieldtype </col> <col> Size </col>
4387         <col> Remarks </col>
4388       </thead>
4389       <row>
4390         <col>paramid</col><col>bigint</col><col>8</col>
4391         <col>The parameter to which this property belongs. Refers to the parameter table</col>
4392       </row>
4393       <row>
4394         <col>name</col><col>text</col><col> </col>
4395         <col>Name of the property</col>
4396       </row>
4397       <row>
4398         <col>value</col><col>text</col><col> </col>
4399         <col>The current value of the property</col>
4400       </row>
4401       <row>
4402         <col>type</col><col>enum</col><col> </col>
4403         <col>Dynamic or Static</col>
4404       </row>
4405       <row>
4406         <col>minimum</col><col>float</col><col>8</col>
4407         <col>The minimum value of the property (for numerical properties only)</col>
4408       </row>
4409       <row>
4410         <col>maximum</col><col>float</col><col>8</col>
4411         <col>The maximum value of the property (for numerical properties only)</col>
4412       </row>
4413       
4414 </table>
4415
4416 </subsubsection>
4417 <subsubsection>
4418 <heading>Sample data</heading>
4419
4420 <para>
4421 The table below lists a few examples of properties
4422 </para>
4423 <table cpos='llllll'>
4424    <thead>
4425       <col>paramid</col><col>name</col><col>value</col>
4426       <col>type</col><col>minimum</col><col>maximum</col>
4427    </thead>
4428    <row>
4429       <col>1</col><col>size</col><col>400000</col>
4430       <col>STATIC</col><col>100000</col><col>999999999</col>
4431    </row>
4432    <row>
4433       <col>1</col><col>used</col><col>200000</col>
4434       <col>DYNAMIC</col><col>50000</col><col>400000</col>
4435    </row>
4436    <row>
4437       <col>2</col><col>size</col><col>3000000</col>
4438       <col>STATIC</col><col>100000</col><col>999999999</col>
4439    </row>
4440    <row>
4441       <col>2</col><col>used</col><col>2000000</col>
4442       <col>DYNAMIC</col><col>50000</col><col>2700000</col>
4443    </row>
4444    <row>
4445       <col>3</col><col>version</col><col>2.2.5-39</col>
4446       <col>STATIC</col><col>0</col><col>0</col>
4447    </row>
4448 </table>
4449 </subsubsection>
4450 </subsection>
4451
4452 <subsection>
4453   <heading>service</heading>
4454
4455 <para>
4456 The table <emph>service</emph> indicates the service that can be handled by the system.
4457 Out of the servicelist the administrator can indicate what services to expect.
4458 </para>
4459 <subsubsection>
4460   <heading>The fields.</heading>
4461
4462 <para>
4463 The fields are listed below:
4464 </para>
4465 <table cpos='lllp{6cm}'>
4466       <thead>
4467         <col>
4468           <para>Fieldname</para>
4469         </col>
4470         <col>
4471           <para>Fieldtype</para>
4472         </col>
4473         <col>
4474           <para>Size</para>
4475         </col>
4476         <col>
4477           <para>Remarks</para>
4478         </col>
4479       </thead>
4480       <row>
4481         <col>
4482           <para>servicecode</para>
4483         </col>
4484         <col>
4485           <para>Text</para>
4486         </col>
4487         <col>
4488           <para/>
4489         </col>
4490         <col>
4491           <para>The code that is written for the service</para>
4492         </col>
4493       </row>
4494       <row>
4495         <col>
4496           <para>servicename</para>
4497         </col>
4498         <col>
4499           <para>Text</para>
4500         </col>
4501         <col>
4502           <para/>
4503         </col>
4504         <col>
4505           <para>The expanded name for the service</para>
4506         </col>
4507       </row>
4508       <row>
4509         <col>
4510           <para>default_priority</para>
4511         </col>
4512         <col>
4513           <para>Int</para>
4514         </col>
4515         <col>
4516           <para>4</para>
4517         </col>
4518         <col>
4519           <para>The advised priority if these log-entries don't
4520            come in<footnote>Advised priorities can be changed in the object_service
4521            table per object. </footnote>.</para>
4522         </col>
4523       </row>
4524       <row>
4525         <col>
4526           <para>max_priority</para>
4527         </col>
4528         <col>
4529           <para>Int</para>
4530         </col>
4531         <col>
4532           <para>4</para>
4533         </col>
4534         <col>
4535           <para>The maximum priority advised for this
4536           service<footnote>Advised priorities can be changed in the
4537           object_service table per object.</footnote>.</para>
4538         </col>
4539       </row>
4540     </table>
4541 </subsubsection>
4542
4543 <subsubsection>
4544   <heading>The indexes.</heading>
4545
4546 <para>
4547 The table is indexed on the following fields:
4548 </para>
4549 <table cpos='lll'>
4550       <thead>
4551         <col>
4552           <para>Indexname</para>
4553         </col>
4554         <col>
4555           <para>Field</para>
4556         </col>
4557         <col>
4558           <para>Characteristics</para>
4559         </col>
4560       </thead>
4561       <row>
4562         <col>
4563           <para>ser_pk</para>
4564         </col>
4565         <col>
4566           <para>servicecode</para>
4567         </col>
4568         <col>
4569           <para>Primary key</para>
4570         </col>
4571       </row>
4572       <row>
4573         <col>
4574           <para>ser_servicename</para>
4575         </col>
4576         <col>
4577           <para>servicename</para>
4578         </col>
4579         <col>
4580           <para>Unique</para>
4581         </col>
4582       </row>
4583     </table>
4584 </subsubsection>
4585
4586 <subsubsection>
4587   <heading>The relationships.</heading>
4588 <para>
4589 Relationships with other tables:
4590 </para>
4591 <table cpos='llp{8cm}'>
4592       <thead>
4593         <col>
4594           <para>Fieldname</para>
4595         </col>
4596         <col>
4597           <para>Remote Table</para>
4598         </col>
4599         <col>
4600           <para>Remarks</para>
4601         </col>
4602       </thead>
4603       <row>
4604         <col>
4605           <para>servicecode</para>
4606         </col>
4607         <col>
4608           <para>log</para>
4609         </col>
4610         <col>
4611           <para>What log entries have been tied to this type of service.</para>
4612         </col>
4613       </row>
4614       <row>
4615         <col>
4616           <para/>
4617         </col>
4618         <col>
4619           <para>object_service</para>
4620         </col>
4621         <col>
4622           <para>Settings for this service per object.</para>
4623         </col>
4624       </row>
4625       <row>
4626         <col>
4627           <para/>
4628         </col>
4629         <col>
4630           <para>unprocessed_log</para>
4631         </col>
4632         <col>
4633           <para>What unprocessed log entries have been tied to this type of service.</para>
4634         </col>
4635       </row>
4636     </table>
4637  
4638     <para>In the model this look like this:</para>
4639     <para>
4640       <picture src="erd-service.png" eps="erd-service"/>
4641     </para>
4642 </subsubsection>
4643 </subsection>
4644
4645 <subsection>
4646   <heading>status.</heading>
4647
4648 <para>
4649 The table <emph>status</emph> contains the possible states that a notification can have.
4650 As with the table <emph>priority</emph> these statuses are limited in number by
4651 default but can be expanded. Also here retrieval prevails above data entry and
4652 therefor indexing is important.
4653 </para>
4654
4655 <subsubsection>
4656   <heading>The fields.</heading>
4657
4658 <para>
4659 The fields of the <emph>status</emph> table are listed below:
4660 </para>
4661
4662 <table cpos='lllp{6cm}'>
4663       <thead>
4664         <col>
4665           <para>Fieldname</para>
4666         </col>
4667         <col>
4668           <para>Fieldtype</para>
4669         </col>
4670         <col>
4671           <para>Size</para>
4672         </col>
4673         <col>
4674           <para>Remarks</para>
4675         </col>
4676       </thead>
4677       <row>
4678         <col>
4679           <para>statuscode</para>
4680         </col>
4681         <col>
4682           <para>Varchar</para>
4683         </col>
4684         <col>
4685           <para>3</para>
4686         </col>
4687         <col>
4688           <para>The code for the status</para>
4689         </col>
4690       </row>
4691       <row>
4692         <col>
4693           <para>statusname</para>
4694         </col>
4695         <col>
4696           <para>Text</para>
4697         </col>
4698         <col>
4699           <para/>
4700         </col>
4701         <col>
4702           <para>What is the correct name for the status</para>
4703         </col>
4704       </row>
4705       <row>
4706         <col>
4707           <para>open_notification</para>
4708         </col>
4709         <col>
4710           <para>Boolean</para>
4711         </col>
4712         <col>
4713           <para/>
4714         </col>
4715         <col>
4716           <para>Is the notification still open when this status is set? Yes = T / No = F</para>
4717         </col>
4718       </row>
4719       <row>
4720         <col>
4721           <para>description</para>
4722         </col>
4723         <col>
4724           <para>Text</para>
4725         </col>
4726         <col>
4727           <para/>
4728         </col>
4729         <col>
4730           <para>Explanation of the code</para>
4731         </col>
4732       </row>
4733     </table>
4734 </subsubsection>
4735
4736 <subsubsection>
4737   <heading>The indexes.</heading>
4738 <para>
4739 The table is indexed on the following fields:
4740 </para>
4741
4742 <table cpos='lll'>
4743       <thead>
4744         <col>
4745           <para>Indexname</para>
4746         </col>
4747         <col>
4748           <para>Field</para>
4749         </col>
4750         <col>
4751           <para>Characteristics</para>
4752         </col>
4753       </thead>
4754       <row>
4755         <col>
4756           <para>sta_pk</para>
4757         </col>
4758         <col>
4759           <para>statuscode</para>
4760         </col>
4761         <col>
4762           <para>Primary key</para>
4763         </col>
4764       </row>
4765       <row>
4766         <col>
4767           <para>sta_statusname</para>
4768         </col>
4769         <col>
4770           <para>statusname</para>
4771         </col>
4772         <col>
4773           <para>Unique</para>
4774         </col>
4775       </row>
4776       <row>
4777         <col>
4778           <para>sta_open_notification</para>
4779         </col>
4780         <col>
4781           <para>open_notification</para>
4782         </col>
4783         <col>
4784           <para/>
4785         </col>
4786       </row>
4787     </table>
4788 </subsubsection>
4789
4790 <subsubsection>
4791   <heading>The relationships.</heading>
4792 <para>
4793 Relationships with other tables
4794 </para>
4795
4796 <table cpos='lll'>
4797       <thead>
4798         <col>
4799           <para>Fieldname</para>
4800         </col>
4801         <col>
4802           <para>Remote Table</para>
4803         </col>
4804         <col>
4805           <para>Remarks</para>
4806         </col>
4807       </thead>
4808       <row>
4809         <col>
4810           <para/>
4811         </col>
4812         <col>
4813           <para/>
4814         </col>
4815         <col>
4816           <para/>
4817         </col>
4818       </row>
4819     </table>
4820     <para>In the model this look like this:</para>
4821     <para>
4822       <picture src="erd-status.png" eps="erd-status"/>
4823     </para>
4824 </subsubsection>
4825
4826 <subsubsection>
4827   <heading>Default values.</heading>
4828 <para>The status values are default for the system and for that reason are predefined.</para>
4829 <table cpos='p{2cm}lp{1cm}p{6cm}'>
4830       <thead>
4831         <col>
4832           <para>Statuscode</para>
4833         </col>
4834         <col>
4835           <para>Statusname</para>
4836         </col>
4837         <col>
4838           <para>Open Notification</para>
4839         </col>
4840         <col>
4841           <para/>
4842         </col>
4843       </thead>
4844       <row>
4845         <col>
4846           <para>new</para>
4847         </col>
4848         <col>
4849           <para>New entry</para>
4850         </col>
4851         <col>
4852           <para>T</para>
4853         </col>
4854         <col>
4855           <para>Just detected nothing has been done yet.</para>
4856         </col>
4857       </row>
4858       <row>
4859         <col>
4860           <para>opn</para>
4861         </col>
4862         <col>
4863           <para>Open</para>
4864         </col>
4865         <col>
4866           <para>T</para>
4867         </col>
4868         <col>
4869           <para>The notification has been displayed, but nothing has been done yet.</para>
4870         </col>
4871       </row>
4872       <row>
4873         <col>
4874           <para>pen</para>
4875         </col>
4876         <col>
4877           <para>Pending</para>
4878         </col>
4879         <col>
4880           <para>T</para>
4881         </col>
4882         <col>
4883           <para>The notification is currently being worked on.</para>
4884         </col>
4885       </row>
4886       <row>
4887         <col>
4888           <para>ver</para>
4889         </col>
4890         <col>
4891           <para>Waiting for verification</para>
4892         </col>
4893         <col>
4894           <para>T</para>
4895         </col>
4896         <col>
4897           <para>The notification has been worked on.
4898           After it has been verified the notification can be closed.</para>
4899         </col>
4900       </row>
4901       <row>
4902         <col>
4903           <para>cls</para>
4904         </col>
4905         <col>
4906           <para>Closed</para>
4907         </col>
4908         <col>
4909           <para>F</para>
4910         </col>
4911         <col>
4912           <para>The notification has been closed</para>
4913         </col>
4914       </row>
4915       <row>
4916         <col>
4917           <para>rej</para>
4918         </col>
4919         <col>
4920           <para>Rejected</para>
4921         </col>
4922         <col>
4923           <para>F</para>
4924         </col>
4925         <col>
4926           <para>This was a false positive and has been rejected.</para>
4927         </col>
4928       </row>
4929       <row>
4930         <col>
4931           <para>inv</para>
4932         </col>
4933         <col>
4934           <para>Investigate</para>
4935         </col>
4936         <col>
4937           <para>T</para>
4938         </col>
4939         <col>
4940           <para>The notification is under investigation and awaiting additional details.</para>
4941         </col>
4942       </row>
4943     </table>
4944 </subsubsection>
4945 </subsection>
4946
4947 <subsection>
4948   <heading>type_of_issue.</heading>
4949
4950 <para>
4951 This table will contain a list of all available issues that can be detected.
4952 All issues have a suggested priority setting.
4953 This is typically data retrieval and good indexing is needed.</para>
4954
4955 <subsubsection>
4956   <heading>The fields.</heading>
4957
4958 <para>
4959 Fields of <emph>type_of_issue</emph> are:
4960 </para>
4961
4962 <table cpos='lllp{6cm}'>
4963       <thead>
4964         <col>
4965           <para>Fieldname</para>
4966         </col>
4967         <col>
4968           <para>Fieldtype</para>
4969         </col>
4970         <col>
4971           <para>Size</para>
4972         </col>
4973         <col>
4974           <para>Remarks</para>
4975         </col>
4976       </thead>
4977       <row>
4978         <col>
4979           <para>type_of_issueid</para>
4980         </col>
4981         <col>
4982           <para>Bigserial</para>
4983         </col>
4984         <col>
4985           <para>8</para>
4986         </col>
4987         <col>
4988           <para>The sequential code for the issue.</para>
4989         </col>
4990       </row>
4991       <row>
4992         <col>
4993           <para>name</para>
4994         </col>
4995         <col>
4996           <para>Text</para>
4997         </col>
4998         <col>
4999           <para/>
5000         </col>
5001         <col>
5002           <para>Name for the issue</para>
5003         </col>
5004       </row>
5005       <row>
5006         <col>
5007           <para>suggested_priority</para>
5008         </col>
5009         <col>
5010           <para>Int</para>
5011         </col>
5012         <col>
5013           <para>4</para>
5014         </col>
5015         <col>
5016           <para>The advised priority setting.</para>
5017         </col>
5018       </row>
5019       <row>
5020         <col>
5021           <para>description</para>
5022         </col>
5023         <col>
5024           <para>Text</para>
5025         </col>
5026         <col>
5027           <para/>
5028         </col>
5029         <col>
5030           <para>Description of the method and how this can be set.</para>
5031         </col>
5032       </row>
5033       <row>
5034         <col>
5035           <para>active</para>
5036         </col>
5037         <col>
5038           <para>Boolean</para>
5039         </col>
5040         <col>
5041           <para/>
5042         </col>
5043         <col>
5044           <para>Is this check currently being used in the system.</para>
5045         </col>
5046       </row>
5047     </table>
5048 </subsubsection>
5049
5050 <subsubsection>
5051   <heading>The indexes.</heading>
5052 <para>
5053 The table is indexed on the following fields:
5054 </para>
5055
5056 <table cpos='lll'>
5057       <thead>
5058         <col>
5059           <para>Indexname</para>
5060         </col>
5061         <col>
5062           <para>Field</para>
5063         </col>
5064         <col>
5065           <para>Characteristics</para>
5066         </col>
5067       </thead>
5068       <row>
5069         <col>
5070           <para>toi_pk</para>
5071           <para>(type_of_issue_type_of_issue_key)</para>
5072         </col>
5073         <col>
5074           <para>type_of_issueid</para>
5075         </col>
5076         <col>
5077           <para>Primary key</para>
5078         </col>
5079       </row>
5080       <row>
5081         <col>
5082           <para>toi_name</para>
5083         </col>
5084         <col>
5085           <para>name</para>
5086         </col>
5087         <col>
5088           <para>Unique</para>
5089         </col>
5090       </row>
5091       <row>
5092         <col>
5093           <para>toi_active</para>
5094         </col>
5095         <col>
5096           <para>active</para>
5097         </col>
5098         <col>
5099           <para/>
5100         </col>
5101       </row>
5102     </table>
5103 </subsubsection>
5104
5105 <subsubsection>
5106   <heading>The relationships.</heading>
5107 <table cpos='lll'>
5108       <thead>
5109         <col>
5110           <para>Fieldname</para>
5111         </col>
5112         <col>
5113           <para>Remote Table</para>
5114         </col>
5115         <col>
5116           <para>Remarks</para>
5117         </col>
5118       </thead>
5119       <row>
5120         <col>
5121           <para>type_of_issueid</para>
5122         </col>
5123         <col>
5124           <para>object_issue</para>
5125         </col>
5126         <col>
5127           <para/>
5128         </col>
5129       </row>
5130     </table>
5131
5132     <para>In the model this look like this:</para>
5133     <para>
5134       <picture src="erd-toi.png" eps="erd-toi"/>
5135     </para>
5136 </subsubsection>
5137
5138 <subsubsection>
5139   <heading>Default values.</heading>
5140
5141 <para>
5142 All checks are entered as code into the system.
5143 This table only works for the application only.
5144 The user can set specifics in the application only.
5145 </para>
5146 <table cpos='lllll'>
5147       <thead>
5148         <col>
5149           <para>Type_of_issueid</para>
5150         </col>
5151         <col>
5152           <para>Name</para>
5153         </col>
5154         <col>
5155           <para>Suggested_priority</para>
5156         </col>
5157         <col>
5158           <para>Description</para>
5159         </col>
5160         <col>
5161           <para>Active</para>
5162         </col>
5163       </thead>
5164       <row>
5165         <col>
5166           <para>1</para>
5167         </col>
5168         <col>
5169           <para>Manual entry</para>
5170         </col>
5171         <col>
5172           <para>4</para>
5173         </col>
5174         <col>
5175           <para>A manual entry of a notification.</para>
5176         </col>
5177         <col>
5178           <para>T</para>
5179         </col>
5180       </row>
5181 </table>
5182 </subsubsection>
5183 </subsection>
5184
5185 <subsection>
5186   <heading>unprocessed_log</heading>
5187
5188 <para>
5189 The <emph>user</emph> table contains the users that can login the monitoring application.
5190 It will also store if the users maintains the system.
5191 Mainly used for retrieval so properly indexed.
5192 </para>
5193
5194 <subsubsection>
5195   <heading>The fields.</heading>
5196
5197 <para>
5198 The fields are listed below:
5199 </para>
5200
5201 <table cpos='lllp{6cm}'>
5202       <thead>
5203         <col>
5204           <para>Fieldname</para>
5205         </col>
5206         <col>
5207           <para>Fieldtype</para>
5208         </col>
5209         <col>
5210           <para>Size</para>
5211         </col>
5212         <col>
5213           <para>Remarks</para>
5214         </col>
5215       </thead>
5216       <row>
5217         <col>
5218           <para>unprocessedid</para>
5219         </col>
5220         <col>
5221           <para>Bigserial</para>
5222         </col>
5223         <col>
5224           <para/>
5225         </col>
5226         <col>
5227           <para>Autonumber entry</para>
5228         </col>
5229       </row>
5230       <row>
5231         <col>
5232           <para>objectid</para>
5233         </col>
5234         <col>
5235           <para>Bigint</para>
5236         </col>
5237         <col>
5238           <para/>
5239         </col>
5240         <col>
5241           <para>Reference to the object</para>
5242         </col>
5243       </row>
5244       <row>
5245         <col>
5246           <para>servicecode</para>
5247         </col>
5248         <col>
5249           <para>Text</para>
5250         </col>
5251         <col>
5252           <para/>
5253         </col>
5254         <col>
5255           <para>The service that entered this data.</para>
5256         </col>
5257       </row>
5258       <row>
5259         <col>
5260           <para>logdata</para>
5261         </col>
5262         <col>
5263           <para>Text</para>
5264         </col>
5265         <col>
5266           <para/>
5267         </col>
5268         <col>
5269           <para>The data that comes from the file.</para>
5270         </col>
5271       </row>
5272     </table>
5273 </subsubsection>
5274
5275 <subsubsection>
5276   <heading>The indexes.</heading>
5277 <para>
5278 The indices of the table:
5279 </para>
5280
5281 <table cpos='lll'>
5282       <thead>
5283         <col>
5284           <para>Indexname</para>
5285         </col>
5286         <col>
5287           <para>Field</para>
5288         </col>
5289         <col>
5290           <para>Characteristics</para>
5291         </col>
5292       </thead>
5293       <row>
5294         <col>
5295           <para>unl_pk</para>
5296           <para>(unprocessed_l_unprocessedid_key)</para>
5297         </col>
5298         <col>
5299           <para>unprocessedid</para>
5300         </col>
5301         <col>
5302           <para>Primary key</para>
5303         </col>
5304       </row>
5305     </table>
5306 </subsubsection>
5307
5308 <subsubsection>
5309   <heading>The relationships.</heading>
5310 <para>
5311 Relationships with other tables:
5312 </para>
5313
5314 <table cpos='llp{8cm}'>
5315       <thead>
5316         <col>
5317           <para>Fieldname</para>
5318         </col>
5319         <col>
5320           <para>Remote Table</para>
5321         </col>
5322         <col>
5323           <para>Remarks</para>
5324         </col>
5325       </thead>
5326       <row>
5327         <col>
5328           <para>objectid</para>
5329         </col>
5330         <col>
5331           <para>object</para>
5332         </col>
5333         <col>
5334           <para>Reference to the object that is reporting the data</para>
5335         </col>
5336       </row>
5337       <row>
5338         <col>
5339           <para>servicecode</para>
5340         </col>
5341         <col>
5342           <para>service</para>
5343         </col>
5344         <col>
5345           <para>Reference to the servicecode that is mentioned in the filename.</para>
5346         </col>
5347       </row>
5348     </table>
5349     <para>In the model this look like this:</para>
5350     <para>
5351       <picture src="erd-unplog.png" eps="erd-unplog"/>
5352     </para>
5353 </subsubsection>
5354
5355 <subsubsection>
5356   <heading>Sample values.</heading>
5357     <para>To do</para>
5358 </subsubsection>
5359 </subsection>
5360
5361 <subsection>
5362   <heading>user_gnucomo</heading>
5363
5364 <para>
5365 The <emph>user</emph> table contains the users that can login the monitoring application.
5366 It will also store if the users maintains the system.
5367 Mainly used for retrieval so properly indexed.
5368 </para>
5369
5370 <subsubsection>
5371   <heading>The fields.</heading>
5372
5373 <para>
5374 The fields are listed in the table below:
5375 </para>
5376
5377 <table cpos='lllp{6cm}'>
5378       <thead>
5379         <col>
5380           <para>Fieldname</para>
5381         </col>
5382         <col>
5383           <para>Fieldtype</para>
5384         </col>
5385         <col>
5386           <para>Size</para>
5387         </col>
5388         <col>
5389           <para>Remarks</para>
5390         </col>
5391       </thead>
5392       <row>
5393         <col>
5394           <para>username</para>
5395         </col>
5396         <col>
5397           <para>Text</para>
5398         </col>
5399         <col>
5400           <para/>
5401         </col>
5402         <col>
5403           <para>Name the user is known by</para>
5404         </col>
5405       </row>
5406       <row>
5407         <col>
5408           <para>password</para>
5409         </col>
5410         <col>
5411           <para>Text</para>
5412         </col>
5413         <col>
5414           <para/>
5415         </col>
5416         <col>
5417           <para>Password</para>
5418         </col>
5419       </row>
5420       <row>
5421         <col>
5422           <para>active_sessionid</para>
5423         </col>
5424         <col>
5425           <para>Bigint</para>
5426         </col>
5427         <col>
5428           <para/>
5429         </col>
5430         <col>
5431           <para>Sessionnumber currently used by user.
5432           If this is set to 0 a user is not present on the system.
5433           Only one session can be open at a time.</para>
5434         </col>
5435       </row>
5436       <row>
5437         <col>
5438           <para>account_active</para>
5439         </col>
5440         <col>
5441           <para>Boolean</para>
5442         </col>
5443         <col>
5444           <para/>
5445         </col>
5446         <col>
5447           <para>Is the account currently active?</para>
5448         </col>
5449       </row>
5450       <row>
5451         <col>
5452           <para>security_level</para>
5453         </col>
5454         <col>
5455           <para>Int</para>
5456         </col>
5457         <col>
5458           <para/>
5459         </col>
5460         <col>
5461           <para>Given securitylevel to this user</para>
5462         </col>
5463       </row>
5464     </table>
5465 </subsubsection>
5466
5467 <subsubsection>
5468   <heading>The indexes</heading>
5469 <para>
5470 The table is indexed on the following fields:
5471 </para>
5472 <table cpos='lll'>
5473       <thead>
5474         <col>
5475           <para>Indexname</para>
5476         </col>
5477         <col>
5478           <para>Field</para>
5479         </col>
5480         <col>
5481           <para>Characteristics</para>
5482         </col>
5483       </thead>
5484       <row>
5485         <col>
5486           <para>usr_pk</para>
5487         </col>
5488         <col>
5489           <para>username</para>
5490         </col>
5491         <col>
5492           <para>Primary key</para>
5493         </col>
5494       </row>
5495       <row>
5496         <col>
5497           <para>usr_active_sessionid</para>
5498         </col>
5499         <col>
5500           <para>active_sessionid</para>
5501         </col>
5502         <col>
5503           <para>Unique</para>
5504         </col>
5505       </row>
5506     </table>
5507 </subsubsection>
5508
5509 <subsubsection>
5510   <heading>The relationships.</heading>
5511 <para>
5512 Relationships with other tables
5513 </para>
5514 <table cpos='lll'>
5515       <thead>
5516         <col>
5517           <para>Fieldname</para>
5518         </col>
5519         <col>
5520           <para>Remote Table</para>
5521         </col>
5522         <col>
5523           <para>Remarks</para>
5524         </col>
5525       </thead>
5526       <row>
5527         <col>
5528           <para>ObjectID</para>
5529         </col>
5530         <col>
5531           <para>Object</para>
5532         </col>
5533         <col>
5534           <para>Link to the object</para>
5535         </col>
5536       </row>
5537     </table>
5538     <para>In the model this look like this:</para>
5539     <para>
5540       <picture src="erd-usr.png" eps="erd-usr"/>
5541     </para>
5542 </subsubsection>
5543 </subsection>
5544 </section>
5545
5546 </chapter>
5547
5548 <chapter>
5549   <heading>Warnings that can be detected.</heading>
5550 </chapter>
5551
5552     <chapter>
5553       <heading>User Interface.</heading>
5554
5555     <para>To be determined in the near future.</para>
5556 </chapter>
5557
5558 <chapter>
5559   <heading>The installation process.</heading>
5560
5561 <para>
5562 Since the system must make maintenance and security easier to use,
5563 the burden of installation should as easy as possible.
5564 Where possible the installation script should take away as much work as possible.
5565 Where settings need to be done, this should be done through an interface.
5566 However at no point we take the user's right to understand and work with system.
5567 Configuration-files should be easy to understand and the choice must be there to do installation manually.
5568 For the time being, we will use the manual installation procedure outlined below:
5569 </para>
5570
5571 <para>
5572 Since there is no binary package available for Gnucomo yet, you will need
5573 to compile and install Gnucomo from the source code.
5574 Before making the Gnucomo binaries, make sure you have the following
5575 packages installed:
5576 <itemize>
5577 <item>postgresql, postgresql-server, postgresql-develop</item>
5578 <item>AXE</item>
5579 <item>libxml2, libxml2-develop</item>
5580 </itemize>
5581
5582 Make sure your PostgreSQL database server is up and running.
5583 If you also want to use the web interface, you will need Apache with PHP.
5584 The PHP module needs Postgresql and DOM-XML support.
5585 With all required packages installed, you should be able to go into
5586 the <emph>src</emph> directory and type <code>make</code> to create
5587 a binary <code>gcm_input</code>.
5588 </para>
5589
5590 <para>
5591 To use gnucomo, you need to create a database and a configuration file.
5592 To make the database in your PostgreSQL server, log in as a DBA (DataBase
5593 Administrator, usually the user 'postgres') and create the database and a
5594 user who can use the database.
5595 Here is an example:
5596
5597 <verbatim>
5598
5599   createdb gnucomo
5600   createuser arjen
5601
5602 </verbatim>
5603
5604 If you also want to be able to use the test scripts, you will need to
5605 create the <code>gnucomo_test</code> database as well.
5606 The configuration file for Gnucomo is a rather simple XML file that
5607 states at least what database Gnucomo uses and the userid with which
5608 Gnucomo will log in to the database server.
5609 These parameters should be the same as the database and user you just
5610 created in your role of DBA.
5611 There is an example configuration file, <code>gnucomo.conf</code> in the
5612 <emph>src</emph> directory.
5613 You should copy this config file to one of the following places:
5614 <enumerate>
5615 <item><code>/etc/gnucomo.conf</code></item>
5616 <item><code>/usr/local/etc/gnucomo.conf</code></item>
5617 </enumerate>
5618 With the database and the configuration file in place, you should
5619 be able to run <code>gcm_input</code> to read log files and store
5620 log entries in the database.
5621 </para>
5622     <section>
5623       <heading>Supported platforms.</heading>
5624
5625     <para>The following two Linux distributions have been selected to be actively supported:</para>
5626     <itemize>
5627       <item>
5628         <para>Debian GNU/Linux (.deb packages)</para>
5629       </item>
5630       <item>
5631         <para>RedHat Linux (.rpm packages)</para>
5632       </item>
5633     </itemize>
5634     <para>
5635       We will try and facilitate as many operating systems client-side and
5636        as many unices server-side, but efforts on testing out of the projects
5637        will be very minimalistic to ensure that the project keeps delivering
5638        new version and new features.
5639     </para>
5640     </section>
5641
5642     <section>
5643       <heading>Installation on the server.</heading>
5644
5645     <para>The following steps will be part of a script, that can automatically perform these steps:</para>
5646
5647 <enumerate>
5648     <item>
5649       <para>Create the user <emph>gnucomo</emph>.</para>
5650     </item>
5651     <item>
5652       <para>Make the directory as described in the chapter <emph>Sending messages to the central gnucomo system</emph> in the subchapter <emph>directories</emph>.(server-side).</para>
5653     </item>
5654 </enumerate>
5655     </section>
5656
5657     <section>
5658       <heading>Installation on a UNIX-client.</heading>
5659
5660     <para>The following steps will be part of a script, that can automatically perform these steps:</para>
5661 <enumerate>
5662     <item>
5663       <para>Create the user <emph>gcm_client</emph>.</para>
5664     </item>
5665     <item>
5666       <para>Make the directory as described in the chapter <emph>Sending messages to the central gnucomo system</emph> in the subchapter <emph>directories</emph> (client-side).</para>
5667     </item>
5668     <item>
5669       <para>Creation of the database user gcm_input. This user has only the right to enter data into the database. There are no deletion, update or select-permissions.</para>
5670     </item>
5671 </enumerate>
5672
5673     </section>
5674     </chapter>
5675
5676 <chapter>
5677   <heading>Dependency on other free software.</heading>
5678
5679 <para>The following list is a set of applications that will be used on to make our application work:</para>
5680     <table cpos='lp{8cm}l'>
5681       <thead>
5682         <col>
5683           <para>Application</para>
5684         </col>
5685         <col>
5686           <para>Needed for</para>
5687         </col>
5688         <col>
5689           <para>Client/Server</para>
5690         </col>
5691       </thead>
5692       <row>
5693         <col>
5694           <para>gpg</para>
5695         </col>
5696         <col>
5697           <para>The encryption of the information being transferred between the two systems.</para>
5698         </col>
5699         <col>
5700           <para>Client</para>
5701           <para>Server</para>
5702         </col>
5703       </row>
5704       <row>
5705         <col>
5706           <para>GNU/Linux</para>
5707         </col>
5708         <col>
5709           <para>The basic operating system. Allthough the system might work very well on all types on versions of Linux, FreeBSD, OpenBSD or any unices the main focus for distribution is given to: Debian GNU/Linux and RedHat Linux (the downloadable iso-version). </para>
5710         </col>
5711         <col>
5712           <para>Server</para>
5713         </col>
5714       </row>
5715       <row>
5716         <col>
5717           <para>mail</para>
5718         </col>
5719         <col>
5720           <para>The application enabling the sending of messages.</para>
5721         </col>
5722         <col>
5723           <para>Client</para>
5724           <para>Server</para>
5725         </col>
5726       </row>
5727       <row>
5728         <col>
5729           <para>openssh</para>
5730         </col>
5731         <col>
5732           <para>If e-mail is not used this application will deliver the file-copy</para>
5733         </col>
5734         <col>
5735           <para>Client</para>
5736           <para>Server</para>
5737         </col>
5738       </row>
5739       <row>
5740         <col>
5741           <para>PostgreSQL</para>
5742         </col>
5743         <col>
5744           <para>The database where all the signals from client will be stored.</para>
5745         </col>
5746         <col>
5747           <para>Client</para>
5748         </col>
5749       </row>
5750     </table>
5751 <section>
5752 <heading>Related projects</heading>
5753
5754 <para>
5755 There are a number of projects that can help <strong>Gnucomo</strong> or perform
5756 similar funtions:
5757
5758 <itemize>
5759    <item>
5760    <reference href='http://crm114.sourceforge.net/'>CRM114</reference> - The Controllable
5761    Regex Mutilator.
5762    </item>
5763 </itemize>
5764 </para>
5765 </section>
5766 </chapter>
5767
5768 <chapter>
5769   <heading>Settings on the server machine.</heading>
5770
5771 <section>
5772   <heading>Required.</heading>
5773
5774 <para>The following settings are required to ensure that the functionality is as much as expected.</para>
5775
5776 <subsection>
5777   <heading>Timezone in GMT (UTC).</heading>
5778
5779 <para>Since all international traffic registers all entries in UTC (Universal Time Coordinate) this system will do so as well. Therefore the clock has to be adjusted to that as well as the system settings.</para>
5780 <para>These settings can found on a RedHat computer in the <code>/etc/sysconfig/clock-file</code>. On Debian this stored in the file <code>/etc/timezone</code>.</para>
5781 </subsection>
5782 </section>
5783
5784 <section>
5785   <heading>Suggested.</heading>
5786
5787 <subsection>
5788   <heading>Use NTP.</heading>
5789
5790 <para>If a computer is running for some time the clocks tend to be off the correct time. This makes it harder to detect what exactly happened exactly at what moment in time and reduce value of log-entries. Especially considering that ultimately all data is gathered in one central system. To overcome this Network Time Protocol (NTP RFC 13025 March 1992) has been created that explains a protocol to synchronize clocks through the Internet. Many operating systems like Microsoft Windows 2000 Server and FreeBSD, OpenBSD and Linux  support this. A ntp-server (or ntpd) can be found at: http://www.eecis.udel.edu/~ntp/ It is strongly recommended that you use this.</para>
5791
5792     </subsection>
5793     </section>
5794     </chapter>
5795
5796     <chapter>
5797       <heading>Settings on the client machine.</heading>
5798
5799     <section>
5800       <heading>Required.</heading>
5801     </section>
5802
5803     <section>
5804       <heading>Suggested.</heading>
5805
5806     <subsection>
5807       <heading>Use NTP.</heading>
5808
5809     <para>If a computer is running for some time the clocks tend to be off the correct time. This makes it harder to detect what exactly happened exactly at what moment in time and reduce value of log-entries. Especially considering that ultimately all data is gathered in one central system. To overcome this Network Time Protocol (NTP RFC 13025 March 1992) has been created that explains a protocol to synchronize clocks through the Internet. Many operating systems like Microsoft Windows 2000 Server and FreeBSD, OpenBSD and Linux  support this. A ntp-server (or ntpd) can be found at: http://www.eecis.udel.edu/~ntp/ It is strongly recommended that you use this.</para>
5810
5811     </subsection>
5812     </section>
5813     </chapter>
5814
5815     <chapter>
5816       <heading>Appendices.</heading>
5817
5818     <section>
5819       <heading>Appendix A. GNU Public License Version 2, June 1991.</heading>
5820
5821     <para>Copyright (C) 1989, 1991 Free Software Foundation, Inc.</para>
5822     <para>59 Temple Place, Suite 330, Boston, MA 02111-1307 USA</para>
5823     <para>Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed.</para>
5824
5825     <subsection>
5826       <heading>Preamble</heading>
5827     <para>The licenses for most software are designed to take away your freedom to share and change it. By contrast, the GNU General Public License is intended to guarantee your freedom to share and change free software--to make sure the software is free for all its users. This General Public License applies to most of the Free Software Foundation's software and to any other program whose authors commit to using it. (Some other Free Software Foundation software is covered by the GNU Library General Public License instead.) You can apply it to your programs, too. </para>
5828     <para>When we speak of free software, we are referring to freedom, not price. Our General Public Licenses are designed to make sure that you have the freedom to distribute copies of free software (and charge for this service if you wish), that you receive source code or can get it if you want it, that you can change the software or use pieces of it in new free programs; and that you know you can do these things.</para>
5829     <para>To protect your rights, we need to make restrictions that forbid anyone to deny you these rights or to ask you to surrender the rights. These restrictions translate to certain responsibilities for you if you distribute copies of the software, or if you modify it.</para>
5830     <para>For example, if you distribute copies of such a program, whether gratis or for a fee, you must give the recipients all the rights that you have. You must make sure that they, too, receive or can get the source code. And you must show them these terms so they know their rights.</para>
5831     <para>We protect your rights with two steps: (1) copyright the software, and (2) offer you this license which gives you legal permission to copy, distribute and/or modify the software. </para>
5832     <para>Also, for each author's protection and ours, we want to make certain that everyone understands that there is no warranty for this free software. If the software is modified by someone else and passed on, we want its recipients to know that what they have is not the original, so that any problems introduced by others will not reflect on the original authors' reputations.</para>
5833     <para>Finally, any free program is threatened constantly by software patents. We wish to avoid the danger that redistributors of a free program will individually obtain patent licenses, in effect making the program proprietary. To prevent this, we have made it clear that any patent must be licensed for everyone's free use or not licensed at all.</para>
5834     <para>The precise terms and conditions for copying, distribution and modification follow.</para>
5835     <para>GNU GENERAL PUBLIC LICENSE</para>
5836     </subsection>
5837
5838     <subsection>
5839       <heading>TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION</heading>
5840
5841 <enumerate>
5842     <item>
5843       <para>This License applies to any program or other work which contains a notice placed by the copyright holder saying it may be distributed under the terms of this General Public License. The &quot;Program&quot;, below, refers to any such program or work, and a &quot;work based on the Program&quot; means either the Program or any derivative work under copyright law: that is to say, a work containing the Program or a portion of it, either verbatim or with modifications and/or translated into another language. (Hereinafter, translation is included without limitation in the term &quot;modification&quot;.) Each licensee is addressed as &quot;you&quot;.</para>
5844     <para>Activities other than copying, distribution and modification are not covered by this License; they are outside its scope. The act of running the Program is not restricted, and the output from the Program is covered only if its contents constitute a work based on the Program (independent of having been made by running the Program). Whether that is true depends on what the Program does. </para>
5845     </item>
5846     <item>
5847       <para>You may copy and distribute verbatim copies of the Program's source code as you receive it, in any medium, provided that you conspicuously and appropriately publish on each copy an appropriate copyright notice and disclaimer of warranty; keep intact all the notices that refer to this License and to the absence of any warranty; and give any other recipients of the Program a copy of this License along with the Program.</para>
5848     <para>You may charge a fee for the physical act of transferring a copy, and you may at your option offer warranty protection in exchange for a fee.</para>
5849     </item>
5850     <item>
5851       <para>You may modify your copy or copies of the Program or any portion of it, thus forming a work based on the Program, and copy and distribute such modifications or work under the terms of Section 1 above, provided that you also meet all of these conditions:</para>
5852     <para>a) You must cause the modified files to carry prominent notices stating that you changed the files and the date of any change.</para>
5853     <para>b) You must cause any work that you distribute or publish, that in whole or in part contains or is derived from the Program or any part thereof, to be licensed as a whole at no charge to all third parties under the terms of this License.</para>
5854     <para>c) If the modified program normally reads commands interactively when run, you must cause it, when started running for such interactive use in the most ordinary way, to print or display an announcement including an appropriate copyright notice and a notice that there is no warranty (or else, saying that you provide a warranty) and that users may redistribute the program under these conditions, and telling the user how to view a copy of this License. (Exception: if the Program itself is interactive but does not normally print such an announcement, your work based on the Program is not required to print an announcement.)</para>
5855     <para>These requirements apply to the modified work as a whole. If identifiable sections of that work are not derived from the Program, and can be reasonably considered independent and separate works in themselves, then this License, and its terms, do not apply to those sections when you distribute them as separate works. But when you distribute the same sections as part of a whole which is a work based on the Program, the distribution of the whole must be on the terms of this License, whose permissions for other licensees extend to the entire whole, and thus to each and every part regardless of who wrote it.</para>
5856     <para>Thus, it is not the intent of this section to claim rights or contest your rights to work written entirely by you; rather, the intent is to exercise the right to control the distribution of derivative or collective works based on the Program.</para>
5857     <para>In addition, mere aggregation of another work not based on the Program with the Program (or with a work based on the Program) on a volume of a storage or distribution medium does not bring the other work under the scope of this License.</para>
5858     </item>
5859     <item>
5860       <para>You may copy and distribute the Program (or a work based on it, under Section 2) in object code or executable form under the terms of Sections 1 and 2 above provided that you also do one of the following:</para>
5861     <para>a) Accompany it with the complete corresponding machine-readable source code, which must be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or, </para>
5862     <para>b) Accompany it with a written offer, valid for at least three years, to give any third party, for a charge no more than your cost of physically performing source distribution, a complete machine-readable copy of the corresponding source code, to be distributed under the terms of Sections 1 and 2 above on a medium customarily used for software interchange; or,</para>
5863     <para>c) Accompany it with the information you received as to the offer to distribute corresponding source code. (This alternative is allowed only for noncommercial distribution and only if you received the program in object code or executable form with such an offer, in accord with Subsection b above.)</para>
5864     <para>The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.</para>
5865     <para>If distribution of executable or object code is made by offering access to copy from a designated place, then offering equivalent access to copy the source code from the same place counts as distribution of the source code, even though third parties are not compelled to copy the source along with the object code.</para>
5866     </item>
5867     <item>
5868       <para>You may not copy, modify, sublicense, or distribute the Program except as expressly provided under this License. Any attempt otherwise to copy, modify, sublicense or distribute the Program is void, and will automatically terminate your rights under this License. However, parties who have received copies, or rights, from you under this License will not have their licenses terminated so long as such parties remain in full compliance.</para>
5869     </item>
5870     <item>
5871       <para>You are not required to accept this License, since you have not signed it. However, nothing else grants you permission to modify or distribute the Program or its derivative works. These actions are prohibited by law if you do not accept this License. Therefore, by modifying or distributing the Program (or any work based on the Program), you indicate your acceptance of this License to do so, and all its terms and conditions for copying, distributing or modifying the Program or works based on it.</para>
5872     </item>
5873     <item>
5874       <para>Each time you redistribute the Program (or any work based on the Program), the recipient automatically receives a license from the original licensor to copy, distribute or modify the Program subject to these terms and conditions. You may not impose any further restrictions on the recipients' exercise of the rights granted herein.</para>
5875     <para>You are not responsible for enforcing compliance by third parties to this License.</para>
5876     </item>
5877     <item>
5878       <para>If, as a consequence of a court judgment or allegation of patent infringement or for any other reason (not limited to patent issues), conditions are imposed on you (whether by court order, agreement or otherwise) that contradict the conditions of this License, they do not excuse you from the conditions of this License. If you cannot distribute so as to satisfy simultaneously your obligations under this License and any other pertinent obligations, then as a consequence you may not distribute the Program at all. For example, if a patent license would not permit royalty-free redistribution of the Program by all those who receive copies directly or indirectly through you, then the only way you could satisfy both it and this License would be to refrain entirely from distribution of the Program.</para>
5879     <para>If any portion of this section is held invalid or unenforceable under any particular circumstance, the balance of the section is intended to apply and the section as a whole is intended to apply in other circumstances.</para>
5880     <para>It is not the purpose of this section to induce you to infringe any patents or other property right claims or to contest validity of any such claims; this section has the sole purpose of protecting the integrity of the free software distribution system, which is implemented by public license practices. Many people have made generous contributions to the wide range of software distributed through that system in reliance on consistent application of that system; it is up to the author/donor to decide if he or she is willing to distribute software through any other system and a licensee cannot impose that choice.</para>
5881     <para>This section is intended to make thoroughly clear what is believed to be a consequence of the rest of this License.</para>
5882     </item>
5883     <item>
5884       <para>If the distribution and/or use of the Program is restricted in certain countries either by patents or by copyrighted interfaces, the original copyright holder who places the Program under this License may add an explicit geographical distribution limitation excluding those countries, so that distribution is permitted only in or among countries not thus excluded. In such case, this License incorporates the limitation as if written in the body of this License.</para>
5885     </item>
5886     <item>
5887       <para>The Free Software Foundation may publish revised and/or new versions of the General Public License from time to time. Such new versions will be similar in spirit to the present version, but may differ in detail to address new problems or concerns.</para>
5888     <para>Each version is given a distinguishing version number. If the Program specifies a version number of this License which applies to it and &quot;any later version&quot;, you have the option of following the terms and conditions either of that version or of any later version published by the Free Software Foundation. If the Program does not specify a version number of this License, you may choose any version ever published by the Free Software Foundation.</para>
5889     </item>
5890     <item>
5891       <para>If you wish to incorporate parts of the Program into other free programs whose distribution conditions are different, write to the author to ask for permission. For software which is copyrighted by the Free Software Foundation, write to the Free Software Foundation; we sometimes make exceptions for this. Our decision will be guided by the two goals of preserving the free status of all derivatives of our free software and of promoting the sharing and reuse of software generally.</para>
5892     </item>
5893 </enumerate>
5894     </subsection>
5895     <subsection>
5896       <heading>NO WARRANTY</heading>
5897 <enumerate>
5898     <item>
5899       <para>BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES PROVidE THE PROGRAM &quot;AS IS&quot; WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.</para>
5900     </item>
5901     <item>
5902       <para>IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH DAMAGES.</para>
5903     </item>
5904 </enumerate>
5905     <para>END OF TERMS AND CONDITIONS</para>
5906     </subsection>
5907     <subsection>
5908       <heading>How to Apply These Terms to Your New Programs</heading>
5909     <para>If you develop a new program, and you want it to be of the greatest possible use to the public, the best way to achieve this is to make it free software which everyone can redistribute and change under these terms. </para>
5910     <para>To do so, attach the following notices to the program. It is safest to attach them to the start of each source file to most effectively convey the exclusion of warranty; and each file should have at least the &quot;copyright&quot; line and a pointer to where the full notice is found.</para>
5911     <para>&lt;one line to give the program's name and a brief idea of what it does.&gt; Copyright (C) &lt;year&gt; &lt;name of author&gt; This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.</para>
5912     <para>This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.</para>
5913     <para>You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA</para>
5914     <para>Also add information on how to contact you by electronic and paper mail.</para>
5915     <para>If the program is interactive, make it output a short notice like this when it starts in an interactive mode:</para>
5916     <para>Gnomovision version 69, Copyright (C) year name of author</para>
5917     <para>Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.</para>
5918     <para>This is free software, and you are welcome to redistribute it under certain conditions; type `show c' for details.</para>
5919     <para/>
5920     <para>The hypothetical commands `show w' and `show c' should show the appropriate parts of the General Public License. Of course, the commands you use may be called something other than `show w' and `show c'; they could even be mouse-clicks or menu items--whatever suits your program.</para>
5921     <para>You should also get your employer (if you work as a programmer) or your school, if any, to sign a &quot;copyright disclaimer&quot; for the program, if necessary. Here is a sample; alter the names:</para>
5922     <para>Yoyodyne, Inc., hereby disclaims all copyright interest in the program `Gnomovision' (which makes passes at compilers) written by James Hacker. </para>
5923     <para>&lt;signature of Ty Coon&gt;, 1 April 1989 Ty Coon, President of Vice</para>
5924     <para>This General Public License does not permit incorporating your program into proprietary programs. If your program is a subroutine library, you may consider it more useful to permit linking proprietary applications with the library. If this is what you want to do, use the GNU Library General Public License instead of this License.</para>
5925     </subsection>
5926     </section>
5927     </chapter>
5928   </book>
5929 </doc>