mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-03-31 16:31:08 -07:00
Change formatting to prevent UI redressing attacks (#17611)
This commit is contained in:
committed by
GitHub
parent
6be42be575
commit
8b2b71c8ef
@@ -33,7 +33,7 @@ import {
|
||||
ShellProcessor,
|
||||
} from './prompt-processors/shellProcessor.js';
|
||||
import { AtFileProcessor } from './prompt-processors/atFileProcessor.js';
|
||||
import { sanitizeForListDisplay } from '../ui/utils/textUtils.js';
|
||||
import { sanitizeForDisplay } from '../ui/utils/textUtils.js';
|
||||
|
||||
interface CommandDirectory {
|
||||
path: string;
|
||||
@@ -248,7 +248,7 @@ export class FileCommandLoader implements ICommandLoader {
|
||||
const defaultDescription = `Custom command from ${path.basename(filePath)}`;
|
||||
let description = validDef.description || defaultDescription;
|
||||
|
||||
description = sanitizeForListDisplay(description, 100);
|
||||
description = sanitizeForDisplay(description, 100);
|
||||
|
||||
if (extensionName) {
|
||||
description = `[${extensionName}] ${description}`;
|
||||
|
||||
Reference in New Issue
Block a user