Hello Administrator, 

thank you for providing the SafeWebdrop service on your server.

After downloading the source code [ https://safewebdrop.com/code ]
you will find the server-side bash scripts in the server directory.
Copy or move the "safewebdrop*" scripts into your server's
cgi-bin directory and make sure they are owned by the server UID
(which may well be  48/apache).

Move the directory "server/home/safewebdrop" into /home and copy the script
"accept" into /home/safewebdrop/admin.

By now your SafeWebdrop service is installed and can be used.

People using your server can now register with the CryptoBone
software on their computers. 
Once registered, they will contact you with the registration code
your server will create on registration. Have a look in the admin
directory, you will find the user's uploaded public key and a 
file NAME.request. Check the registration code and if it matches
the information the user has given you first hand, then you can
enable the user by running "./accept NAME". This script will create
a directory for the user and copies the public key into it.

That's all you have to do, everything else is done by the server
scripts.

Your involvement stops, when you have accepted a user.
If you wish to dismiss a user, just remove their directory
from the server. Nothing more needs to be done.

#----------------------#

To test the functionality of your service, put the files in the
"tests" directory on a computer that can access your server via
the internet.

Here are some examples

# change into the bin directory!
# register adam and eve
    ./registrationtest adam yourserver.com
    ./registrationtest eve yourserver.com

# to enable these two users on your server, run ./accept adam and ./accept eve there.

# send a message from adam to eve
    ./sendtestmessage adam yourserver.com eve yourserver.com

# read all messages as eve 
    ./gettestwebdrops eve yourserver.com    

# you'll find the messages in "../eve/batch"
    cat ../eve/batch
    ./decryptfile ../eve/batch
    cat ../eve/batch-message

# if many messages arrive, you have to split them and process individually.

# send an attachment with a message
    cp someattachmentfile ../eve
    ./sendtestmessageandattachment eve yourserver.com adam yourserver.com someattachmentfile

# download attachment and message as adam
    ./gettestwebdropsandattachment adam yourserver.com
    cat ../adam/batch
    cat ../adam/filebatch
    ./decryptfile ../adam/batch
    cat ../adam/batch-message

    ./decryptfile ../adam/filebatch
    cat ../adam/filebatch-message

# the attachment file is now in clear text, you may change the name to reflect
# the original filename and extension.

    mv ../adam/filebatch-message someattachmentfile.ext


#----------------------#

# If a third user harry is already registered by another administrator on
# a different server, adam can allow harry%otherserver.com to contact him:

    ./sendcrosspermission adam yourserver.com harry otherserver.com

# If harry replies with:

    ./sendcrosscontact harry otherserver.com adam yourserver.com

# then both users can now communicate in the same way local users can.


#----------------------#

NOTE, that these scripts are to check that everything works correctly,
your users will use the SafeWebdrop service with the CryptoBone GUI.

But of course, you can use the service for your own messaging project
as well.

If you have comments or questions you can contact me directly:
https://senderek.ie/contact

#----------------------#

