@http-forge/core 0.2.7 → 0.2.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -36,6 +36,10 @@ export declare class RequestScriptSession implements IRequestScriptSession {
36
36
  private _globals;
37
37
  private _sessionVariables;
38
38
  private _environmentVariables;
39
+ private _liveEnvironmentScope;
40
+ private _liveSessionScope;
41
+ private _liveGlobalsScope;
42
+ private _liveCollectionScope;
39
43
  private _nextRequest;
40
44
  private _skipRequest;
41
45
  private _visualizerData;
@@ -0,0 +1,43 @@
1
+ /**
2
+ * Sensitive Data Redactor
3
+ *
4
+ * Prevents tokens, passwords, credentials, and other sensitive data from being
5
+ * persisted in history files, result files, and shared-history files.
6
+ *
7
+ * Uses pattern-based auto-detection on:
8
+ * - HTTP header names (Authorization, Cookie, Set-Cookie, etc.)
9
+ * - URL query parameter names (token, key, secret, etc.)
10
+ * - JSON/form body field names (password, client_secret, api_key, etc.)
11
+ */
12
+ import { FullResponse, HistoryEntry } from '../history/history-interfaces';
13
+ import { FullResultDetails } from '../test-suite/result-storage';
14
+ /**
15
+ * Redact values from a headers object.
16
+ * Returns a shallow copy with sensitive header values replaced.
17
+ */
18
+ export declare function redactHeaders(headers: Record<string, string | string[]>): Record<string, string | string[]>;
19
+ /**
20
+ * Redact sensitive query parameters from a URL string.
21
+ * E.g. `?token=abc&name=foo` → `?token=[REDACTED]&name=foo`
22
+ */
23
+ export declare function redactUrl(url: string): string;
24
+ /**
25
+ * Redact sensitive data from a request body.
26
+ * Handles JSON objects, JSON strings, and URL-encoded form strings.
27
+ */
28
+ export declare function redactBody(body: any): any;
29
+ /**
30
+ * Redact sensitive data from a HistoryEntry's sentRequest.
31
+ * Returns a deep copy with sensitive values replaced.
32
+ * The originalConfig (unresolved templates) is left untouched.
33
+ */
34
+ export declare function redactHistoryEntry(entry: HistoryEntry): HistoryEntry;
35
+ /**
36
+ * Redact sensitive data from a FullResponse (response headers and cookies).
37
+ * Response body is NOT redacted (too varied to pattern-match safely).
38
+ */
39
+ export declare function redactFullResponse(response: FullResponse): FullResponse;
40
+ /**
41
+ * Redact sensitive data from a FullResultDetails (suite test result).
42
+ */
43
+ export declare function redactFullResultDetails(result: FullResultDetails): FullResultDetails;
@@ -7,8 +7,8 @@
7
7
  * - Aggregated stats in memory (constant size)
8
8
  * - On-demand result loading
9
9
  */
10
- import { IConfigService } from '../config';
11
10
  import { ExecutionResult } from '../../types/types';
11
+ import { IConfigService } from '../config';
12
12
  import { FullResultDetails, IndexPage, IResultStorageService, RecentError, RequestStats, ResultSummary, RunConfig, RunManifest, RunStats } from './result-storage';
13
13
  /**
14
14
  * File-based Result Storage Service for Test Suite
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@http-forge/core",
3
- "version": "0.2.7",
3
+ "version": "0.2.8",
4
4
  "description": "Headless HTTP testing engine with Postman collection support, dynamic variables, and script-based automation.",
5
5
  "main": "./dist/index.js",
6
6
  "module": "./dist/index.mjs",