Skip to content

Add basic authentication #60

Closed
Closed

Description

@reuster986

Currently, a running arkouda server can be hijacked by anyone on the system that knows the hostname and port. We should implement some sort of authentication, either via a password or a token. My vote is for a token, because it's what Jupyter uses, and it's less of a burden on the user.

arkouda_server.chpl should:

  • generate a cryptographically secure random token (probably with Crypto.CryptoBuffer
  • print the token upon server startup (like jupyter notebook)
  • save the token (and hostname:port) to a user-readable-only file like ~/.arkouda-running-servers, so that a user can find how to reconnect to a running server (jupyter also does something like this)
  • check for the correct token in the "connect" message

For convenience, ak.connect() should be modified to accept the raw connection string that arkouda_server prints on startup with the hostname, port, and token.

Activity

  1. added
    enhancement
    good first issue
    on Jun 6, 2019
  2. mhmerrill commented on Mar 27, 2020

    @mhmerrill
    Contributor

    @hokiegeek2 thye system will not allow me to assign this to you for some reason. I am going to create a new issue, link it to this one, and assign that to you.

  3. hokiegeek2 commented on Mar 27, 2020

    @hokiegeek2
    Contributor
  4. mhmerrill commented on Mar 27, 2020

    @mhmerrill
    Contributor

    Weird, that’s a dirty trick by GitHub! 😜 Maybe Bill has to assign it?
    …
    On Mar 27, 2020, at 9:40 AM, Michael Merrill @.***> wrote: @hokiegeek2 https://github.com/hokiegeek2 thye system will not allow me to assign this to you for some reason. I am going to create a new issue, link it to this one, and assign that to you. — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#60 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACSJDAIOQPJMQ5YTKMIYR3DRJSUDHANCNFSM4HVIP3CQ.

    I can't even assign you to the new issue ;-(

  5. mhmerrill commented on Mar 27, 2020

    @mhmerrill
    Contributor

    now it worked ??? you are assigned @hokiegeek2

  6. hokiegeek2 commented on Jun 4, 2020

    @hokiegeek2
    Contributor

    @mhmerrill @reuster986 I have a prototype of this working in Python using zmq certs for authentication. The server-side is here:

    image

    The client side is here:

    image

    Here's the print statements, server and client-side, respectively:

    image

    image

    The way it works is certificates are generated from zmq and those are used to connect to ZeroMQ and, depending upon the authentication mechanism, authenticate. There are three scenarios I have working:

    1. no authenticator -> still need certs to establish connection, but no authentication is done, including on whitelist or blacklist urls
    2. global authenticator -> lets everyone through for a given domain. Whitelist and blacklist urls can be configured, so where the user is connecting from is the authentication mechanism.
    3. keys -> the zmq certs for approved users (clients) are loaded, users authenticated via their respective zmq certs.
  7. 15 remaining items

  8. hokiegeek2 commented on Aug 5, 2020

    @hokiegeek2
    Contributor

    @mhmerrill @reuster986 Are we good to close this issue?

  9. hokiegeek2 commented on Sep 3, 2020

    @hokiegeek2
    Contributor

    @mhmerrill is it cool to close this?

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

Metadata

Metadata

Assignees

Labels

enhancementgood first issue

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions