|
@@ -1,29 +1,43 @@
|
|
|
# lcmlog-server
|
|
|
|
|
|
-Server side of a tool for reading and writing the lcm staff logs
|
|
|
+Server side of a tool for reading and writing the lcm staff logs.
|
|
|
The program doen't accept any command line options.
|
|
|
The first line of the input can be `GET`, `POST` or `UPDATE`.
|
|
|
|
|
|
-## The two kind of the logs
|
|
|
-To do
|
|
|
+**For the test session, only the account `log` can access.**
|
|
|
|
|
|
-## The authenticsation process
|
|
|
-To do
|
|
|
+## The two kind of logs
|
|
|
+Admins and 150 logs.
|
|
|
+
|
|
|
+_To do_
|
|
|
+
|
|
|
+## The authentication process
|
|
|
+In the main directory there is a folder named `auth` that contain the following files:
|
|
|
+* UPDATE
|
|
|
+* 150/
|
|
|
+ * GET
|
|
|
+ * POST
|
|
|
+* Admin/
|
|
|
+ * GET
|
|
|
+ * POST
|
|
|
+Every file contain the list of the euid of the users that can send and request logs and update the database. Now there is only the euid of the `log` account. If you want to add a new user, you have to add his euid in these files.
|
|
|
|
|
|
## The three methods
|
|
|
+The first line is always the name of the method.
|
|
|
+
|
|
|
### GET
|
|
|
The `GET` method is used to print all the logs that meet the required criteria.
|
|
|
-The second line of the input is the kind of the log to search for (see below), and it is the only mandatory parameter.
|
|
|
-The third line is the date: only logs whose date contains the searched for date are printed. The format for the date has not been decided yet, so currently any string can be inserted here.
|
|
|
-The fourth line is a list of comma separated tags to search for.
|
|
|
-The fifth line is the name of the user to search for.
|
|
|
+* The second line of the input is the kind of the log to search for (see below), and it is the only mandatory parameter.
|
|
|
+* The third line is the date: only logs whose date contains the searched for date are printed. The format for the date has not been decided yet, so currently any string can be inserted here.
|
|
|
+* The fourth line is a list of comma separated tags to search for.
|
|
|
+* The fifth line is the name of the user to search for.
|
|
|
|
|
|
### POST
|
|
|
The `POST` method is used to add a log to the database.
|
|
|
-The second line of the input is the kind (se below).
|
|
|
-The third one is the date.
|
|
|
-The fourth one is a list of comma separated tags.
|
|
|
-The remainder of the file (until EOF is met) is the content of the log.
|
|
|
+* The second line of the input is the kind (se below).
|
|
|
+* The third one is the date.
|
|
|
+* The fourth one is a list of comma separated tags.
|
|
|
+* The remainder of the file (until EOF is met) is the content of the log.
|
|
|
|
|
|
### UPDATE
|
|
|
The `UPDATE` method is used to regenerate the internal server database.
|
|
@@ -31,4 +45,4 @@ It should only be called if a log file is added by hand, or if some of the log f
|
|
|
It assumes that all the log files are correctly formatted.
|
|
|
|
|
|
## The format of the log files
|
|
|
-To do
|
|
|
+_To do_
|