diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 730853c..4ee9a24 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -14,7 +14,7 @@ jobs: runs-on: ubuntu-latest services: ctfd: - image: ctfd/ctfd:3.7.3@sha256:90470e1fe0f93028ce6ac197b8942916ee157d4b5d33c8266c5bec7662e55ac3 + image: ctfd/ctfd:3.7.4@sha256:b2cc1ff1767d919282cf9811ec41a9a4f994d502f502b4a8852999ffb1b7e81a ports: - 8000:8000 steps: diff --git a/README.md b/README.md index 51642f4..13cd648 100644 --- a/README.md +++ b/README.md @@ -13,4 +13,4 @@ Golang client for interacting with [CTFd](https://ctfd.io/). -Last version tested on: [3.7.3](https://github.com/CTFd/CTFd/releases/tag/3.7.3). +Last version tested on: [3.7.4](https://github.com/CTFd/CTFd/releases/tag/3.7.4). diff --git a/api/challenges.go b/api/challenges.go index 31534ba..19bfd49 100644 --- a/api/challenges.go +++ b/api/challenges.go @@ -26,6 +26,7 @@ type PostChallengesParams struct { Name string `json:"name"` Category string `json:"category"` Description string `json:"description"` + Attribution *string `json:"attribution,omitempty"` Function string `json:"function"` ConnectionInfo *string `json:"connection_info,omitempty"` Value int `json:"value"` @@ -81,6 +82,7 @@ type PatchChallengeParams struct { Name string `json:"name"` Category string `json:"category"` Description string `json:"description"` + Attribution *string `json:"attribution,omitempty"` Function string `json:"function"` ConnectionInfo *string `json:"connection_info,omitempty"` Value *int `json:"value,omitempty"` diff --git a/api/model.go b/api/model.go index 43b5296..4159e44 100644 --- a/api/model.go +++ b/api/model.go @@ -5,6 +5,7 @@ type ( ID int `json:"id"` Name string `json:"name"` Description string `json:"description"` + Attribution *string `json:"attribution"` ConnectionInfo *string `json:"connection_info,omitempty"` MaxAttempts *int `json:"max_attempts,omitempty"` Function string `json:"function"` diff --git a/examples/setup/main.go b/examples/setup/main.go index 8820a3f..bfe8ac0 100644 --- a/examples/setup/main.go +++ b/examples/setup/main.go @@ -61,6 +61,7 @@ func main() { Name: "Break The License 1/2", Category: "crypto", Description: "...", + Attribution: ptr("pandatix"), Function: "logarithmic", ConnectionInfo: ptr("ssh -l user@crypto1.ctfer.io"), MaxAttempts: ptr(3), @@ -121,6 +122,7 @@ func main() { Name: ch.Name, Category: ch.Category, Description: ch.Description, + Attribution: ch.Attribution, Function: ch.Function, ConnectionInfo: ch.ConnectionInfo, Initial: ch.Initial,