diff options
| author | DanConwayDev <DanConwayDev@protonmail.com> | 2025-12-23 13:55:34 +0000 |
|---|---|---|
| committer | DanConwayDev <DanConwayDev@protonmail.com> | 2025-12-23 13:55:34 +0000 |
| commit | 2ce9b2831e3af536f31491344abdf4b897f67a69 (patch) | |
| tree | 7836686c56ed087ac3be533e1e529de668fac406 /grasp-audit/src/specs/grasp01/git_clone.rs | |
| parent | a996defa7efd75dd9f1bbe921b6f49ac697672a0 (diff) | |
audit: updated grasp01 line refs to reflect purgatory insertion
Diffstat (limited to 'grasp-audit/src/specs/grasp01/git_clone.rs')
| -rw-r--r-- | grasp-audit/src/specs/grasp01/git_clone.rs | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/grasp-audit/src/specs/grasp01/git_clone.rs b/grasp-audit/src/specs/grasp01/git_clone.rs index 3d81964..e162558 100644 --- a/grasp-audit/src/specs/grasp01/git_clone.rs +++ b/grasp-audit/src/specs/grasp01/git_clone.rs | |||
| @@ -53,7 +53,7 @@ impl GitCloneTests { | |||
| 53 | Err(e) => { | 53 | Err(e) => { |
| 54 | return TestResult::new( | 54 | return TestResult::new( |
| 55 | test_name, | 55 | test_name, |
| 56 | "GRASP-01:git-http:28", | 56 | "GRASP-01:git-http:34", |
| 57 | "Repository must be cloneable via Git HTTP backend", | 57 | "Repository must be cloneable via Git HTTP backend", |
| 58 | ) | 58 | ) |
| 59 | .fail(format!("Failed to create repo fixture: {}", e)) | 59 | .fail(format!("Failed to create repo fixture: {}", e)) |
| @@ -86,7 +86,7 @@ impl GitCloneTests { | |||
| 86 | Err(e) => { | 86 | Err(e) => { |
| 87 | return TestResult::new( | 87 | return TestResult::new( |
| 88 | test_name, | 88 | test_name, |
| 89 | "GRASP-01:git-http:28", | 89 | "GRASP-01:git-http:34", |
| 90 | "Repository must be cloneable via Git HTTP backend", | 90 | "Repository must be cloneable via Git HTTP backend", |
| 91 | ) | 91 | ) |
| 92 | .fail(format!("Failed to convert pubkey to npub: {}", e)) | 92 | .fail(format!("Failed to convert pubkey to npub: {}", e)) |
| @@ -121,7 +121,7 @@ impl GitCloneTests { | |||
| 121 | cleanup(); | 121 | cleanup(); |
| 122 | return TestResult::new( | 122 | return TestResult::new( |
| 123 | test_name, | 123 | test_name, |
| 124 | "GRASP-01:git-http:28", | 124 | "GRASP-01:git-http:34", |
| 125 | "Repository must be cloneable via Git HTTP backend", | 125 | "Repository must be cloneable via Git HTTP backend", |
| 126 | ) | 126 | ) |
| 127 | .fail(format!("Failed to execute git clone: {}", e)); | 127 | .fail(format!("Failed to execute git clone: {}", e)); |
| @@ -133,7 +133,7 @@ impl GitCloneTests { | |||
| 133 | let stderr = String::from_utf8_lossy(&output.stderr); | 133 | let stderr = String::from_utf8_lossy(&output.stderr); |
| 134 | return TestResult::new( | 134 | return TestResult::new( |
| 135 | test_name, | 135 | test_name, |
| 136 | "GRASP-01:git-http:28", | 136 | "GRASP-01:git-http:34", |
| 137 | "Repository must be cloneable via Git HTTP backend", | 137 | "Repository must be cloneable via Git HTTP backend", |
| 138 | ) | 138 | ) |
| 139 | .fail(format!("Git clone failed: {}", stderr)); | 139 | .fail(format!("Git clone failed: {}", stderr)); |
| @@ -144,7 +144,7 @@ impl GitCloneTests { | |||
| 144 | cleanup(); | 144 | cleanup(); |
| 145 | return TestResult::new( | 145 | return TestResult::new( |
| 146 | test_name, | 146 | test_name, |
| 147 | "GRASP-01:git-http:28", | 147 | "GRASP-01:git-http:34", |
| 148 | "Repository must be cloneable via Git HTTP backend", | 148 | "Repository must be cloneable via Git HTTP backend", |
| 149 | ) | 149 | ) |
| 150 | .fail("Cloned repository missing .git directory"); | 150 | .fail("Cloned repository missing .git directory"); |
| @@ -153,7 +153,7 @@ impl GitCloneTests { | |||
| 153 | cleanup(); | 153 | cleanup(); |
| 154 | TestResult::new( | 154 | TestResult::new( |
| 155 | test_name, | 155 | test_name, |
| 156 | "GRASP-01:git-http:28", | 156 | "GRASP-01:git-http:34", |
| 157 | "Repository must be cloneable via Git HTTP backend", | 157 | "Repository must be cloneable via Git HTTP backend", |
| 158 | ) | 158 | ) |
| 159 | .pass() | 159 | .pass() |
| @@ -175,7 +175,7 @@ impl GitCloneTests { | |||
| 175 | Err(e) => { | 175 | Err(e) => { |
| 176 | return TestResult::new( | 176 | return TestResult::new( |
| 177 | test_name, | 177 | test_name, |
| 178 | "GRASP-01:git-http:28", | 178 | "GRASP-01:git-http:34", |
| 179 | "Clone URL must follow correct format", | 179 | "Clone URL must follow correct format", |
| 180 | ) | 180 | ) |
| 181 | .fail(format!("Failed to create repo fixture: {}", e)) | 181 | .fail(format!("Failed to create repo fixture: {}", e)) |
| @@ -203,7 +203,7 @@ impl GitCloneTests { | |||
| 203 | if !valid_url.contains(&npub) { | 203 | if !valid_url.contains(&npub) { |
| 204 | return TestResult::new( | 204 | return TestResult::new( |
| 205 | test_name, | 205 | test_name, |
| 206 | "GRASP-01:git-http:28", | 206 | "GRASP-01:git-http:34", |
| 207 | "Clone URL must follow correct format", | 207 | "Clone URL must follow correct format", |
| 208 | ) | 208 | ) |
| 209 | .fail("URL missing npub"); | 209 | .fail("URL missing npub"); |
| @@ -212,7 +212,7 @@ impl GitCloneTests { | |||
| 212 | if !valid_url.contains(&format!("{}.git", repo_id)) { | 212 | if !valid_url.contains(&format!("{}.git", repo_id)) { |
| 213 | return TestResult::new( | 213 | return TestResult::new( |
| 214 | test_name, | 214 | test_name, |
| 215 | "GRASP-01:git-http:28", | 215 | "GRASP-01:git-http:34", |
| 216 | "Clone URL must follow correct format", | 216 | "Clone URL must follow correct format", |
| 217 | ) | 217 | ) |
| 218 | .fail("URL missing repository identifier"); | 218 | .fail("URL missing repository identifier"); |
| @@ -241,7 +241,7 @@ impl GitCloneTests { | |||
| 241 | if output.status.success() { | 241 | if output.status.success() { |
| 242 | return TestResult::new( | 242 | return TestResult::new( |
| 243 | test_name, | 243 | test_name, |
| 244 | "GRASP-01:git-http:28", | 244 | "GRASP-01:git-http:34", |
| 245 | "Clone URL must follow correct format", | 245 | "Clone URL must follow correct format", |
| 246 | ) | 246 | ) |
| 247 | .fail("Invalid URL was accepted (should have been rejected)"); | 247 | .fail("Invalid URL was accepted (should have been rejected)"); |
| @@ -249,7 +249,7 @@ impl GitCloneTests { | |||
| 249 | 249 | ||
| 250 | TestResult::new( | 250 | TestResult::new( |
| 251 | test_name, | 251 | test_name, |
| 252 | "GRASP-01:git-http:28", | 252 | "GRASP-01:git-http:34", |
| 253 | "Clone URL must follow correct format", | 253 | "Clone URL must follow correct format", |
| 254 | ) | 254 | ) |
| 255 | .pass() | 255 | .pass() |
| @@ -278,7 +278,7 @@ impl GitCloneTests { | |||
| 278 | Err(e) => { | 278 | Err(e) => { |
| 279 | return TestResult::new( | 279 | return TestResult::new( |
| 280 | test_name, | 280 | test_name, |
| 281 | "GRASP-01:git-http:36", | 281 | "GRASP-01:git-http:42", |
| 282 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 282 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 283 | ) | 283 | ) |
| 284 | .fail(format!("Failed to create repo fixture: {}", e)) | 284 | .fail(format!("Failed to create repo fixture: {}", e)) |
| @@ -299,7 +299,7 @@ impl GitCloneTests { | |||
| 299 | None => { | 299 | None => { |
| 300 | return TestResult::new( | 300 | return TestResult::new( |
| 301 | test_name, | 301 | test_name, |
| 302 | "GRASP-01:git-http:36", | 302 | "GRASP-01:git-http:42", |
| 303 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 303 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 304 | ) | 304 | ) |
| 305 | .fail("Repository announcement missing d tag") | 305 | .fail("Repository announcement missing d tag") |
| @@ -311,7 +311,7 @@ impl GitCloneTests { | |||
| 311 | Err(e) => { | 311 | Err(e) => { |
| 312 | return TestResult::new( | 312 | return TestResult::new( |
| 313 | test_name, | 313 | test_name, |
| 314 | "GRASP-01:git-http:36", | 314 | "GRASP-01:git-http:42", |
| 315 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 315 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 316 | ) | 316 | ) |
| 317 | .fail(format!("Failed to convert pubkey to npub: {}", e)) | 317 | .fail(format!("Failed to convert pubkey to npub: {}", e)) |
| @@ -331,7 +331,7 @@ impl GitCloneTests { | |||
| 331 | Err(e) => { | 331 | Err(e) => { |
| 332 | return TestResult::new( | 332 | return TestResult::new( |
| 333 | test_name, | 333 | test_name, |
| 334 | "GRASP-01:git-http:36", | 334 | "GRASP-01:git-http:42", |
| 335 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 335 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 336 | ) | 336 | ) |
| 337 | .fail(format!("HTTP request failed: {}", e)) | 337 | .fail(format!("HTTP request failed: {}", e)) |
| @@ -341,7 +341,7 @@ impl GitCloneTests { | |||
| 341 | if !response.status().is_success() { | 341 | if !response.status().is_success() { |
| 342 | return TestResult::new( | 342 | return TestResult::new( |
| 343 | test_name, | 343 | test_name, |
| 344 | "GRASP-01:git-http:36", | 344 | "GRASP-01:git-http:42", |
| 345 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 345 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 346 | ) | 346 | ) |
| 347 | .fail(format!( | 347 | .fail(format!( |
| @@ -356,7 +356,7 @@ impl GitCloneTests { | |||
| 356 | Err(e) => { | 356 | Err(e) => { |
| 357 | return TestResult::new( | 357 | return TestResult::new( |
| 358 | test_name, | 358 | test_name, |
| 359 | "GRASP-01:git-http:36", | 359 | "GRASP-01:git-http:42", |
| 360 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 360 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 361 | ) | 361 | ) |
| 362 | .fail(format!("Failed to read response body: {}", e)) | 362 | .fail(format!("Failed to read response body: {}", e)) |
| @@ -370,7 +370,7 @@ impl GitCloneTests { | |||
| 370 | if !has_allow_reachable { | 370 | if !has_allow_reachable { |
| 371 | return TestResult::new( | 371 | return TestResult::new( |
| 372 | test_name, | 372 | test_name, |
| 373 | "GRASP-01:git-http:36", | 373 | "GRASP-01:git-http:42", |
| 374 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 374 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 375 | ) | 375 | ) |
| 376 | .fail("Missing capability: allow-reachable-sha1-in-want"); | 376 | .fail("Missing capability: allow-reachable-sha1-in-want"); |
| @@ -379,7 +379,7 @@ impl GitCloneTests { | |||
| 379 | if !has_allow_tip { | 379 | if !has_allow_tip { |
| 380 | return TestResult::new( | 380 | return TestResult::new( |
| 381 | test_name, | 381 | test_name, |
| 382 | "GRASP-01:git-http:36", | 382 | "GRASP-01:git-http:42", |
| 383 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 383 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 384 | ) | 384 | ) |
| 385 | .fail("Missing capability: allow-tip-sha1-in-want"); | 385 | .fail("Missing capability: allow-tip-sha1-in-want"); |
| @@ -387,7 +387,7 @@ impl GitCloneTests { | |||
| 387 | 387 | ||
| 388 | TestResult::new( | 388 | TestResult::new( |
| 389 | test_name, | 389 | test_name, |
| 390 | "GRASP-01:git-http:36", | 390 | "GRASP-01:git-http:42", |
| 391 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", | 391 | "MUST include allow-reachable-sha1-in-want and allow-tip-sha1-in-want in advertisement", |
| 392 | ) | 392 | ) |
| 393 | .pass() | 393 | .pass() |