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 799041
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 14, 20262026-05-14T23:03:52+00:00 2026-05-14T23:03:52+00:00

I am building a suite of batch jobs that require regular access to a

  • 0

I am building a suite of batch jobs that require regular access to a database, running on a Solaris 10 machine. Because of (unchangable) design constraints, we are required use a certain program to connect to it. Said interface requires us to pass a plain-text password over a command line to connect to the database. This is a terrible security practice, but we are stuck with it.

I am trying to make sure things are properly secured on our end. Since the processing is automated (ie, we can’t prompt for a password), and I can’t store anything outside the disk, I need a strategy for storing our password securely.

Here are some basic rules

  1. The system has multiple users.
  2. We can assume that our permissions are properly enforced (ie, if a file with a is chmod’d to 600, it won’t be publically readable)
  3. I don’t mind anyone with superuser access looking at our stored password

Here is what i’ve got so far

  • Store password in password.txt
  • $chmod 600 password.txt
  • Process reads from password.txt when it’s needed
  • Buffer overwritten with zeros when it’s no longer needed

Although I’m sure there is a better way.

  • 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-14T23:03:53+00:00Added an answer on May 14, 2026 at 11:03 pm

    This is not a solution for cryptography. No matter the cipher used, the key will be equally accessible to the attacker. Cyrpto doesn’t solve all problems.

    chmod 400 is best, this makes it read only. chmod 600 is read write, which may or may not be a requirement. Also make sure its chown’ed by the the process that needs it. This is really the best you can do. Even if you are sharing the machine with other users they shouldn’t be able to access it. Hopefully this is a dedicated machine, in that case there isn’t much of a threat. SELinux or AppArmor will help harden the system from cross process/cross user attacks.

    Edit:
    shred is the tool you need to securely delete files.

    Edit: Based on Moron/Mike’s comments the unix command ps aux will display all running processes and the command used to invoke them. For instance the following command will be exposed to all users on the system: wget ftp://user:password@someserver/somefile.ext. A secure alternative is to use the CURL library. You should also disable your shells history. In bash you can do this by setting an environment variable export HISTFILE=

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

Sidebar

Related Questions

I am building an automation test suite which is running on multiple machines, all
In my current job I'm building a suite of Perl scripts that depend heavily
I'm currently building a unit test suite for my application, using QTestLib . It's
building a site using PHP and MySQL that needs to store a lot of
I'm building a site in django that interfaces with a large program written in
I'm building a site with django that lets users move content around between a
I am building a site that will (obvisouly) have a front end public portion
I'm building tests for a suite of enterprise-ware. The good advice I had from
First off, I'm using Access 2000 and DAO. I have code that executes a
I'm currently building a suite of Watir tests for my .net web application. I

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.