Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

2
  • +1 for mentioning the security implications of creating queries as strings. Even for purely internal systems, there are often possibilities for mistakes or external inputs. Libraries/frameworks often have ways to specify params separately, so that they get sanitised automatically; and they usually provide a way to sanitise manually if needed. Commented Apr 13, 2023 at 22:17
  • 1
    I'm glad you mentioned SQL injection. It's unlikely that an arracker could use the environment variables to cause direct harm to the database; however, it might be very easy for an attacker to use SQL injection to access information that was not intended to be exposed. Commented Apr 13, 2023 at 23:19