DXSpider Registration Support System: Difference between revisions

From DXSpider Documentation Wiki
Jump to navigation Jump to search
EA3CV (talk | contribs)
No edit summary
EA3CV (talk | contribs)
No edit summary
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'''.
📌 '''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.


=== 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 ===
== 💬 How It Works ==
- 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 ==
1. '''User''' sends a message:
=== From the DXSpider shell:
  <pre>
Send a registration request:
   msg_sysop EA0ABC-2 REGISTER name@domain.net Registration request
   msg_sysop EA0ABC-2 REGISTER name@domain.net Registration request
  </pre>


Authorize a registration:
2. '''Sysop receives:'''
  * 📧 Email with request details
  * 📱 Telegram notification (optional)
 
3. '''Sysop approves:'''
  <pre>
   auth_register EA0ABC-2
   auth_register EA0ABC-2
  </pre>


Deny a registration:
4. '''User receives confirmation email''', e.g.:
   deny_register EA0ABC-2
   <pre>
  Subject: Registration accepted EA0ABC-2 at EA3CV-3
  User: EA0ABC-2
  Password: 5B54gqGz
  </pre>


== 📦 Requirements ==
5. '''Or sysop denies:'''
=== DXVars.pm Located at: `/spider/local/DXVars.pm`
  <pre>
  deny_reg EA0ABC-2
  </pre>


You must include at the bottom (before `1;`) the following configuration:
6. '''User receives denial notice''', e.g.:
  <pre>
  Subject: Access request denied for EA0ABC-2 on EA3CV-3
  </pre>


```perl
== 📂 Scripts Included ==


# Telegram config
All scripts go in <code>/spider/local_cmd/</code>


$id = "123456789";                      # Your Telegram chat ID $token = "123456789:ABCdEfGhIjKlmNo";    # Telegram bot token
* [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]


# Email SMTP config
Also required:


$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'; ```
* [https://github.com/EA3CV/dxspider_info/blob/main/Local.pm Local.pm] → to <code>/spider/local/Local.pm</code>


=== Local.pm File: `/spider/local/Local.pm`
== 🧩 Configuration: DXVars.pm ==


📥 Download: https://github.com/EA3CV/dxspider_info/blob/main/Local.pm
Append to <code>/spider/local/DXVars.pm</code>:


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


1. Download the scripts:
# 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>


```text /spider/local_cmd/msg_sysop.pl /spider/local_cmd/auth_register.pl /spider/local_cmd/deny_register.pl ```
== 📑 Files Used ==


📥 Download them from:
* <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


- 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
== 🔧 Installation ==


2. Make sure `/spider/local/Local.pm` is updated.
1. Copy the scripts to <code>/spider/local_cmd/</code>
2. Edit <code>/spider/local/DXVars.pm</code> with your email and Telegram settings
3. Install required Perl modules (see below)
4. Restart the DXSpider node


3. Restart DXSpider: ```bash ./cluster.pl restart ```
== 📦 Required Perl Modules ==


== 🧩 Required Perl Modules
Install with CPAN (from Linux shell):


Install the following modules using `cpan`:
<syntaxhighlight lang="bash">
cpan Net::SMTP
cpan Net::SMTP::SSL
cpan Net::MQTT::Simple
cpan JSON
</syntaxhighlight>


```bash cpan JSON cpan Net::MQTT::Simple cpan Net::SMTP cpan Net::SMTP::SSL ```
== ✏️ Template Customization ==


== 📂 Files Used
Each script includes variables where you can '''modify the bilingual message content'''. Look for blocks like:


- `/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)
<syntaxhighlight lang="perl">
my $msg_text_ok = <<"EMAIL";
...
EMAIL
</syntaxhighlight>


== ✉️ Emails Sent to Users
You can change these to fit your tone and language.


=== Message confirmation: _Subject_: Message received for EA3CV-3 sysop
== 📧 Example Messages ==


``` En breve recibira una respuesta. Saludos.
=== Request Received ===
<pre>
Subject: Message received for EA3CV-3 sysop


You will receive a response shortly. Regards,
En breve recibira una respuesta.
Saludos.


Kin EA3CV ```
You will receive a response shortly.
Regards,


=== 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
=== Confirmation Message ===
<pre>
Subject: Registration accepted EA0ABC-2 at EA3CV-3


Usuario: EA0ABC-2 Password: 5B54gqGz
Se ha aceptado su solicitud de registro


Use el comando `set/password` para cambiar la contraseña si lo desea. Disfrute.
Usuario: EA0ABC-2
Password: 5B54gqGz
 
Use el comando `set/password` para cambiar la contraseña si lo desea.
Disfrute.


Your registration request has been approved.
Your registration request has been approved.


User: EA0ABC-2 Password: 5B54gqGz
User: EA0ABC-2
Password: 5B54gqGz


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


Kin EA3CV ```
Kin EA3CV
</pre>


=== Rejection after deny_register: _Subject_: Solicitud de acceso denegada / Access request denied for EA0ABC-2 on EA3CV-3
=== Denial Message ===
<pre>
Subject: Access request denied for EA0ABC-2 on EA3CV-3


``` Lamentamos informarle que su solicitud de acceso para EA0ABC-2 ha sido denegada en EA3CV-3.
Lamentamos informarle que su solicitud de acceso para EA0ABC-2 ha sido denegada en EA3CV-3.


No cumple con los criterios requeridos. Puede intentarlo más adelante si lo desea.
No cumple con los criterios requeridos.
Puede intentarlo más adelante si lo desea.


We regret to inform you that your access request for EA0ABC-2 has been denied on EA3CV-3.
We regret to inform you that your access request for EA0ABC-2 has been denied on EA3CV-3.


It does not meet the required criteria. You may try again later if you wish.
It does not meet the required criteria.
 
You may try again later if you wish.
Kin EA3CV ```
 
== 📲 Telegram Messages (to sysop)
 
From msg_sysop:
 
``` 📡 Message from DXSpider command: Call: EA0ABC-2 Subject: REGISTER Email: name@domain.net Sent by: EA3CV IP: 1.2.3.4


Registration request ```
Kin EA3CV
</pre>


From auth_register:
=== Telegram Notifications ===


``` ✅ Registered EA0ABC-2 in EA3CV-3 ```
* Incoming request:
 
  <pre>
From deny_register:
  📡 Message from DXSpider command:
 
  Call: EA0ABC-2
``` ❌ Registration denied for EA0ABC-2 on EA3CV-3 ```
  Subject: REGISTER
 
== 📑 Command Outputs (user view)
 
From `msg_sysop`:
 
``` Message sent to sysop.
  Call: EA0ABC-2
Subject: REGISTER
   Email: name@domain.net
   Email: name@domain.net
Message: Registration request ```
  Sent by: EA3CV
 
  IP: 1.2.3.4
From `auth_register`:
  </pre>
 
``` ✔️ Registration completed for EA0ABC-2
  Email: name@domain.net
  IP:   1.2.3.4
  Pass:  5B54gqGz
```
 
From `deny_register`:


``` ✔️ Registration denied for EA0ABC-2
* Approval:
  Email: name@domain.net
  <pre>
  IP:    1.2.3.4
  ✅ Registered EA0ABC-2 in EA3CV-3
```
  </pre>


== ✏️ Customizing Texts
* Denial:
  <pre>
  ❌ Registration denied for EA0ABC-2 on EA3CV-3
  </pre>


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.
== ✅ Commands Summary ==


== 👤 Author
{| 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
|}


📧 Kin EA3CV — [ea3cv@cronux.net](mailto:ea3cv@cronux.netApril 2025
== 👤 Author ==
'''Kin EA3CV''' — [mailto:ea3cv@cronux.net ea3cv@cronux.net] April 2025

Revision as of 17:04, 11 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.

📌 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.

⚙️ 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)

💬 How It Works

1. User sends a message:

   msg_sysop EA0ABC-2 REGISTER name@domain.net Registration request
   

2. Sysop receives:

  * 📧 Email with request details
  * 📱 Telegram notification (optional)

3. Sysop approves:

   auth_register EA0ABC-2
   

4. User receives confirmation email, e.g.:

   Subject: Registration accepted EA0ABC-2 at EA3CV-3
   User: EA0ABC-2
   Password: 5B54gqGz
   

5. Or sysop denies:

   deny_reg EA0ABC-2
   

6. User receives denial notice, e.g.:

   Subject: Access request denied for EA0ABC-2 on EA3CV-3
   

📂 Scripts Included

All scripts go in /spider/local_cmd/

Also required:

🧩 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

🔧 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 JSON

✏️ Template Customization

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

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

You can change these to fit your tone and language.

📧 Example Messages

Request Received

Subject: Message received for EA3CV-3 sysop

En breve recibira una respuesta.
Saludos.

You will receive a response shortly.
Regards,

Kin EA3CV

Confirmation Message

Subject: Registration accepted EA0ABC-2 at EA3CV-3

Se ha aceptado su solicitud de registro

Usuario: EA0ABC-2
Password: 5B54gqGz

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

Your registration request has been approved.

User: EA0ABC-2
Password: 5B54gqGz

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

Kin EA3CV

Denial Message

Subject: Access request denied for EA0ABC-2 on EA3CV-3

Lamentamos informarle que su solicitud de acceso para EA0ABC-2 ha sido denegada en EA3CV-3.

No cumple con los criterios requeridos.
Puede intentarlo más adelante si lo desea.

We regret to inform you that your access request for EA0ABC-2 has been denied on EA3CV-3.

It does not meet the required criteria.
You may try again later if you wish.

Kin EA3CV

Telegram Notifications

  • Incoming request:
  📡 Message from DXSpider command:
  Call: EA0ABC-2
  Subject: REGISTER
  Email: name@domain.net
  Sent by: EA3CV
  IP: 1.2.3.4
  
  • Approval:
  ✅ Registered EA0ABC-2 in EA3CV-3
  
  • Denial:
  ❌ Registration denied for EA0ABC-2 on EA3CV-3
  

✅ 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 EA3CVea3cv@cronux.net April 2025