Giter VIP home page Giter VIP logo

Comments (6)

ilyakaznacheev avatar ilyakaznacheev commented on July 30, 2024

I'm not very familiar with this practice. Could you give me an example of how and when it applies?

from cleanenv.

s3rj1k avatar s3rj1k commented on July 30, 2024

@ilyakaznacheev To hide credentials from none root users when application is started from systemd (as daemon) with none root users.

That way credentials are only available to systemd (and root) in initial start of application, then after start and user change they are dropped from environment.

from cleanenv.

ilyakaznacheev avatar ilyakaznacheev commented on July 30, 2024

What you mean by "hide"?

The library only reads configs, not prints them or something like that. Hiding sensitive data from users is far beyond its scope.

from cleanenv.

s3rj1k avatar s3rj1k commented on July 30, 2024

Setting private information inside env, this info will still be accessible from application and even from /proc/PID/environ.

By hiding I mean, unsetting env key that contains sensitive information.

You could say that this is not in scope of library, but without this, using library doesn't make much sense.
One would still have to manage env so why not manage all envs.

Feel free to close if you think that this is not important.

from cleanenv.

ilyakaznacheev avatar ilyakaznacheev commented on July 30, 2024

The library doesn't manage the environment. It only reads from env variables, and only if it was chosen as a source of data.

You may try to use a custom setter to unset the environment variable there.

I will think about adding some kind of middleware with more metainfo on input.

from cleanenv.

ilyakaznacheev avatar ilyakaznacheev commented on July 30, 2024

So the solution - do not pass sensitive data with environment variables, use config files instead. You can remove the file just after the app started, so the requirements will be met. You can do that directly from the app.

And yes, it is not in the scope of the library, but you can easily achieve it like as I said before.

from cleanenv.

Related Issues (20)

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.