

This would save you countless time and repetitive clicks to upload files to remove server manually. That being said, if necessary, this is how you can map a local directory to remove server via FTP/SFTP directly within Sublime Text. We all know working off a live website is not a good idea. Key Takeawayīefore making any project public, make sure the Github repository as well as previous commit branches does not contain hardcoded credentials and config files.Here is an extremely useful trick that allows you to directly upload a file to remote FTP server upon saving in Sublime Text.

So when we use this github dork, we get many results with php projects containing hardcoded credentials.Īttackers can take advantage of this information disclosure bug to hijack the database completely and deal more damage.

Usually the config.php file is used to provide configuration details for a php application which will be used to establish a database connection. It is very common for php applications to hardcode database credentials. So, if we search in github for sftp-config.json, we get several results, one of which is a web-programming project that contains credentials in plain text. This file contains sensitive information such as username, password, and IP address to connect. Once you setup the SFTP in sublime, sftp-config.json file is created as following: Sftp can be used with both password and/or key based authentication. For this purpose, sftp package in sublime comes handy. Many developers prefer sublime text for remote development. The file sftp-config.json is created by sublime text editor. Let’s go through a couple examples of these to find secrets. A good collection of Github dorks is available here: These secrets can be found with special Github search queries also called Github Dorks. to the repository in addition to their code. These secrets are the product of developers unknowingly pushing their credentials, server secrets, passwords, etc. In addition to hosting millions of lines of code, Github contains a ton of secrets hidden in the depths of various repositories.
