Skip to content

kgost/saoirse

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Saoirse

Saoirse Is an end to end encrypted messaging app. Using RSA keys for each user and AES keys to encrypt atual messages, all messages are encryptd and unencrypted on the client side, without the server ever storing the unencrypted keys, meaning even the server won't be able to decrypt your messages, it simply organizes conversations and friendships and stores encrypted strings.

Getting a dev environment running

NOTE: the environments here are only suitable for development, to setup for production you will need to do various things like replacing urls with the urls you will be using and swapping out passwords and keys

On Windows and MacOS

follow this guide and then continue with the tutorial guide

Using just nodejs

Back End

first you will need to have a running mysql database and have its database and config match the settings in back/config/config.json.

npm install -g sequelize-cli
cd back
sequelize db:migrate
# sync the database to all the relations are set
node sync.js
# install the back end dependencies
npm install

create the file back/.env and fill the following environment variables

JWTKEY=""
PRIVATE_VAPID_KEY=""
PORT=8080

you can pick any JWTKEY you want, to generate a vapid keypair:

npm i -g web-push
web-push generate-vapid-keys --json

use this for the vapid keypair now just run the express server

node app.js

Front End

set the public vapid key as base64String in front/src/store.ts and front/src/views/Settings.vue then run

npm run serve

now the app will be up and running on localhost:3000 any changes you make to the front end will automatically rebuild but the backend must be restarted manually To get push notifications and service workers running you will need to run

npm run build

you then need to serve the dist folder as a pwa, there are many ways to do this, look into https://www.npmjs.com/package/http-server-pwa

Using Docker

You must have docker and docker-compose installed and working.

Same as in the previous enviroment, you must setup your vapid keys and other enviroment variables, located in back/Dockerfile.

You don't need to change any database settings as docker has everything setup already.

Now just run.

docker-compose build
docker-compose up

And the app will launch and be available at localhost:3000.

Any changes made to front/src will automatically rebuild the front end and any changes to config, functions, models, routes, controllers and migrations will automatically update on the backend. When installing new packages for either or changing other settings you must rebuild and reup.

Using Kubernetes

you must setup the Dockerfile and vapid keys same as before to use with kubernetes, you must already have your kubernetes cluster setup, then use:

kubectl apply -f saoirse-back.yml
kubectl apply -f saoirse-front.yml

the app will launch at 10.96.1.2, you can setup an alias in your hosts file if you want

About

end to end encrypted messaging app

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published