Nym Servers and Pseudonymous Emails

From Whonix
Jump to navigation Jump to search

About this Nymservers Page
Contributor maintained wiki page.
Support Status stable
Difficulty medium
Contributor HulaHooparchive.org
Support Support

How to use Nym Servers

Info This page is archived.

Introduction[edit]

Info These instructions are mostly defunct since Mixmaster is dead upstream; see herearchive.org for more information.

A nym server is: [1]

... a pseudonym server that furnishes an untraceable email address. The purpose of this server is to allow users to have usernames (pseudonyms) and send and receive messages without revealing their true identities. Even the nym server operators cannot trace a user's email address.

This arrangement means nym servers (and a network of anonymous remailers) send pseudonymous emails and forward the replies to the user's real email address. In order to use nym servers: [1]

  • Registration is required with an available server located on the internet.
  • A PGP key pair must be created and sent to the nym server, as well as the reply block for anonymous remailers in order to send a message to the creator's real email address for replies.

Rationale[edit]

Properly created nym server systems are considered relatively anonymous -- it is difficult to trace the nym server or identify the real email sender. [2] In addition, this configuration provides an uncensorable inbox that does not rely on a single service provider; this is beneficial in today's climate where a number of email services have abruptly shut down due to coercion or service restrictions (see Lavabitarchive.org for a recent example). Further, it is unnecessary to risk browser-based logins in a webmail interface, thereby reducing the chance of connections being intercepted or poised by adversaries relying on specific selectors.

The following guide utilizes Zax-type nym serversarchive.org [3] as they are infinitely more usable than the original GHIO-type servers which should be avoided at all costs (unless you enjoy hand-crafting reply-blocksarchive.org). Readers who are unfamiliar with the term 'reply-block' should not be concerned because no manual configuration is necessary in these instructions.

To manage your nym, messages can be sent to the nym server via a SMTP server or even a personal email address (unrecommended, but still functional). Previously Whonix strongly recommended the use of Mixmaster to communicate with nym servers, since they are commonly used together but are totally independent. Unfortunately this is no longer possible, as Mixmaster is dead upstream and has been permanently removed from Debianarchive.org.

Message Path[edit]

Table: Message Path Factors

Factor Description
Nym Server Connections
  • Remember that every message sent by your nym must be delivered to the nym server:

WhonixTor circuitMixmaster networkNym server

Newsgroup Replies
  • When the nym server receives a message from your nym (configuration or regular message), a reply is posted to the Newsgroup for the nym to confirm it was received. It can be retrieved later by downloading it from the Newsgroup:

Nym serverNewsgroupTor circuitWhonix

Other Nyms
  • If your message was sent to another nym from the same server, it will follow the same path as above. If it wasn't, it will be delivered to the respective recipient:

Nym serverRecipient

Received Messages
  • When messages are sent to your nym they are delivered to the nym server and processed, before finally being posted to the Newsgroup in a similar fashion to the earlier "Newsgroup Replies" section:

SenderNym serverNewsgroupTor circuitWhonix

Instructions[edit]

This guide uses mixnym.net, but the same steps equally apply to any other Zax-type nym server. For a selection of nym servers, see: Zax-type Nym Server List.

The examples below use the nym nym@mixnym.net -- adjust this text to match your nym choice and the domain name of the nym server.

Conventions[edit]

It is important to know which address should be used when sending messages to the nym server:

  • config@mixnym.net: creation or configuration requests, to create and manage your nym
  • send@mixnym.net: send requests, to send messages from your nym to other people
  • url@mixnym.net: url requests, to retrieve an HTML page

For an overview of the process, seven primary steps apply:

  1. Import the Nym Server Key
  2. Prepare the Nym Request
  3. Send Request to the Nym Server
  4. Retrieve Messages from the Newsgroup
  5. Decrypt Messages
  6. Send Mail with Registered Nym
  7. Reconfigure Nym

Import the Nym Server Key[edit]

A nym server's key is usually on their homepage. Follow these steps to import the key.

1. Download the mixnym.net nym server key with curl to the home folder.

curl -o key.asc http://is-not-my.name/key.asc

2. Check fingerprints/owners without importing anything.

gpg --keyid-format long --with-fingerprint key.asc

Always check the fingerprint for yourself. The output at the moment is:

pub  4096R/0xFF4DB66014D0C447 2010-05-05 URL is-not-my.name (URL Retrieval address for Is-Not-My Nymserver) <url@is-not-my.name>
      Key fingerprint = 94F2 04C2 8BF0 0937 EFC8  5D1A FF4D B660 14D0 C447

3. If the fingerprint is correct, import it with GPG.

gpg --import key.asc

Sometimes it may only be available from PGP keyservers. In that instance, download it from a keyserver such as keys.openpgp.org (zkaan2xfbuxia2wpf7ofnkbz6r5zdbbvxbunvp5g2iebopbfc4iqmbad.onion) by providing the fingerprint.

Whonix first time users warning Warning:

The following command using gpg with --recv-keys is not recommended for security reasons and is often non-functional. [4] This is not a Whonix-specific issue. The OpenPGP public key should be downloaded from the web instead; see also Secure Downloads. This procedure is currently undocumented and can be resolved as per the Self Support First Policy. Documentation contributions will be happily considered.

gpg --keyserver keys.openpgp.org --recv-keys 94F204C28BF00937EFC85D1AFF4DB66014D0C447

If the fingerprint is unknown, try and search for it.

gpg --keyserver keys.openpgp.org --search-keys config@mixnym.net

Do not forget to check the fingerprint before importing the key.

Prepare the Nym Request[edit]

Create a Key Pair[edit]

Create a new key pair for nym@mixnym.net.

gpg --gen-key

    Please select what kind of key you want:
       (1) RSA and RSA (default)
       (2) DSA and Elgamal
       (3) DSA (sign only)
       (4) RSA (sign only)
    Your selection? 1

    What keysize do you want? (2048) 4096

    Please specify how long the key should be valid.
             0 = key does not expire
          <n>  = key expires in n days
          <n>w = key expires in n weeks
          <n>m = key expires in n months
          <n>y = key expires in n years
    Key is valid for? (0) 6m

    Real name: John Doe
    Email address: nym@mixnym.net
    You selected this USER-ID:
        "nym@mixnym.net <nym@mixnym.net>"

    You need a Passphrase to protect your secret key.

    public and secret key created and signed.

Make sure to provide different information from the example above. Also note the nym expires when the key expires.

Export Public Key[edit]

To create a nym, its public key must be exported and sent to the nym server. In the following example, it will be copied to pubkey.txt.

gpg --armor --export nym@mixnym.net > pubkey.txt

Configure Additional Options[edit]

This step is only necessary if choosing to configure additional nym options, such as Subject Identification or Symmetric Encryption. For each option, prepend a line to the pubkey.txt file using the following format.

option: setting

Caps are unimportant in the option name, but are sensitive in the setting.

The nym server parameters specified here are optional. [5] They can be set immediately or changed in the future as detailed in the Reconfigure Nym section.

Table: Optional Nym Server Parameters

Parameter Description
Fixed (Plaintext) Subject Choose a unique keyword as a Subject to be able identify the nym server reply on the newsgroup with the subject option. Using a fixed subject is convenient, but anyone can link all the messages to the same nym since they all have the same subject.
Hashed Subject A better alternative to the subject option is to use hashed subjects (hSubs), by providing an hSub passphrase with the hsub option.

A hSub is made of two parts: the first is a random number and the second part is the hash of that same random number and a passphrase. As the hashing is a one-way function, it is impossible to identify the owner of the message. However, as you know your nym's hSub passphrase, it can be hashed with the random number of every message, and if the result collides with the second part of the hSub, that message was sent to your nym. [6]

Alternative options for setting a hSub include: hash-key, hash-subject and subject-password. All of these are equivalent to hsub.

Symmetric Encryption A symmetric encryption layer can be added by specifying a key with the symmetric option.
Deletion To delete your nym, the following option and setting can be sent: delete: yes.

For a concrete example, to add the hSub passphrase panda, pubkey.txt should be edited as follows:

    hsub: panda

    -----BEGIN PGP PUBLIC KEY BLOCK-----
    <snipped>
    -----END PGP PUBLIC KEY BLOCK-----

More than one option line can be added to the request, but be aware that some options might create conflicts. For example, subject and hsub work differently, but are used for the same purpose -- only one of these options should be used at the same time.

Encrypt the Request[edit]

It is necessary to wrap pubkey.txt -- the message containing additional options and the public key -- to the nym server. The pubkey.txt file is the input for the following example and the encrypted file will be created as pubkey.txt.asc:

gpg --armor --encrypt --recipient config@mixnym.net pubkey.txt

It is safe to ignore the warning about encrypting to an "untrusted" key and just select y for yes.

Send Request to the Nym Server[edit]

Before sending the request, update the remailer keys first. It is enough to complete this procedure on a daily basis: [7] [8]

    mixmaster

    u)pdate stats

    *

    pick remailer letter (optional)

    <space>

    q)uit

Send the encrypted file to the nym server with Mixmaster:

mixmaster --mail -l *,*,* -c 2 config@mixnym.net pubkey.txt.asc

Where:

  • -l customizes the remailer chain length. The shorter the chain the faster the mail will be sent, thereby improving the chances of success. In this example, three random mixes are in use: *,*,*.
  • -c sends copies of the message. In this example, 2 copies are sent.

If necessary, run Mixmaster from the command line and check the remailer chain list to see node availability and reliability statistics, then choose accordingly.

If all steps were followed correctly, the nym server will decrypt the message, extract your nym's email address from the supplied public key, then process it. Provided the nym is not reserved or already taken, a confirmation message will be received from the nym server, encrypted to your nym's key.

Note that the protection provided by Mixmaster is of little importance here because everything is done behind Tor. [9]

Info Important: Take note that this is the only message where the public key is attached, as well as the only one the server will ever accept that is not signed by that key. From now on, the nym's digital signature will prove your ownership of it. Examples on signing can be found in Send Mail with Registered Nym and Reconfigure Nym.

Retrieve Messages from the Newsgroup[edit]

Zax-type nym servers deliver messages to nyms via the alt.anonymous.messages Usenet group (a.a.m). Anyone can access these messages, but only the nyms can decrypt them by using their private keys.

As explained earlier, messages can be configured to be identified by subject. If a form of subject identification was set up from the previous section, then refer to the Use aam2mail to Fetch Replies section.

If subject identification was not configured but is desirable, then a configuration message must be sent to stipulate a method of subject identification. An example can be found in the Reconfigure Nym section.

If no form of subject identification is desired, then the default method is to download and attempt to decrypt every message posted on the Newsgroup. If it works, then the message was sent to your nym.

Use aam2mail to Fetch Replies[edit]

1. Install git and clone aam2mail source.

aam2mail does not have any extra dependencies.

sudo apt install git git clone https://github.com/crooks/aam2mail cd aam2mail sudo python setup.py install

2. Configure aam2mail settings.

Utilize the hsub that was chosen.

mkdir ~/aam2mail/etc echo 'panda' >> aam2mail/etc/subject_hsub echo 'nntp.aioe.org' >> aam2mail/etc/servers

3. Run aam2mail periodically to check for messages.

There is an expected delay of a few hours before receiving replies.

aam2mail --start

or

aam2mail --restart

4. Check for replies downloaded by aam2mail.

The default path is /home/user/Maildir/new. aam2mail will only retrieve messages and not decrypt them.

Be sure to check for new messages regularly; messages on Usenet accumulate beyond the fetch-limit and can easily be missed.

Decrypt Messages[edit]

With the message saved to a file, decrypt it as follows.

gpg --decrypt file

If successful, the plaintext of the message your nym received should be visible.

Congratulations on registering your first nym! Now it can be used for sending messages.

Send Mail with Registered Nym[edit]

To send messages to other people, the steps are very similar to those used previously for creation and configuration.

1. Use a text editor to compose the message.txt file.

To: recipient@domain Subject: Example This is an example

2. Encrypt and sign to the server.

gpg --armor --encrypt --sign --recipient send@mixnym.net message.txt

3. Send the file with Mixmaster.

This time the message is sent to send@mixnym.net.

mixmaster --mail -l *,*,* send@mixnym.net message.txt

The recipient will receive a message from nym@mixnym.net and they can send a reply to the same address.

Take note that copies of the message were not sent on this occasion. This was advisable for the creation step, because after receiving the first one the server would ignore the others. In this case of sending mail, if copies are sent the server will send all of them to the recipient.

Reconfigure Nym[edit]

1. To add (or change) an option, another message must be sent to config@mixnym.net.

This message must state option.txt and the additional option(s) that should be added.

hsub: passphrase

The message does not require a body, just headers.

2. Remember to sign and encrypt the message.

gpg --armor --encrypt --sign --recipient config@mixnym.net option.txt

3. Send the message.

As you are configuring the nym, it should be sent to config@mixnym.net.

mixmaster --mail -l *,*,* config@mixnym.net option.txt.asc

Important Notes[edit]

End-to-End Encryption[edit]

The encryption layers discussed in this wiki entry will only protect data between the nym and the server. It is recommended that another form of end-to-end encryption (another layer) is added between you and the recipient, for example by encrypting the body of the message first, and then encrypting to the server's key.

Bear in mind the headers cannot be encrypted, so an end-to-end encrypted message would appear similar to the example below.

    To: recipient@domain
    Subject: Subject

    -----BEGIN PGP MESSAGE-----
    <snipped>
    -----END PGP MESSAGE-----

After this step, users would then encrypt to the nym server so it would appear like the example below.

    To: send@server

    -----BEGIN PGP MESSAGE-----
    <snipped>
    -----END PGP MESSAGE-----

Message Ordering[edit]

Due to Mixmaster's latency, it is possible for messages to arrive out of order. For instance, later messages might arrive earlier than the creation message. If no responses are received, it is necessary to send them again once the nym is created.

Multiple Nyms[edit]

If more than one nym is used, you must remember to choose which nym will sign the message, or always use the same nym to send the messages, and consequently only these messages will be accepted. As noted earlier, the only message accepted without a signature is the creation message.

To specify the nym that will sign the message, use the --local-user flag.

gpg --armor --encrypt --sign --recipient send@server --local-user nym@server message.txt

Public Mailbox[edit]

When someone sends a message to your nym, the server will receive it, encrypt to the nym and post it on a.a.m so it can be retrieved. The Newsgroup acts as a public mailbox -- everybody can see and download the messages but only the intended recipient (your nym) can decrypt it.

Zax-type Nym Server List[edit]

Although the reference is dated, active Zax-type nym servers in 2019 include: [10]

Public/Open News Servers[edit]

Other Useful Topics[edit]

  • The default Mixmaster editor can be changed to something more usable than vi with the following steps. [13]

Whonix Xfce:

sudo echo 'export EDITOR=mousepad' >> ~/.bashrc

Logout and then log back in again for changes to take effect.

  • What happens if you register a nym that is already taken?

A message will be received in a.a.m that it is already taken. [14]

Development Notes[edit]

  • Explore whether aam2mail [15] can be shipped as a stand-alone python utility for hsub management.
  • Further reading: the Mixnym.net key expired but Zax fixed the problem. [16]

See Also[edit]

Sources[edit]

This wiki entry is based on Zax's helparchive.org guidesarchive.org on Mixnym.net, which is also archivedarchive.org herearchive.org. Appreciation is also expressed to the Nymphemeralarchive.org developer, [17] Felipe Dau, for helping with these instructions.

Footnotes[edit]

  1. 1.0 1.1 https://www.techopedia.com/definition/1696/nym-serverarchive.org
  2. Explaining why they are sometimes use by parties for malicious purposes.
  3. Zax (aka Steve Crook) is the author of this newer type of nym server.
  4. https://forums.whonix.org/t/gpg-recv-keys-fails-no-longer-use-keyservers-for-anything/5607archive.org
  5. https://groups.google.com/g/alt.privacy.anon-server/c/f3H4Xw5j2LIarchive.org
  6. https://web.archive.org/web/20221205224559/https://is-not-my.name/hsub.htmlarchive.org
  7. https://www.youtube.com/watch?v=Oaft_WNMUIgarchive.org Steven Murdoch
  8. https://web.archive.org/web/20190915082414/https://www.youtube.com/watch?v=dzbrFPO4604&gl=US&hl=enarchive.org LinuxJournal
  9. https://www.mail-archive.com/liberationtech@lists.stanford.edu/msg00022.htmlarchive.org
  10. https://alt.privacy.anon-server.narkive.com/Zd27lR8z/how-to-get-nymserver-help-keyarchive.org
  11. A open (read-only) (text) usenet server. Both nntp and nntps are supported. https://dizum.com/archive.org
  12. 12.0 12.1 Used by QSA: https://web.archive.org/web/20221007035558/https://sec3.net/www.quicksilvermail.net/archive.org
  13. https://alt.privacy.anon-server.narkive.com/5dbZVYpQ/choice-of-editor-with-mixmasterarchive.org
  14. https://alt.privacy.anon-server.narkive.com/Zd27lR8z/how-to-get-nymserver-help-keyarchive.org
  15. The latter is also written by Steve Crook, see: https://github.com/crooks/aam2mailarchive.org
  16. https://groups.google.com/g/alt.privacy.anon-server/c/A6ltHhItGrwarchive.org
  17. pypi.orgarchive.org:

    It is a GUI client that relies on a pseudonym remailer that communicates to its users by posting messages to a shared mailbox, a Zax-type nym server. Both the server and the client apply an ephemeral encryption layer on their messages based on the Axolotl Ratchet protocol, providing forward and future secrecy to the conversation.

We believe security software like Whonix needs to remain open source and independent. Would you help sustain and grow the project? Learn more about our 12 year success story and maybe DONATE!