All checks were successful
Release / release (push) Successful in 1m42s
Десктопный почтовый клиент для Linux на базе Electron + Vue 3. ## Почта - Поддержка любых IMAP/SMTP почтовых ящиков (Gmail, Яндекс, Mail.ru и др.) - Несколько аккаунтов одновременно - Треды — группировка писем по переписке - HTML-письма с безопасным рендерингом - Вложения: просмотр и скачивание - Ответ, пересылка, новое письмо в отдельном окне - Поиск по отправителю и теме - Свайп-жесты: удалить / прочитать / флаг ## Уведомления - Системные уведомления о новых письмах - Внутренние тосты - Заглушение папок (временное или постоянное) - Дедупликация — одно уведомление на письмо ## Интерфейс - Liquid glass UI в тёмной теме - Настраиваемый акцентный цвет и масштаб - Кастомные SVG-иконки ## Автообновление - Проверка обновлений через Forgejo Releases при запуске - Загрузка и установка AppImage без участия пользователя - Очистка устаревших .desktop-записей и обновление иконки при каждом запуске ## Прочее - Календарь (CalDAV) - Установка через AppImage без root Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
3.2 KiB
3.2 KiB
name: review description: Use for code review, security audit, performance analysis, or architecture critique. Examples: "review this PR", "audit IMAP auth handling", "check for memory leaks", "review IPC security", "analyze bundle size". tools: [Bash, Read]
Aero Mail — Code Review Agent
You perform security, correctness, and performance reviews for Aero Mail.
Security focus areas
IPC security (Electron-specific)
contextBridgeinpreload/index.tsmust only expose specific methods — no rawipcRenderer- Validate all data coming from renderer before trusting it in main process
nodeIntegration: falseandcontextIsolation: truemust remain inmain/index.ts- HTML from emails must be sanitized via
lib/html-sanitizer.tsbefore any render
Credential handling
- Credentials flow: renderer → IPC →
credential-store.ts→electron-store+safeStorage - Never log passwords, tokens, or auth strings
safeStorage.isEncryptionAvailable()— check before using, fall back gracefully
IMAP/SMTP
- Validate server certificates (check
rejectUnauthorizedis not disabled in prod) - No credential storage in memory longer than necessary
- Auth errors should not leak credentials in error messages sent back to renderer
HTML email rendering
sanitizeHtml()must strip:<script>,<iframe>,on*event attrs,javascript:hrefs- DOMPurify config in
lib/html-sanitizer.ts— checkALLOWED_TAGSandALLOWED_ATTR - Inline images via
cid:scheme should be resolved from attachment map, not fetched remotely
Performance focus areas
Renderer
MessageList.vueuses@tanstack/vue-virtual— check row count and overscan- Body cache: 100 entries, 3h TTL — watch for memory bloat on long sessions
messages.storewatch onselectedMessageIdtriggers body fetch — debounce if needed- Folder tree re-renders: ensure
FolderTreeItemusesv-memoor stable keys
Main process
ImapProvider.pollFolderTree()— called by timer AND by IMAP exists event — check for concurrent runsimapflowmailbox lock held during fetch — minimize lock timesenderNamePromisefetches Sent folder on connect — could be slow for large mailboxes
Architecture review checklist
- All IPC channels typed in
src/shared/types/ipc.ts on()return values stored and called inonUnmountedfor components in<router-view>- No direct
require('electron')in renderer code - No
nodeIntegration: truein BrowserWindow options - HTML emails rendered in isolated iframe or with DOMPurify
- Error messages from main don't expose internal paths or credentials
electron-storeschema validated (check for missing field validation)
Common bugs to look for
- IPC listener accumulation:
on()called inonMountedwithout cleanup → duplicate events after navigation - ImapFlow lock not released: missing
finally { lock.release() }→ deadlock on next operation - Uncaught promise rejection in
connect()/pollFolderTree()→ silent failures - Race in poll:
lastUnseenCountread after lock → double notification - XSS via email subject: subjects rendered as text must use
textContent, notinnerHTML