Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update doc #1700

Open
wants to merge 10 commits into
base: develop
Choose a base branch
from
2 changes: 1 addition & 1 deletion doc/Changes1.10
Original file line number Diff line number Diff line change
Expand Up @@ -217,7 +217,7 @@ Eggdrop v1.10.0rc1 (2024-08-08):
* Additional internals doc tweaks
2024-01-18 * Switch autoscripts to GitHub
2024-01-15 * change py init from Isolated to Python
2024-01-14 * Add Python intpreter to Eggdrop
2024-01-14 * Add Python interpreter to Eggdrop
[Patch by: Geo, thommey]
* Update docs
* Update copyright
Expand Down
2 changes: 1 addition & 1 deletion doc/Changes1.8
Original file line number Diff line number Diff line change
Expand Up @@ -1184,7 +1184,7 @@ Eggdrop v1.8.1rc1 (2017-03-01):
- Made some corrections to the contributors list, removed a duplicate entry.
Patch by: pseudo

- Fixed bind cron html documention to be in sync with non-html one.
- Fixed bind cron html documentation to be in sync with non-html one.
Found by: 64MAAMVDH / Patch by: thommey

- Replaced most dns.mod preprocessor definitions with config variables.
Expand Down
4 changes: 2 additions & 2 deletions doc/sphinx_source/_themes/agogo/layout.html
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@
<div class="headertitle"><a
href="{{ pathto(master_doc) }}">{{ shorttitle|e }}</a></div>
{%- endblock %}
<div class="rel" role="navigation" aria-label="related navigation">
<div class="rel" role="navigation" aria-label="Related">
{%- for rellink in rellinks|reverse %}
<a href="{{ pathto(rellink[0]) }}" title="{{ rellink[1]|striptags|e }}"
{{ accesskey(rellink[2]) }}>{{ rellink[3] }}</a>
Expand Down Expand Up @@ -76,7 +76,7 @@ <h3 style="margin-top: 1.5em;">{{ _('Search') }}</h3>
<div class="footer-wrapper">
<div class="footer">
<div class="left">
<div role="navigation" aria-label="related navigaton">
<div role="navigation" aria-label="Related">
{%- for rellink in rellinks|reverse %}
<a href="{{ pathto(rellink[0]) }}" title="{{ rellink[1]|striptags|e }}"
{{ accesskey(rellink[2]) }}>{{ rellink[3] }}</a>
Expand Down
15 changes: 6 additions & 9 deletions doc/sphinx_source/about/about.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
About Eggdrop
Last revised: July 27, 2010

=============
About Eggdrop
=============
Expand Down Expand Up @@ -38,10 +35,10 @@ About Eggdrop
for information on setting up a botnet.

Eggdrop is always being improved and adjusted because there are bugs to
be fixed and features to be added (if the users demand them, and they
make actually sense). In fact, it existed for several years as v0.7 -
v0.9 before finally going 1.0. This version of Eggdrop is part of the
1.9 tree. A valiant effort has been made to chase down and destroy bugs.
be fixed and features to be added (if the users demand them, and they
make actually sense). In fact, it existed for several years as v0.7 - v0.9
before finally going 1.0. This version of Eggdrop is part of the
1.10 tree. A valiant effort has been made to chase down and destroy bugs.

To use Eggdrop, you need:

Expand All @@ -50,8 +47,8 @@ About Eggdrop
* A pretty good knowledge of IRC and Unix, including how to compile
programs, how to read, and what DCC chat is, at absolute minimum.

* About 5-7 MB of disk space. The Eggdrop tarball is about 5.4 MB
unpacked.
* About 8 MB of disk space for the installed Eggdrop. The Eggdrop
tarball is about 10 MB unpacked.

* Tcl -- Eggdrop cannot compile without Tcl installed on your shell.

Expand Down
22 changes: 15 additions & 7 deletions doc/sphinx_source/tutorials/firststeps.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ You can either telnet to the bot, or connect to the bot using DCC Chat. To telne

You can find the IP and port the bot is listening on by a) remembering what you set in the config file ;) or b) reading the display the bot presented when it started up. Look for a line that looks similar to this::

Listening for telnet connections on 2.4.6.9:3183 (all).
Listening for telnet connections on 192.0.2.1:3183 (all).

This tells you that the bot is listening on IP 2.4.6.9, port 3183. If you see 0.0.0.0 listed, that means Eggdrop is listening on all available IPs on that particular host.
This tells you that the bot is listening on IP 192.0.2.1, port 3183. If you see 0.0.0.0 listed, that means Eggdrop is listening on all available IPs on that particular host.


If you choose not to telnet to connect to the partyline, you can either ``/dcc chat BotNick`` or ``/ctcp BotNick chat``. If one of those methods does not work for you, try the other. Once you're on the bot for the first time, type ``.help`` for a short list of available commands, or ``.help all`` for a more thorough list.
Expand Down Expand Up @@ -150,26 +150,34 @@ Simple Authentication and Security Layer (SASL) is becoming a prevalant method o

* **PLAIN**: To use this method, set sasl-mechanism to 0. This method passes the username and password (set in the sasl-username and sasl-password config file settings) to the IRC server in plaintext. If you only connect to the IRC server using a connection protected by SSL/TLS this is a generally safe method of authentication; however you probably want to avoid this method if you connect to a server on a non-protected port as the exchange itself is not encrypted.

* **ECDSA-NIST256P-CHALLENGE**: To use this method, set sasl-mechanism to 1. This method uses a public/private keypair to authenticate, so no username/password is required. Not all servers support this method. If your server does support this, you you must generate a certificate pair using::
* **ECDSA-NIST256P-CHALLENGE**: To use this method, set sasl-mechanism to 1. This method uses a public/private keypair to authenticate, so no username/password is required. Not all servers support this method. If your server does support this, you must generate a certificate pair using::

openssl ecparam -genkey -name prime256v1 -out eggdrop-ecdsa.pem

You will need to determine your public key fingerprint by using::

openssl ec -noout -text -conv_form compressed -in eggdrop-ecdsa.pem | grep '^pub:' -A 3 | tail -n 3 | tr -d ' \n:' | xxd -r -p | base64
openssl ec -noout -text -conv_form compressed -in eggdrop-ecdsa.pem 2>/dev/null | grep '^pub:' -A 3 | tail -n 3 | tr -d ' \n:' | xxd -r -p | base64

Then, authenticate with your NickServ service and register your public certificate with NickServ. You can view your public key On Libera for example, it is done by::
If error "xxd: command not found" you could install vim, because xxd is a part of vim, or you could try python::

openssl ec -noout -text -conv_form compressed -in eggdrop-ecdsa.pem 2>/dev/null| grep '^pub:' -A 3 | tail -n 3 | tr -d ' \n:' | python -c "import base64,sys;print(base64.b64encode(bytearray.fromhex(sys.stdin.readline())).decode())"

Then, authenticate with your NickServ service and register your public certificate with NickServ. On Libera for example, it is done by::

/msg NickServ set pubkey <fingerprint string from above goes here>

* **EXTERNAL**: To use this method, set sasl-mechanism to 2. This method allows you to use other TLS certificates to connect to the IRC server, if the IRC server supports it. An EXTERNAL authentication method usually requires you to connect to the IRC server using SSL/TLS. There are many ways to generate certificates; one such way is generating your own certificate using::

openssl req -new -x509 -nodes -keyout eggdrop.key -out eggdrop.crt

You will need to determine your public key fingerprint by using::
You will need to determine your public key fingerprint by using::

openssl x509 -in eggdrop.crt -outform der | sha1sum -b | cut -d' ' -f1

Then, ensure you have those keys loaded in the ssl-privatekey and ssl-certificate settings in the config file. Finally, to add this certificate to your NickServ account, type::
Then, ensure you have those keys loaded in the ssl-privatekey and ssl-certificate settings in the config file. Finally, to add this certificate to your NickServ account, type::

/msg NickServ cert add <fingerprint string from above goes here>

Alternatively you could connect via ssl and if NickServ supports it, make it automatically determine and add your fingerprint in just the right format:

/msg NickServ cert add
4 changes: 2 additions & 2 deletions doc/sphinx_source/tutorials/setup.rst
Original file line number Diff line number Diff line change
Expand Up @@ -102,9 +102,9 @@ Below are some of the common settings used for Eggdrop:

:set username: if your shell runs identd (most do), then you should set this to your account login name.

:set vhost4: you'll need to set this if you want your bot to use a vhost. This setting lets you choose which IP to use if your shell has multiple. Use vhost4 for an IPv4 address (ie, 1.2.3.4) See also: vhost6
:set vhost4: you'll need to set this if you want your bot to use a vhost. This setting lets you choose which IP to use if your shell has multiple. Use vhost4 for an IPv4 address (ie, 192.0.2.1) See also: vhost6

:set vhost6: the same as vhost4, only for IPv6 addresses (ie, 5254:dead:b33f::1337:f270).
:set vhost6: the same as vhost4, only for IPv6 addresses (ie, 2001:db8:dead:b33f::1337:f270).

:logfile: keeping logs is a good idea. Generally, you should have one log for bot stuff, and one log for each of your channels. To capture bot stuff, add the line ``logfile mcobxs * "botnick.log"`` to the config. To capture channel stuff, add ``logfile jkp #donkeys "#donkeys.log"``, ``logfile jkp #horses "#horses.log"``, etc. Make sure you remove the sample logfile lines for the channel #lamest. If you'd like to put your logfiles in their own directory, specify the directory in the log name (e.g. ``logfile jkp #donkeys "logs/#donkeys.log"`` to write the logfiles in the /logs directory).

Expand Down
4 changes: 2 additions & 2 deletions doc/sphinx_source/tutorials/tlssetup.rst
Original file line number Diff line number Diff line change
Expand Up @@ -59,9 +59,9 @@ Connecting to an Eggdrop listening with TLS
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
To connect to a bot listening with TLS, prefix the port number with a '+'. For example::

.+bot HubBot 1.2.3.4 +5555
.+bot HubBot 192.0.2.1 +5555

will use TLS to connect to 1.2.3.4 on port 5555 the next time a connection is attempted to HubBot.
will use TLS to connect to 192.0.2.1 on port 5555 the next time a connection is attempted to HubBot.

Additional Information
----------------------
Expand Down
2 changes: 1 addition & 1 deletion doc/sphinx_source/using/botnet.rst
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ At this point, you can link the two bots by typing '.link BotA' on BotB (or '.li

Secure (TLS) Links
^^^^^^^^^^^^^^^^^^
Since Eggdrop 1.8.0, the ability to encrypt bot links using TLS is possible. On the hub bot you would prefix the port given in the `listen` command with a +, and when you add the hub bot to the leaf, you would prefix the port used in the `.+bot` command with a +. In other words, you would set `listen +5555` in the hub config and use `.+bot hubbot 1.2.3.4 +5555` on the leaf bot. These settings are explained more thoroughly in the `TLS botnet documentation. <https://docs.eggheads.org/using/tls.html#botnet>`_
Since Eggdrop 1.8.0, the ability to encrypt bot links using TLS is possible. On the hub bot you would prefix the port given in the `listen` command with a +, and when you add the hub bot to the leaf, you would prefix the port used in the `.+bot` command with a +. In other words, you would set `listen +5555` in the hub config and use `.+bot hubbot 192.0.2.1 +5555` on the leaf bot. These settings are explained more thoroughly in the `TLS botnet documentation. <https://docs.eggheads.org/using/tls.html#botnet>`_


Using botflags
Expand Down
2 changes: 1 addition & 1 deletion doc/sphinx_source/using/python.rst
Original file line number Diff line number Diff line change
Expand Up @@ -93,7 +93,7 @@ bind <arguments>

An important difference to note is that Eggdrop Python has its own ``bind`` command implemented. You will generally want to create binds using the Python ``bind`` command and not import bind from eggdrop.tcl because a Python bind will call a Python function, whereas using the Tcl bind will call a Tcl function (not one from the script you are writing).

The python version of the bind command is used to create a bind that triggers a python function. The python bind takes the same arguments as the Tcl binds, but here each argument is passed individually. For example, a bind that would look like ``bind pub * !foo myproc`` in Tcl is written as ``bind("pub", "*", "!foo", myproc)``. For more information on Eggsrop bind argument syntax please see :ref:`bind_types`. The eggdrop.tcl.bind command should not be used as it will attempt to call a Tcl proc.
The python version of the bind command is used to create a bind that triggers a python function. The python bind takes the same arguments as the Tcl binds, but here each argument is passed individually. For example, a bind that would look like ``bind pub * !foo myproc`` in Tcl is written as ``bind("pub", "*", "!foo", myproc)``. For more information on Eggdrop bind argument syntax please see :ref:`bind_types`. The eggdrop.tcl.bind command should not be used as it will attempt to call a Tcl proc.

The ``bind`` command returns a PythonBind object that has an ``unbind`` method::

Expand Down
2 changes: 1 addition & 1 deletion doc/sphinx_source/using/tcl-commands.rst
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,7 @@ getuser <handle> [entry-type] [extra info]
Description: an interface to the new generic userfile support. Without an entry-type, it returns a flat key/value list (dict) of all set entries. Valid entry types are:

+----------+-------------------------------------------------------------------------------------+
| ACCOUNT | returns thee a list of servivce accounts associated with the user |
| ACCOUNT | returns a list of service accounts associated with the user |
+----------+-------------------------------------------------------------------------------------+
| BOTFL | returns the current bot-specific flags for the user (bot-only) |
+----------+-------------------------------------------------------------------------------------+
Expand Down
2 changes: 1 addition & 1 deletion eggdrop-basic.conf
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ set help-path "help/"
# a valid IP assigned to the host Eggdrop is running on in front of the port
# (this replaces the listen-addr setting used prior to Eggdrop v1.9)
#
# listen 1.2.3.4 3333 all
# listen 192.0.2.1 3333 all
#
# You need to un-comment this line and change the port number in order to open
# the listen port. You should not keep this set to 3333.
Expand Down
2 changes: 1 addition & 1 deletion eggdrop.conf
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ set userfile-perm 0600
# a valid IP assigned to the host Eggdrop is running on in front of the port
# (this replaces the listen-addr setting used prior to Eggdrop v1.9)
#
# listen 1.2.3.4 3333 all
# listen 192.0.2.1 3333 all
#
# You need to un-comment this line and change the port number in order to open
# the listen port. You should not keep this set to 3333.
Expand Down
2 changes: 1 addition & 1 deletion src/tls.c
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ static int ssl_seed(void)
*
* Creates a context object, supporting SSLv2/v3 & TLSv1 protocols;
* Seeds the Pseudo Random Number Generator;
* Optionally loads a SSL certifate and a private key.
* Optionally loads a SSL certificate and a private key.
* Tell OpenSSL the location of certificate authority certs
*
* Return value: 0 on successful initialization, !=0 on failure
Expand Down