DXSpider Registration Support System: Difference between revisions

From DXSpider Documentation Wiki
Jump to navigation Jump to search
EA3CV (talk | contribs)
No edit summary
EA2CW (talk | contribs)
Β 
(8 intermediate revisions by 2 users not shown)
Line 1: Line 1:
= DXSpider Registration Support System =


= DXSpider Registration & Password Assistant System =
πŸ“‘ '''DXSpider Registration Support System''' provides a user-friendly way for sysops to manage registration requests via '''email''' and/or '''Telegram''', with clear messages and configurable templates in '''Spanish and English''' (default).
πŸ“Œ '''Purpose''' This system provides a user-friendly assistant for managing user registrations and passwords in DXSpider. It includes:


- πŸ“¬ Sending bilingual emails (Spanish/English) to users. - πŸ“² Optional Telegram notifications to the sysop. - βš™οΈ Three modular commands that can work independently or as a complete workflow:
== πŸ“Œ Purpose ==
Β  - `msg_sysop`
Β  - `auth_register`
Β  - `deny_register`
All user-facing text (email bodies, etc.) is editable for customization.


== 🧰 Included Commands ==
This system adds simple tools to support '''registration and password management''' on a DXSpider node. It allows users to send a request, and sysops to authorize or deny it with minimal effort, while keeping a record of all registration requests and their acceptance or denial.
It is not allowed to send more than 10 messages per day per IP.


=== msg_sysop.pl ===
== βš™οΈ Features ==
- Sends a message from a user to the sysop via email and/or Telegram. - Optionally adds the user to a pending registration list if subject includes `REGISTER`.


=== auth_register.pl ===
* Users send requests via a simple command: <code>msg_sysop</code>
- Authorizes a user in `pending_reg.txt`. - Registers the user in DXSpider. - Sends a bilingual welcome email with username/password. - Sends a Telegram notification to the sysop.
* Sysops receive Telegram alerts and emails
* Sysops can approve (<code>auth_register</code>) or reject (<code>deny_reg</code>) registrations
* Sends multilingual confirmation/denial messages to users
* Configurable templates for email content (Spanish/English)


=== deny_register.pl ===
== πŸ“₯ Commands Usage ==
- Denies a user registration from `pending_reg.txt`. - Sends a bilingual rejection email to the user. - Sends a Telegram notification to the sysop.


== πŸ“„ How to Use ==
The system uses three main commands for managing user registrations:
=== From the DXSpider shell:
Send a registration request:
Β  msg_sysop EA0ABC-2 REGISTER name@domain.net Registration request


Authorize a registration:
=== msg_sysop ===
Β  auth_register EA0ABC-2
Used by the user to send a registration request.


Deny a registration:
<pre>
Β  deny_register EA0ABC-2
msg_sysop <user_call> REGISTER <user_email> <comments>
</pre>


== πŸ“¦ Requirements ==
Example:
=== DXVars.pm Located at: `/spider/local/DXVars.pm`
<pre>
msg_sysop EA1ZZZ REGISTER ea1zzz@example.net I would like to join the cluster
</pre>


You must include at the bottom (before `1;`) the following configuration:
=== auth_register ===
Used by the sysop to approve and register the user.


```perl
<pre>
auth_reg <user_call>
</pre>


# Telegram config
Example:
<pre>
auth_reg EA1ZZZ
</pre>


$id = "123456789";Β  Β  Β  Β  Β  Β  Β  Β  Β  Β  Β  # Your Telegram chat ID $token = "123456789:ABCdEfGhIjKlmNo";Β  Β  # Telegram bot token
=== deny_register ===
Used by the sysop to reject a registration request.


# Email SMTP config
<pre>
deny_reg <user_call>
</pre>


$email_enable = 1; $email_from = 'sysop@example.net'; $email_smtp = 'smtp.provider.net'; $email_port = 587;Β  Β  Β  Β  Β  Β  Β  Β  Β  Β  Β  # 587 for STARTTLS or 465 for SSL $email_user = 'smtpuser@example.net'; $email_pass = 'smtppassword'; ```
Example:
<pre>
deny_reg EA1ZZZ
</pre>


=== Local.pm File: `/spider/local/Local.pm`
== πŸ“’ How It Works: Full Example ==


πŸ“₯ Download: https://github.com/EA3CV/dxspider_info/blob/main/Local.pm
=== REGISTRATION REQUEST (msg_sysop) ===


== πŸ”§ Installation
'''User input from Telnet:'''
<pre>
msg_sysop XX0ABC REGISTER xx0abc@domain.com Requesting access
</pre>


1. Download the scripts:
{| class="wikitable" style="width:100%"
|-
! style="width:50%; vertical-align:top;" | Response to user
! style="width:50%; vertical-align:top;" | To sysop via email
|-
|
<pre>
Message sent to sysop.
Β  Call: XX0ABC
Subject: REGISTER
Β  Email: xx0abc@domain.com
Message: Requesting access
</pre>
|
<pre>
Subject: Msg received from XX0ABC (REGISTER) to EA3CV-2


```text /spider/local_cmd/msg_sysop.pl /spider/local_cmd/auth_register.pl /spider/local_cmd/deny_register.pl ```
New message via msg_sysop command:


πŸ“₯ Download them from:
Node: EA3CV-2
Call: XX0ABC
Subject: REGISTER
Email: xx0abc@domain.com
IP: 1.2.3.4
Message: Requesting access
</pre>
|-
! style="vertical-align:top;" | To user via email
! style="vertical-align:top;" | To sysop via Telegram
|-
|
<pre>
Asunto: Msg del sysop de / Msg from sysop of EA3CV-2


- https://github.com/EA3CV/dxspider_info/blob/main/msg_sysop.pl - https://github.com/EA3CV/dxspider_info/blob/main/auth_register.pl - https://github.com/EA3CV/dxspider_info/blob/main/deny_register.pl
En breve recibira una respuesta.
Saludos.


2. Make sure `/spider/local/Local.pm` is updated.
You will receive a response shortly.
Regards,


3. Restart DXSpider: ```bash ./cluster.pl restart ```
Kin EA3CV
</pre>
|
<pre>
πŸ“‘ Message from DXSpider command:
Date: 13 April 2025 16:35:02
Call: XX0ABC
Subject: REGISTER
Email: xx0abc@domain.com
Sent by: EA3CV
IP: 1.2.3.4
Requesting access
</pre>
|}


== 🧩 Required Perl Modules
'''Entry in pending_reg.txt:'''
<pre>
20250413-163500,00000000-000000,PENDING ,XX0ABC,u$2wGVX=,1.2.3.4,xx0abc@domain.com
</pre>


Install the following modules using `cpan`:
=== REGISTRATION APPROVAL (auth_register) ===


```bash cpan JSON cpan Net::MQTT::Simple cpan Net::SMTP cpan Net::SMTP::SSL ```
'''Sysop input from Console:'''
<pre>
auth_reg XX0ABC
</pre>


== πŸ“‚ Files Used
{| class="wikitable" style="width:100%"
|-
! style="width:50%; vertical-align:top;" | Sysop output
! style="width:50%; vertical-align:top;" | To user via email
|-
|
<pre>
Registration completed for XX0ABC
Email: joaquin@cronux.net
IP:Β  Β  127.0.0.1
Pass:Β  u$2wGVX=
</pre>
|
<pre>
Asunto: Aceptada su solicitud de registro / Registration accepted XX0ABC at EA3CV-2


- `/spider/local_cmd/msg_sysop.pl` - `/spider/local_cmd/auth_register.pl` - `/spider/local_cmd/deny_register.pl` - `/spider/local/Local.pm` - `/spider/local_data/pending_reg.txt` (created automatically)
Se ha aceptado su solicitud de registro


== βœ‰οΈ Emails Sent to Users
Usuario: XX0ABC
Password: u$2wGVX=


=== Message confirmation: _Subject_: Message received for EA3CV-3 sysop
Use el comando `set/password` para cambiar la contraseΓ±a si lo desea.
Disfrute.


``` En breve recibira una respuesta. Saludos.
Your registration request has been approved.


You will receive a response shortly. Regards,
User: XX0ABC
Password: u$2wGVX=


Kin EA3CV ```
You can use the `set/password` command to change your password if you wish.
Enjoy.


=== Welcome after auth_register: _Subject_: Aceptada su solicitud de registro / Registration accepted EA0ABC-2 at EA3CV-3
Kin EA3CV
</pre>
|}


``` Se ha aceptado su solicitud de registro
'''Entry in pending_reg.txt:'''
<pre>
20250413-163500,20250413-164558,ACCEPTED,XX0ABC,u$2wGVX=,1.2.3.4,xx0abc@domain.com
</pre>


Usuario: EA0ABC-2 Password: 5B54gqGz
=== REGISTRATION DENIAL (deny_register) ===


Use el comando `set/password` para cambiar la contraseΓ±a si lo desea. Disfrute.
'''Sysop input from Console:'''
<pre>
deny_reg XX0ABC
</pre>


Your registration request has been approved.
{| class="wikitable" style="width:100%"
|-
! style="width:50%; vertical-align:top;" | Sysop output
! style="width:50%; vertical-align:top;" | To user via email
|-
|
<pre>
Registration denied for XX0ABC
Email: joaquin@cronux.net
IP:Β  Β  127.0.0.1
</pre>
|
<pre>
Asunto: Denegada su solicitud de registro / Registration denied XX0ABC at EA3CV-2


User: EA0ABC-2 Password: 5B54gqGz
Se ha denegado su solicitud de registro.


You can use the `set/password` command to change your password if you wish. Enjoy.
Si cree que esto es un error, puede contactar con el administrador.
Gracias.


Kin EA3CV ```
Your registration request has been denied.


=== Rejection after deny_register: _Subject_: Solicitud de acceso denegada / Access request denied for EA0ABC-2 on EA3CV-3
If you believe this is a mistake, please contact the administrator.
Thank you.


``` Lamentamos informarle que su solicitud de acceso para EA0ABC-2 ha sido denegada en EA3CV-3.
Kin EA3CV
</pre>
|-
! colspan="2" style="vertical-align:top;" | To sysop via Telegram
|-
|
<pre>
❌ DENIED registration of XX0ABC from 127.0.0.1
</pre>
|}


No cumple con los criterios requeridos. Puede intentarlo mΓ‘s adelante si lo desea.
'''Entry in pending_reg.txt:'''
<pre>
20250413-163500,20250413-165008,DENIEDΒ  ,XX0ABC,u$2wGVX=,1.2.3.4,xx0abc@domain.com
</pre>


We regret to inform you that your access request for EA0ABC-2 has been denied on EA3CV-3.
== πŸ“‚ Scripts Included ==


It does not meet the required criteria. You may try again later if you wish.
All scripts go in <code>/spider/local_cmd/</code>


Kin EA3CV ```
* [https://github.com/EA3CV/dxspider_info/blob/main/msg_sysop.pl msg_sysop.pl]
* [https://github.com/EA3CV/dxspider_info/blob/main/auth_register.pl auth_register.pl]
* [https://github.com/EA3CV/dxspider_info/blob/main/deny_register.pl deny_register.pl]


== πŸ“² Telegram Messages (to sysop)
Also required:


From msg_sysop:
* [https://github.com/EA3CV/dxspider_info/blob/main/Local.pm Local.pm] β†’ to <code>/spider/local/Local.pm</code>


``` πŸ“‘ Message from DXSpider command: Call: EA0ABC-2 Subject: REGISTER Email: name@domain.net Sent by: EA3CV IP: 1.2.3.4
== 🧩 Configuration: DXVars.pm ==


Registration request ```
Append to <code>/spider/local/DXVars.pm</code>:


From auth_register:
<syntaxhighlight lang="perl">
# Telegram config
$id = "123456789";
$token = "123456789:ABCDEF-TOKEN";


``` βœ… Registered EA0ABC-2 in EA3CV-3 ```
# Email SMTP config
$email_enable = 1;
$email_from = 'you@example.com';
$email_smtp = 'smtp.example.com';
$email_port = 587;Β  Β  Β  # Port 587 for STARTTLS/Port 465 for SSL)
$email_user = 'your_user';
$email_pass = 'your_pass';
</syntaxhighlight>


From deny_register:
== πŸ“‘ Files Used ==


``` ❌ Registration denied for EA0ABC-2 on EA3CV-3 ```
* <code>/spider/local_data/pending_reg.txt</code> β€” Automatically created
* <code>/spider/local_cmd/*.pl</code> β€” Command scripts
* <code>/spider/local/Local.pm</code> β€” Email & Telegram logic
* <code>/spider/local/DXvars.pm</code> β€” Email and Telegram variables


== πŸ“‘ Command Outputs (user view)
== πŸ”§ Installation ==


From `msg_sysop`:
# Copy the scripts to <code>/spider/local_cmd/</code>
# Edit <code>/spider/local/DXVars.pm</code> with your email and Telegram settings
# Install required Perl modules (see below)
# Restart the DXSpider node


``` Message sent to sysop.
== πŸ“¦ Required Perl Modules ==
Β  Call: EA0ABC-2
Β 
Subject: REGISTER
Install with CPAN (from Linux shell):
Β  Email: name@domain.net
Message: Registration request ```


From `auth_register`:
<syntaxhighlight lang="bash">
cpan Net::SMTP
cpan Net::SMTP::SSL
cpan Net::MQTT::Simple
cpan List:Util
</syntaxhighlight>


``` βœ”οΈ Registration completed for EA0ABC-2
== ✏️ Template Customization ==
Β  Email: name@domain.net
Β  IP:Β  Β  1.2.3.4
Β  Pass:Β  5B54gqGz
```


From `deny_register`:
Each script includes variables where you can '''modify the bilingual message content'''. Look for blocks like:


``` βœ”οΈ Registration denied for EA0ABC-2
<syntaxhighlight lang="perl">
Β  Email: name@domain.net
my $msg_text_ok = <<"EMAIL";
Β  IP:Β  Β  1.2.3.4
...
```
EMAIL
</syntaxhighlight>


== ✏️ Customizing Texts
== βœ… Commands Summary ==


Each script includes a section at the beginning where you can edit the bilingual email content. Modify these strings to suit your cluster style or tone.
{| class="wikitable"
! Command !! Description
|-
| <code>msg_sysop</code> || User sends registration request
|-
| <code>auth_register</code> || Sysop approves and registers the user
|-
| <code>deny_reg</code> || Sysop denies the request
|}


== πŸ‘€ Author
== πŸ‘€ Author ==


πŸ“§ Kin EA3CV β€” [ea3cv@cronux.net](mailto:ea3cv@cronux.net)Β  April 2025
'''Kin EA3CV''' β€” [mailto:ea3cv@cronux.net ea3cv@cronux.net] April 2025

Latest revision as of 10:08, 14 April 2025

DXSpider Registration Support System

πŸ“‘ DXSpider Registration Support System provides a user-friendly way for sysops to manage registration requests via email and/or Telegram, with clear messages and configurable templates in Spanish and English (default).

πŸ“Œ Purpose

This system adds simple tools to support registration and password management on a DXSpider node. It allows users to send a request, and sysops to authorize or deny it with minimal effort, while keeping a record of all registration requests and their acceptance or denial. It is not allowed to send more than 10 messages per day per IP.

βš™οΈ Features

  • Users send requests via a simple command: msg_sysop
  • Sysops receive Telegram alerts and emails
  • Sysops can approve (auth_register) or reject (deny_reg) registrations
  • Sends multilingual confirmation/denial messages to users
  • Configurable templates for email content (Spanish/English)

πŸ“₯ Commands Usage

The system uses three main commands for managing user registrations:

msg_sysop

Used by the user to send a registration request.

msg_sysop <user_call> REGISTER <user_email> <comments>

Example:

msg_sysop EA1ZZZ REGISTER ea1zzz@example.net I would like to join the cluster

auth_register

Used by the sysop to approve and register the user.

auth_reg <user_call>

Example:

auth_reg EA1ZZZ

deny_register

Used by the sysop to reject a registration request.

deny_reg <user_call>

Example:

deny_reg EA1ZZZ

πŸ“’ How It Works: Full Example

REGISTRATION REQUEST (msg_sysop)

User input from Telnet:

msg_sysop XX0ABC REGISTER xx0abc@domain.com Requesting access
Response to user To sysop via email
Message sent to sysop.
   Call: XX0ABC
Subject: REGISTER
  Email: xx0abc@domain.com
Message: Requesting access
Subject: Msg received from XX0ABC (REGISTER) to EA3CV-2

New message via msg_sysop command:

Node: EA3CV-2
Call: XX0ABC
Subject: REGISTER
Email: xx0abc@domain.com
IP: 1.2.3.4
Message: Requesting access
To user via email To sysop via Telegram
Asunto: Msg del sysop de / Msg from sysop of EA3CV-2

En breve recibira una respuesta.
Saludos.

You will receive a response shortly.
Regards,

Kin EA3CV
πŸ“‘ Message from DXSpider command:
Date: 13 April 2025 16:35:02
Call: XX0ABC
Subject: REGISTER
Email: xx0abc@domain.com
Sent by: EA3CV
IP: 1.2.3.4
Requesting access

Entry in pending_reg.txt:

20250413-163500,00000000-000000,PENDING ,XX0ABC,u$2wGVX=,1.2.3.4,xx0abc@domain.com

REGISTRATION APPROVAL (auth_register)

Sysop input from Console:

auth_reg XX0ABC
Sysop output To user via email
Registration completed for XX0ABC
Email: joaquin@cronux.net
IP:    127.0.0.1
Pass:  u$2wGVX=
Asunto: Aceptada su solicitud de registro / Registration accepted XX0ABC at EA3CV-2

Se ha aceptado su solicitud de registro

Usuario: XX0ABC
Password: u$2wGVX=

Use el comando `set/password` para cambiar la contraseΓ±a si lo desea.
Disfrute.

Your registration request has been approved.

User: XX0ABC
Password: u$2wGVX=

You can use the `set/password` command to change your password if you wish.
Enjoy.

Kin EA3CV

Entry in pending_reg.txt:

20250413-163500,20250413-164558,ACCEPTED,XX0ABC,u$2wGVX=,1.2.3.4,xx0abc@domain.com

REGISTRATION DENIAL (deny_register)

Sysop input from Console:

deny_reg XX0ABC
Sysop output To user via email
Registration denied for XX0ABC
Email: joaquin@cronux.net
IP:    127.0.0.1
Asunto: Denegada su solicitud de registro / Registration denied XX0ABC at EA3CV-2

Se ha denegado su solicitud de registro.

Si cree que esto es un error, puede contactar con el administrador.
Gracias.

Your registration request has been denied.

If you believe this is a mistake, please contact the administrator.
Thank you.

Kin EA3CV
To sysop via Telegram
❌ DENIED registration of XX0ABC from 127.0.0.1

Entry in pending_reg.txt:

20250413-163500,20250413-165008,DENIED  ,XX0ABC,u$2wGVX=,1.2.3.4,xx0abc@domain.com

πŸ“‚ Scripts Included

All scripts go in /spider/local_cmd/

Also required:

  • Local.pm β†’ to /spider/local/Local.pm

🧩 Configuration: DXVars.pm

Append to /spider/local/DXVars.pm:

# Telegram config
$id = "123456789";
$token = "123456789:ABCDEF-TOKEN";

# Email SMTP config
$email_enable = 1;
$email_from = 'you@example.com';
$email_smtp = 'smtp.example.com';
$email_port = 587;      # Port 587 for STARTTLS/Port 465 for SSL)
$email_user = 'your_user';
$email_pass = 'your_pass';

πŸ“‘ Files Used

  • /spider/local_data/pending_reg.txt β€” Automatically created
  • /spider/local_cmd/*.pl β€” Command scripts
  • /spider/local/Local.pm β€” Email & Telegram logic
  • /spider/local/DXvars.pm β€” Email and Telegram variables

πŸ”§ Installation

  1. Copy the scripts to /spider/local_cmd/
  2. Edit /spider/local/DXVars.pm with your email and Telegram settings
  3. Install required Perl modules (see below)
  4. Restart the DXSpider node

πŸ“¦ Required Perl Modules

Install with CPAN (from Linux shell):

cpan Net::SMTP
cpan Net::SMTP::SSL
cpan Net::MQTT::Simple
cpan List:Util

✏️ Template Customization

Each script includes variables where you can modify the bilingual message content. Look for blocks like:

my $msg_text_ok = <<"EMAIL";
...
EMAIL

βœ… Commands Summary

Command Description
msg_sysop User sends registration request
auth_register Sysop approves and registers the user
deny_reg Sysop denies the request

πŸ‘€ Author

Kin EA3CV β€” ea3cv@cronux.net April 2025