/** * Copyright (c) 2025 Ofri Peretz * Licensed under the MIT License. Use of this source code is governed by the * MIT license that can be found in the LICENSE file. */ /** * ESLint Rule: no-ecb-mode * Detects use of ECB encryption mode which leaks data patterns * CWE-327: ECB mode encrypts identical blocks identically * * @see https://blog.cloudflare.com/why-are-some-images-more-secure-than-others/ */ import type { TSESLint } from '@interlace/eslint-devkit'; type MessageIds = 'ecbMode' | 'useGcm' | 'useCbc'; export interface Options { /** Allow ECB in test files. Default: false */ allowInTests?: boolean; } type RuleOptions = [Options?]; export declare const noEcbMode: TSESLint.RuleModule & { name: string; }; export type { Options as NoEcbModeOptions };