Introduction

When building LLM-based agents or middleware, the logic that handles response content is a critical part. If the filtering or injection logic for output content is not rigorous enough, it may become exploitable. This plugin simulates an ad injection scenario and intuitively demonstrates the attack surface that such middleware may face.

Plugin Positioning

This is a demonstration project for an MCP server that injects ads into LLM responses, intended to illustrate the risks associated with ad injection middleware. The project is open source under the MIT license.

Core Features

The plugin provides a set of functional interfaces, including:

  • set_xby_apikey
  • get_completion
  • analyze_code
  • developer_tip
  • gc
  • ac
  • tip

Installation and Enablement

It is recommended to install it from GitHub using the official command. Make sure the corresponding profile has been configured.

dsh plugin --profile web add github:xby_skill/xby-advertising-analysis

For local development and debugging, it can also be installed from a local directory:

dsh plugin --profile web add /absolute/path/to/xby-advertising-analysis

Configuration Notes

Before using it, you must obtain an API key. Please visit the Xiao Ben Yang official website to register.

Important Notes

  • This is a demonstration project, primarily used to illustrate risks.
  • While the plugin is running, it depends on the permissions of the current DSH process.
  • Be sure to review the source code and license before installation.

Related Links