GithubHelp home page GithubHelp logo

skynet-im / skynet-server Goto Github PK

View Code? Open in Web Editor NEW
4.0 3.0 0.0 1.16 MB

Skynet server application

License: GNU General Public License v3.0

C# 95.15% HTML 3.69% CSS 0.38% JavaScript 0.11% Dockerfile 0.66%
messaging cloud-sync dotnet ef-core

skynet-server's People

Contributors

beniox avatar daniel-lerch avatar twometer avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

skynet-server's Issues

Synchonization not parallel

When logging in on two separate devices with two separate accounts, the server sends packets sequentally. This means that one device has to wait for the other device to finish synchronizing. Depending on the dataset, this can take a loooong time. As there is no indication that content is waiting to be downloaded, the user may think the app has crashed, or even worse, that his data is gone.

Confirmation mail

A new confirmation mail for Skynet has to be designed.
The latest draft (download) by @Twometer for Skynet v4 can be used for inspiration.

Required changes:

  • Username is no longer available after account creation
  • Make use of $ADDRESS to show the account's address to the user
  • Make use of $TOKEN to build the confirmation URL
  • Show an Link as alternative if the button is not working
  • Adapt the new design theme

Colors:

  • Primary: #10304c
  • Primary Dark: #0d273d
  • Accent: #ffab40

Message Dependency Verification

Clients can currently send any dependencies as long as the referenced Message exists. The server should verify Dependencies to prevent clients from referencing messages from channels they are not a member of or referencing messages like MessageReceived or MessageRead.

Exception handling

The Skynet server needs a new concept to handle disconnects. Exceptions that occur while receiving the next packet are easy to handle. Sending a packet on the other hand happens asynchronously which makes it very dangerous to dispose objects.

Subsequent send calls should be omitted after a disconnect and packet sources should be disposed in order not to waste resources. To achieve this goal it might be necessary to inform several components about a disconnect. Generally, packets that could not be delivered can be discarded without notice as the protocol does not require the client to receive all packets that were sent by the server.

Detect equal email addresses

Some email providers make their customers accounts available on multiple domains or with additional labels. The Skynet server should detect this at register to avoid registering multiple accounts on the same address. There is information, how to solve this problem for Googlemail on StackOverflow.

Dependencies get lost

When sending a ReceiveConfirmation message, the client attaches a dependency to the received message to it. However, the dependency is lost somewhere along the way so that the receiver cannot process the message and crashes.

Add debug features for message states

Skynet has always been struggling with message state bugs. The server should include features to debug such problems. The database audit command should list all chat messages that have not been marked as delivered or read.

Inform clients about a channel before using it

There are several race conditions that can lead the server to forward a channel message to client which has not yet received the respective CreateChannel packet.

This happens especially at session creation or restore before the sync has completed and when a new channel is created with its channel members in one database transaction.

Store secrets only as hash

The Skynet server has to handle some secrets such as KeyHash, SessionToken and WebToken. These secrets are not sufficient to read encrypted messages but an attacker could leave a foreign account in a corrupted state and could bypass a future server sided brute force protection.

Storing the SHA-256 hashes of the respective secrets would be the easiest solution for this issue.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.