如何在VS Code中使用SFTP防止文件上传?

huangapple go评论57阅读模式
英文:

How to prevent files upload on VS Code with SFTP?

问题

我的团队一直将.vscode文件夹与sftp.json文件上传到我们的项目中,造成了安全漏洞。
我们都使用SFTP插件,这对我们非常有帮助!

是否有一个配置或文件可以编辑以防止文件上传?

英文:

My team keeps uploading .vscode folder with sftp.json file to our projects, creating a security flaw.
We all use SFTP plugin, which helps us a lot!

There is a config or a file where we can edit to prevent a file upload?

答案1

得分: 1

在您的上传文件夹中创建一个名为.vscode的文件。这将阻止sftp插件在远程站点上创建一个名为.vscode的文件夹。

英文:

Create a file called .vscode in your upload folder. This will prevent the sftp plugin from creating a folder, called .vscode, on the remote site.

答案2

得分: 1

"你可以将以下内容添加到 sftp.json 文件中:

"ignore": [
    ".vscode/**",
    "YourAnyOtherFolder/**"
]"
英文:

You can add to the sftp.json file the following lines:

"ignore": [
    ".vscode/**",
    "YourAnyOtherFolder/**"
]

huangapple
  • 本文由 发表于 2023年6月8日 21:39:57
  • 转载请务必保留本文链接:https://go.coder-hub.com/76432460.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定