Reputation: 182
I am looking at Google Drive API tutorials and they tell you to store credentials.json in my working directory (eg https://developers.google.com/drive/api/v3/quickstart/python).
My goal is to make a script which regularly runs on my system and downloads files from Google Drive. My concern is: does storing the credentials.json file leave me open to security risks? If anyone gets access to this file, can they not use it to gain access to all my Google Drive data?
If so, then how should I store the credentials file in a secure manner?
Upvotes: 2
Views: 1693
Reputation: 117146
The credentials.json file is used to create user credentials for your application. If someone got a hold of that they could pretend to be your application and request access of users and then do what they wanted with user data. It is very important that you keep this file secure.
Note: If you are only accessing your google drive account and not one owned by other users then you should consider looking into service accounts.
Upvotes: 2