-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathREADME
93 lines (84 loc) · 2.12 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
Project: ISA - SMTP client
==========================
Authors: Albert Uchytil (xuchyt03)
Description
-----------
School project for Network Applications and Network Administration.
Simple SMTP client. The connection to the server is not encrypted.
Implementation details
----------------------
SMTP client application written using C++. This implementation uses OOP approach.
Application consist of six classes.
`Envelope` and `Message` are used as data models.
`ArgParser` focuses on argument parsing and validation. It fills the data models.
After filling the models with valid data, the `Client` class instance is created.
All communication with the SMTP server happens within the `Client`.
Usage
-----
```sh
$ ./smtpclient [ -a IP ] [ -p port] [ -i file ] [ -w seconds ]
```
Options
-------
* `-a IP`
* Address of the SMTP server
* Optional
* Default value is `127.0.0.1`
* `-p port`
* Port on which the SMTP server is running
* Optional
* Default value is `25`
* `-i file`
* Path to client's configuration file, that contains E-Mails
* Required
* `-w seconds`
* Number of seconds to delay the closing of the connection with the server
* Must be number from `0` to `3600`
* Optional
* Default value is `0`
Examples
--------
```sh
$ ./smtpclient -i test/file01.txt
```
```sh
$ ./smtpclient -a 192.168.2.145 -p 1337 -i test/file02.txt
```
```sh
$ ./smtpclient -i test/file03.txt -w 60
```
Notes
-----
* Uses `isa.local` as hard-coded hostname, because it is the hostname of the testing server
* Uses `xuchyt03@isa.local` as a sender
* `client.hpp` contains `DEBUG` macro which enables logging if set to `1`
Make options
------------
* `make`
* Builds the project
* `make clean`
* Removes compiled files
* `make pack`
* Creates archive containing source files
* `make run`
* Runs project
Files required for submission
-----------------------------
* src/args.cpp
* src/args.hpp
* src/client.cpp
* src/client.hpp
* src/env.cpp
* src/env.hpp
* src/main.cpp
* src/msg.cpp
* src/msg.hpp
* src/signal.cpp
* src/signal.hpp
* src/status.cpp
* src/status.hpp
* test/file01.txt
* test/file02.txt
* test/file03.txt
* Makefile
* README