Adversarial Prompting
Adversarial prompting encompasses a range of techniques, including prompt injection, prompt leaking, prompt jailbreaking, and prompt poisoning, designed to exploit vulnerabilities in natural language processing or language model systems. These attacks manipulate input prompts to elicit harmful, unintended, or sensitive outputs from the models.
To mitigate adversarial prompting attacks, it is crucial to implement security measures and validation checks when accepting user-generated prompts or input. These measures may include content moderation, filtering, anomaly detection, careful tool permissions, and monitoring for malicious or inappropriate prompts.
Prompt Injections
A prompt injection attack is a security exploit that subtly manipulates or injects malicious prompts into a natural language processing or language model system. This manipulation can occur in ways a user may overlook, leading the model to generate harmful or unintended output.
Prompt Leaking
Prompt leaking occurs when a Large Language Model inadvertently discloses sensitive or private information embedded within its system prompts. This can include data used during training or fine-tuning, but also the complete system prompt, which may contain intellectual property.
Prompt Jailbreaking
Prompt jailbreaking involves crafting specific prompts to circumvent restrictions or safety measures implemented in language models. By using cleverly designed prompts, attackers can manipulate the model to generate prohibited, harmful, or inappropriate content.
Prompt Poisoning
Prompt poisoning corrupts the data a model relies on, such as training data, fine-tuning examples, retrieved documents, or context provided to the model, so it produces manipulated or malicious outputs across future interactions.
Adversarial prompting risk and impact scores
When evaluating various scenarios or injections, it is useful to categorize them with two distinct metrics:
- Risk score: RISK: HIGH RISK: MEDIUM RISK: LOW This score reflects the likelihood of the event occurring.
- Impact score: IMPACT: HIGH IMPACT: MEDIUM IMPACT: LOW This score assesses the potential consequences if the event does occur.
Each injection is tagged with these scores at the end of its title, providing a quick understanding of both its likelihood and potential impact.
These evaluations are subjective, based on personal analysis and reasoning, which is elaborated in the description conclusion. This dual-scoring approach offers a nuanced view of each scenario.
Adversarial prompt overview
No adversarial prompts found in this category.
Skill Poisoning
Agents are only as safe as the skills they learn. This page details 'Skill Poisoning,' a technique where attackers hide malicious prompts inside community-created AI plugins to hijack your agent's behavior and steal data.
Package Injection
When AI coding assistants hallucinate non-existent software libraries, hackers exploit the mistake. This article explains 'Package Hallucination' attacks, where adversaries register fake packages invented by LLMs to trick developers into installing malware.
Email Prompt Injection
When AI tools read your email, they inherit your access level. This article explains how attackers leverage 'Email Prompt Injection' to turn high-privilege users into unwitting accomplices, tricking their AI agents into retrieving and leaking restricted files.
Image and Document
Attackers can hide prompts within documents and images that are not visible to users.
Memory Manipulation
Since February 13, 2024, ChatGPT has been equipped with the ability to memorize what you've shared. This can be very useful as it allows ChatGPT to learn from what you share and use that information in later conversations.
Website redirect
When models search the internet, the user might run into adversarial prompts when websites have been infected.
ASCII Art-based
The ability to manipulate large language models (LLMs) like GPT-3.5, GPT-4, Gemini, Claude, and Llama2 using novel techniques has become a significant concern in AI safety. A recent study introduces a new form of prompt injection that utilizes ASCII art to bypass safety mechanisms, raising substantial risks and impacts.
Emoji jailbreak
Emoji jailbreak is a form of adversarial prompting that uses emojis to manipulate the output of a language model. It is a form of prompt jailbreaking that uses emojis to inject malicious or unintended prompts into the output of a language model.
Many-shot
Read more about many-shot prompt jailbreaking
Custom GPT
Be aware that storing data in CustomGPT's (OpenAI's platform) can be a risk to your data.
ChatGPT Query Injection
ChatGPT provides a convenient feature that allows users to prefill a prompt directly via a URL using the q parameter — for example: chatgpt.com?q=[yourQuery]. Test it on desktop, by clicking on this link (safe): https://chatgpt.com/?q=How%20are%20you?
Read more
The three phases
CRAFT
Craft (write) the prompt with the following elements: Context, Register, Acting Role, Format, and Task.
ING
Validate the prompt and ensure it maintains an interactive approach. Keep in mind the importance of non-disclosure and staying goal-driven throughout the process.
AI
Continuously assess and refine the output based on the prompts output to improve the overall quality.