Skip to content

Commit

Permalink
Add fetchuri example; fixed typo in ignore-errors
Browse files Browse the repository at this point in the history
  • Loading branch information
l50 committed Sep 15, 2023
1 parent 21d7a48 commit b58cc95
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 1 deletion.
33 changes: 33 additions & 0 deletions ttps/examples/fetchuri/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
# Using the FetchURI Step in TTPs

Discover how to effectively employ the `FetchURI` step in TTPs to fetch content
from a specific URI and store it in a file.

---

## Running `fetchuri-example.yaml` Demonstration

To observe the functionality of the `FetchURI` step in action, execute:

```bash
ttpforge run forgearmory//examples/fetchuri/fetchuri.yaml
```

---

## Expected Output

```text
INFO [*] Validating Steps
INFO [+] Finished validating steps
INFO [+] Running current TTP: fetchuri_step_example
INFO [+] Running current step: fetch-google-and-store-in-file
INFO ========= Executing ==========
INFO ========= Result ==========
INFO [+] Finished running step: fetch-google-and-store-in-file
INFO [*] Completed TTP
INFO [*] Beginning Cleanup
INFO ========= Executing ==========
INFO ========= Result ==========
INFO [*] Finished Cleanup
```
11 changes: 11 additions & 0 deletions ttps/examples/fetchuri/fetchuri.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
---
name: fetchuri_step_example
description: Illustrates how to employ the FetchURI step.

steps:
- name: fetch-google-and-store-in-file
fetch_uri: https://google.com
location: ./google.txt
overwrite: true
cleanup:
inline: rm google.txt
2 changes: 1 addition & 1 deletion ttps/examples/ignore-errors/ignore-errors.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
name: ignore-errorsure
name: ignore-errors
description: |
Illustrates how to create a step that will allow the TTP to continue,
even if an error occurs.
Expand Down

0 comments on commit b58cc95

Please sign in to comment.