4

I am an absolute beginner with GitHub Actions.

There are Actions available on the market place. Can any of those actions do malicious things to my repository, such as, say,

  • deleting my repo?
  • commit malicious code into my repo?
  • copy the content from private repositories?
shuhalo
  • 5,732
  • 12
  • 43
  • 60

1 Answers1

7

The answer is (unfortunately) YES

You can find some references here:

Understand that this is the same thing with most libraries you use to code on a daily basis.

Github Actions on the Github Marketplace are generally public open source repositories, and aren't always backed-up by big companies.

Most of them do simple operations that you can check by looking at the repository code, but it is always possible for the owner to configure malicious things deep inside the implementation.

That's why you need to be aware of this when choosing one or another action/library, and be cautious and check the code and its eventual vulnerabilities before using them for your own projects.

Be even more cautious if you need to inform Personal Access Token (PAT) as input variable.

Note that Github shows verified users on the Marketplace, which can be considered as 'trusted'.

Example:

enter image description here

Hopefully, not everyone has this mindset (of doing malicious things), and the community is most of the time helpful. Just be aware that there might always be some risks (and some security tools can help with that).

GuiFalourd
  • 15,523
  • 8
  • 44
  • 71
  • 1
    Thanks. I presume that 'actions' is somewhat a verified collection of actions and about as trustworthy/secure as GitHub itself. – shuhalo May 26 '21 at 19:54
  • I know that the GitHub Team is working on some ways to restrict the `GITHUB_TOKEN`, because the current token has a lot of permissions. So this brings us more security. – Nils Reichardt Jul 16 '21 at 19:25