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

Offline Capabilites #21

Open
amenk opened this issue Mar 11, 2016 · 10 comments
Open

Offline Capabilites #21

amenk opened this issue Mar 11, 2016 · 10 comments

Comments

@amenk
Copy link
Collaborator

amenk commented Mar 11, 2016

When I loose the internet connection, I can not view secrets any more.

Are there any plans for offline capabilities? Even for the login?

@teh
Copy link
Member

teh commented Mar 11, 2016

No plans but if you want to give it a shot I think there are a few parts to this:

1/ Change the fetching code to check whether the user is offline (https://developer.mozilla.org/en/docs/Online_and_offline_events) with navigator.onLine
2/ If offline read data from localstore
3/ If online store encrypted data in localstore

There's probably more I forgot about around logging in etc.

@amenk
Copy link
Collaborator Author

amenk commented May 10, 2016

Okay, sounds good so far.
But what happens when I change any data? Is there any kind of versioning or locking?

Testcase:

  1. I am offline
  2. Open a cached secret
    2A. Another user changes at the same secret at the server
  3. Change something
  4. Go online
  5. Save

@teh
Copy link
Member

teh commented May 11, 2016

That's an issue with all distributed data stores. E.g. git has merges, couchdb has various conflict resolutions (latest wins) e.g. We'd have to pick one and run with that.

A read-only offline version might be a good start.

@amenk
Copy link
Collaborator Author

amenk commented May 11, 2016

How is it currently handled?
I mean conflicts already can appear, if in a shared secret, two users are editing at the same time, right?

@teh
Copy link
Member

teh commented May 11, 2016

Currently it's newest write wins.

@amenk
Copy link
Collaborator Author

amenk commented May 11, 2016

Oh my ...

I think it would be sufficient to have a revision number and allow only writing if I had the last revision number. (OpenStreetMap is doing it that way)

By the way ... are secret entries versioned already?

@teh
Copy link
Member

teh commented May 11, 2016

There's no versioning. The server has very little information - that's a design decision. It's a dumb key value store with auditing and sharing.

@amenk
Copy link
Collaborator Author

amenk commented Apr 2, 2017

We might just allow editing only when you are online, what do you think? Like this the feature should be not-so-hard?

@teh
Copy link
Member

teh commented Apr 2, 2017

There isn't even a concept of "being online" but we could introduce that if you want to give it a go.

First though it might be interesting to understand what problems you are hitting>

@amenk
Copy link
Collaborator Author

amenk commented Apr 2, 2017

I just want to be able to access my passwords when I am offline.
example use case: Our companys router is offline, I need the password to login and fix it.
or: I am in Ethiopia and they seem to block the access to passopolis -> no passwords accessible

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants