Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6891967
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T06:28:34+00:00 2026-05-27T06:28:34+00:00

I have an Android app, which is intended for use by about 10 people,

  • 0

I have an Android app, which is intended for use by about 10 people, i.e. it will not be published and is “in house”. The app connects the user to an SSH server, using jsch. I hit a problem when deciding how the user logs on. Even though the app severely limits the user’s functionality when logged onto the server (basically only allowing the upload of certain files), they still have to log on, with the user password (everyone uses the same user account). I don’t think it is a good idea to give away the password like this, so I am thinking of ways to allow the user to use the app without knowing the login password. My ideas so far.

(1) generate a ssh key and put it on each android device. (I’m not sure how to do this yet, or if it is possible).

(2) encrypt the password and store it on the phone and then create an “app password” for the user to login to the app.

I would like advice about what is the best course of action.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T06:28:35+00:00Added an answer on May 27, 2026 at 6:28 am

    First, you can restrict on the server side what a user account can do – do this. (See below for some hints.)

    Second, I would use the public-key authentication method. Generate (different) private keys for each of the users and store it on their phones (Android phones have some kind of file system, don’t they?), maybe encrypted by a password (so evil phone thieves can’t use the key).

    (There might be some build-in crypto key holding device – if so, you can certainly use this. But I don’t know enough about Android to help here.)

    Assuming the server uses OpenSSH sshd, you can put an ~/.ssh/authorized_keys file in the home directory of this user, which contains the public keys of each phone’s private keys. These key lines can contain options, which might be used to force a command (to allow only sftp/scp) or disable all kinds of forwarding. More options are available in the sshd’s sshd_config – you might want to start a separate sshd in a jailed environment for those uploads instead of using your main one.

    From JSch, you can enable public-key authentication by using one of the addIdentity methods of the JSch object. (Disclaimer: JSch documentation was written by me.)

    You also should deliver your server’s public key with the application (and not disable checking on connection) to prevent man-in-the-middle attacks. You can use the setKnownHosts method to provide the list of known host keys to JSch.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have an android app which let the user to submit a form ,
I have an Android app which is crashing on some phones, and not on
I have an android app which gives the user the option of loading a
I have an Android app in which I use a HashMap to store container
I have an app which I want to use instead of the standard android
I'm starting an Android app which will have multiple Activities. It will be using
Sorry about the in-concise title. I have an Android app in which I draw
I have a question about maps API key. I'm writing an Android app which
I have an Android app which I use to register users on my web
I have an android app on which, when the user taps a TextView ,

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.