summaryrefslogtreecommitdiff
path: root/kpov_judge/tasks/radius_mysql_pam
diff options
context:
space:
mode:
authords8283@student.uni-lj.si <ds8283@student.uni-lj.si@5cf9fbd1-b2bc-434c-b4b7-e852f4f63414>2015-01-05 20:02:10 +0000
committerds8283@student.uni-lj.si <ds8283@student.uni-lj.si@5cf9fbd1-b2bc-434c-b4b7-e852f4f63414>2015-01-05 20:02:10 +0000
commitaa3f0208a725fe6bebe1061eec623db4a4e2d76b (patch)
treecd7376120aa2174188bf5dd486847561ea7af40b /kpov_judge/tasks/radius_mysql_pam
parente3f0930577e6f024215cfe305c9e60788ca700f0 (diff)
Popravljene gramaticne napake v angleskem howto-ju.Prevedene instrukcije v test.py.
git-svn-id: https://svn.lusy.fri.uni-lj.si/kpov-public-svn/kpov-public@149 5cf9fbd1-b2bc-434c-b4b7-e852f4f63414
Diffstat (limited to 'kpov_judge/tasks/radius_mysql_pam')
-rw-r--r--kpov_judge/tasks/radius_mysql_pam/howtos/en/index.html30
-rw-r--r--kpov_judge/tasks/radius_mysql_pam/task.py3
2 files changed, 18 insertions, 15 deletions
diff --git a/kpov_judge/tasks/radius_mysql_pam/howtos/en/index.html b/kpov_judge/tasks/radius_mysql_pam/howtos/en/index.html
index b774ceb..e4b913b 100644
--- a/kpov_judge/tasks/radius_mysql_pam/howtos/en/index.html
+++ b/kpov_judge/tasks/radius_mysql_pam/howtos/en/index.html
@@ -6,28 +6,28 @@
<body><font face="Georgia, Times New Roman, Times, serif">
<strong><h1>Radius mysql:</h1></strong>
-<p><strong><h2>Tasks quick how to:</h2></strong><br>
- Set OpenRadius server and add users. Use MySql for database.</p>
+<p><strong><h2>Quick how to:</h2></strong><br>
+ Setup the OpenRadius server and add users. Use MySql as the database.</p>
<strong><h2>Instructions:</h2></strong>
<ol>
- <li>Create two virtual machines - SimpleArbiter (use disc simpleArbiterDhcp) and RadiusServer. Discs for virtual machines are located on polz.si/media/uploads/kpov/virtualke.</li>
- <li>Use disks VPNCLient.vdi and SimpleArbiterVPN.vdi to create VMs.</li>
- <li>On both VMs set two network adapters - NAT and Internal.</li>
- <li>Login with username <strong>student</strong> and password <strong>student</strong> on both VMs.</li>
+ <li>Create two virtual machines - SimpleArbiter (use the simpleArbiterDhcp.vdi disk) and RadiusServer. Discs for virtual machines are located on polz.si/media/uploads/kpov/virtualke.</li>
+ <li>Create another two virtual machines using the disks VPNCLient.vdi and SimpleArbiterVPN.vdi.</li>
+ <li>Setup both VMs so that they use two network adapters - NAT and Internal network.</li>
+ <li>Login with the username <strong>student</strong> and password <strong>student</strong> on both VMs.</li>
</ol>
-<h3><u><strong><em>First: Set OpenRadius.</em></strong></u></h3>
+<h3><u><strong><em>Part one: Setup OpenRadius.</em></strong></u></h3>
<ol>
- <li>Install OpenRadius on virtual machine RadiusServer (configuration: /etc/openradius/configuration and /etc/openradius/behaviour)</li>
- <li>Add user and assign him shared secret. Shared secret should be written in /etc/openradius/configuration file. (More info: <a href = "http://sites.e-advies.nl/openradius/doc-using-openradius.html"> http://sites.e-advies.nl/openradius/doc-using-openradius.html </a>)</li>
- <li>Use shared secret to connect form SimpleArbiter to RadiusServer.</strong></li>
+ <li>Install OpenRadius on the RadiusServer VM (configuration files are: /etc/openradius/configuration and /etc/openradius/behaviour)</li>
+ <li>Add a user and assign him a shared secret. This should be configured in the /etc/openradius/configuration file. (More info: <a href = "http://sites.e-advies.nl/openradius/doc-using-openradius.html"> http://sites.e-advies.nl/openradius/doc-using-openradius.html </a>)</li>
+ <li>Create a connection from SimpleArbiter to RadiusServer using the secret you configured.</strong></li>
</ol>
-<u><strong><em><h3>Second: Install and set MySQL database on RadiusServer</h3></em></strong></u>
+<u><strong><em><h3>Part two: Install and setup a MySQL database on RadiusServer</h3></em></strong></u>
<ol>
- <li>Use OpenRadius modul RadSQL to store users in database.</li>
- <li>Set MySQL server: sudo apt-get install mysql-server.</li>
- <li>Connect to MySQL server: mysql -u root -p.</li>
- <li>Create database: CREATE DATABASE <database-name>. Create table users with columns username and password.</li>
+ <li>OpenRadius can use the module RadSQL to store users in database.</li>
+ <li>Setup a MySQL server: sudo apt-get install mysql-server.</li>
+ <li>Connect to the MySQL server: mysql -u root -p.</li>
+ <li>Create a database: CREATE DATABASE <database-name>. Create a table <strong>users</strong> with columns <strong>username</strong> and <strong>password</strong>.</li>
</ol>
</body>
diff --git a/kpov_judge/tasks/radius_mysql_pam/task.py b/kpov_judge/tasks/radius_mysql_pam/task.py
index 3c4abce..0319dbd 100644
--- a/kpov_judge/tasks/radius_mysql_pam/task.py
+++ b/kpov_judge/tasks/radius_mysql_pam/task.py
@@ -18,6 +18,9 @@ Ustvari podatkovno bazo.Najprej namestimo mysql server. Nato se prijavimo v Mysq
Na RadiusServer ustvari uporabnika test. Nastavi PAM tako, da se bo geslo uporabnika primerjalo z vnosom
v tabeli v mysql, namesto da se uporabi datoteka /etc/passwd oziroma /etc/shadow.
"""
+ 'en':u"""Create two virtual computers - SimpleArbiter (using the SimpleArbiterDhcp.vdi disk) and RadiusServer. You can get the disk image at polz.si/media/uploads/kpov/virtualke. Install OpenRadius on the RadiusServer VM. Installation instructions can be found at evbergen.home.xs4all.nl/openradius/doc-using-openradius.html. OpenRadius uses two configuration files /etc/openradius/configuration and /etc/openradius/behaviour. The first one defines sources and interfaces of the server, the second one defines how the server responds to requests. Add your username and password from the SimpleArbiter VM to the OpenRadius configuration. Make shure that SimpleArbiter is able to connect to RadiusServer using the shared secret.
+Install the MySQL database on the RadiusServer VM. Log into the MySQL server using mysql -u root -p . Create the database using CREATE DATABASE <dbnamehere>. Add the columns username and password. Create the user test on RadiusServer and setup PAM so that the user password is checked against the MySQL database instead of the file /etc/passwd or /etc/shadow.
+"""
}
computers = {