The creation of an Apps Script project is used to write, manage, and execute JavaScript code that automates and extends the functionalities of Google apps.
Step-by-step procedure:
-
Unzip the file provided by Cyber Guru. Inside, there are 3 files: onGmailMessageOpen.gs, onDefaultHomePageOpen.gs and appscript.json
-
Go to Apps Script
-
Click "New Project" at the top left:
- Once you click on "New Project", the following page will open:
5. Delete the file Code.gs:
6. Click on the "+" to add a new file, rename it to onDefaultHomePageOpen and copy the content from the file extracted from the zip:
7. Click on the "+" to add a new file, rename it to onGmailMessageOpen and copy the content from the file extracted from the zip:
In the first two lines, there are addresses to configure for forwarding simulation emails to Cyber Guru and real phishing emails.
Note: The names of the two variables “addressCGphishing” and “addressRealPhishing” CANNOT be changed to avoid potential script malfunction. In the text of the variable "addressRealPhishing" where it says "mailbox.dedicata@azienda.org", you need to insert the email address where the real phishing should be sent, such as a SOC/CERT email.
8. Open the settings by clicking on the gear on the left and enable "Show "appsscript.json" manifest file in editor":
9. In the editor, the file appscript.json will appear. Copy the content of appscript.json from the zip into it:
10. Click on "Save project"