shield-llm 0.3.1 → 0.4.0

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.
package/dist/cli.js CHANGED
@@ -17,13 +17,16 @@ import {
17
17
  generatePdf,
18
18
  loadConfig,
19
19
  loadSystemPrompt
20
- } from "./chunk-NCPHRVFO.js";
20
+ } from "./chunk-DVOKN4JV.js";
21
21
  import "./chunk-WM5Z3SXV.js";
22
22
 
23
23
  // src/cli.ts
24
24
  import "dotenv/config";
25
25
  import { Command, CommanderError } from "commander";
26
26
 
27
+ // package.json
28
+ var version = "0.4.0";
29
+
27
30
  // src/credentials.ts
28
31
  import {
29
32
  readFileSync,
@@ -1265,9 +1268,8 @@ async function testConnectionCommand(opts) {
1265
1268
  const target = buildTargetConfig(config);
1266
1269
  const systemPrompt = loadSystemPrompt(config);
1267
1270
  const message = opts.message ?? DEFAULT_MESSAGE;
1268
- const where = target.mode === "endpoint" ? target.url : `${target.provider}/${target.model ?? "default"}`;
1269
- console.log(`Target: ${where}`);
1270
- if (target.mode === "endpoint" && target.request.encoding) {
1271
+ console.log(`Target: ${target.url}`);
1272
+ if (target.request.encoding) {
1271
1273
  console.log(`Encoding: ${target.request.encoding}`);
1272
1274
  }
1273
1275
  console.log(`Sending benign test message: "${message}"
@@ -1413,7 +1415,7 @@ process.on("uncaughtException", (err) => {
1413
1415
  });
1414
1416
  var program = new Command();
1415
1417
  program.exitOverride();
1416
- program.name("shield-llm").description("AI chatbot security scanner \u2014 automated red teaming for LLMs").version("0.3.1");
1418
+ program.name("shield-llm").description("AI chatbot security scanner \u2014 automated red teaming for LLMs").version(version);
1417
1419
  program.command("scan").description("Run a security scan against a target chatbot").option("-c, --config <path>", "Path to shield.config.json").option("-e, --endpoint <url>", "Target chatbot HTTP endpoint URL").option("--auth <type>", "Auth type: bearer, api-key, oauth2").option("--token <value>", "Bearer token or API key value").option("--auth-header <name>", "Custom auth header name (for api-key auth)").option(
1418
1420
  "--response-field <path>",
1419
1421
  "Dot-notation path to response text in JSON (default: response)"
package/dist/index.js CHANGED
@@ -9,7 +9,7 @@ import {
9
9
  generatePdf,
10
10
  loadConfig,
11
11
  loadSystemPrompt
12
- } from "./chunk-NCPHRVFO.js";
12
+ } from "./chunk-DVOKN4JV.js";
13
13
  import "./chunk-WM5Z3SXV.js";
14
14
  export {
15
15
  ConfigError,
package/dist/logo.png ADDED
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shield-llm",
3
- "version": "0.3.1",
3
+ "version": "0.4.0",
4
4
  "description": "AI chatbot security scanner — automated red teaming for LLMs",
5
5
  "type": "module",
6
6
  "publishConfig": {
@@ -41,7 +41,7 @@
41
41
  "url": "https://github.com/sami-essouri/shield-ai/issues"
42
42
  },
43
43
  "scripts": {
44
- "build": "tsup && cp src/reporters/report-template.hbs dist/",
44
+ "build": "tsup && cp src/reporters/assets/logo.png dist/",
45
45
  "dev": "tsx src/cli.ts",
46
46
  "test": "vitest run --exclude src/integration.test.ts",
47
47
  "test:integration": "vitest run src/integration.test.ts",
@@ -54,12 +54,16 @@
54
54
  "chalk": "^5.3.0",
55
55
  "commander": "^12.0.0",
56
56
  "dotenv": "^17.2.3",
57
- "handlebars": "^4.7.9",
58
57
  "ora": "^8.0.0",
59
58
  "zod": "^3.23.0"
60
59
  },
61
- "optionalDependencies": {
62
- "puppeteer": "^24.2.0"
60
+ "peerDependencies": {
61
+ "puppeteer": ">=24"
62
+ },
63
+ "peerDependenciesMeta": {
64
+ "puppeteer": {
65
+ "optional": true
66
+ }
63
67
  },
64
68
  "devDependencies": {
65
69
  "@shield-llm/scanner-core": "workspace:*",
@@ -67,6 +71,7 @@
67
71
  "@types/express": "^5.0.6",
68
72
  "@types/node": "^20.19.30",
69
73
  "express": "^5.2.1",
74
+ "puppeteer": "^24.2.0",
70
75
  "tsup": "^8.0.0",
71
76
  "tsx": "^4.0.0",
72
77
  "typescript": "^5.0.0",