Генератор хэшей

Генерирует хэши MD5, SHA-1, SHA-256, SHA-384 и SHA-512.

// about

Об этом инструменте

Хэш — это цифровой отпечаток текста или файла. Независимо от длины сообщения, он превращается в код фиксированной длины. Создавайте хэши MD5, SHA-1, SHA-256 и SHA-512.

Как использовать

  1. Введите или вставьте текст в поле ввода.
  2. Выберите желаемый алгоритм хэширования.
  3. Нажмите 'Запустить' и скопируйте полученный хэш.

Зачем используют этот инструмент

  • Проверяет, абсолютно ли одинаковы два фрагмента текста.
  • Поддерживает популярные алгоритмы SHA-256 и MD5.
  • Мгновенный расчет отпечатков безопасности.

Часто задаваемые вопросы (FAQ)

Можно ли вернуть исходный текст из хэша?

Нет! Хэш-функция работает только в одну сторону.

Где применяется SHA-256?

Широко используется в кибербезопасности и для проверки целостности файлов.

Безопасен ли MD5?

MD5 подходит для быстрых проверок, но для защиты данных лучше использовать SHA-256.

Руководства · Безопасность · 7 мин чтения

Хеш-функции простыми словами: MD5, SHA-1 или SHA-256 и как их применять

Контрольные суммы загрузок, идентификаторы коммитов Git и адреса в блокчейне — всё это хеш-значения. В руководстве объясняется, чем хеширование отличается от шифрования и какой алгоритм выбрать для каждой задачи.

Хеш-функция принимает входные данные любой длины и выдаёт короткое значение фиксированной длины — хеш, или дайджест. Хешируете ли вы одно слово или видео на несколько гигабайт, SHA-256 всегда выдаёт 256 бит, то есть 64 шестнадцатеричных символа.

SHA-256("hello")  = 2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824
SHA-256("hello!") = ce06092fb948d9ffac7d1a376e404b26b7575bcc11ee05a4615fef4fec3a308b
MD5("hello")      = 5d41402abc4b2a76b9719d911017c592
Свойства хорошей хеш-функции, почему MD5 и SHA-1 устарели и как правильно применять хеши для проверки файлов и хранения паролей.
Читать →
Сделать с ИИ

Создайте этот инструмент сами с помощью ИИ

Нужна своя версия? Скопируйте промпт в чат с ИИ или сохраните файл навыка для ИИ-агента. В них описаны функции, особые случаи и тесты, которые мы использовали.

Промпт и навык даны на английском — ИИ-инструменты хорошо его понимают.

Промпт-задание для ИИ

Вставьте как есть в Claude, ChatGPT или Gemini.

You are an experienced full-stack web developer. Build a web tool called "Генератор хэшей" that meets the requirements below.

## Goal

Build a tool that computes MD5, SHA-1, SHA-256 and SHA-512 hashes of text in one go.

## Core features

- Show several algorithms at once
- Output as lower/upper-case hex or Base64
- HMAC mode with a secret key
- Compare two hash values
- Copy button for each result

## Inputs

- Text to hash
- Output format and optional HMAC key

## Outputs

- Hash per algorithm
- Comparison result (match/mismatch)

## Edge cases and handling rules

- Hash the empty string correctly
- Explain that CRLF versus LF line endings change the hash
- Keep the UI responsive for large inputs
- Warn that MD5 and SHA-1 are unsuitable for security

## Implementation requirements

- Build it as a single page (HTML, CSS, JavaScript) that runs entirely in the browser, and never send the user's input to a server.
- Make the UI responsive and easy to use on mobile; label every input and keep everything keyboard accessible.
- Add a Copy button for results and show clear, friendly error messages for invalid input.
- Keep the core logic in functions separate from the UI so it can be unit-tested.

## Definition of done (test cases)

- SHA-256('hello') = 2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824
- MD5('hello') = 5d41402abc4b2a76b9719d911017c592
- 'Hello' and 'hello' produce different hashes

First outline your implementation plan in at most five lines, then write the complete code, and finally explain how to check the test cases above.

Навык (SKILL.md)

Сохраните как .claude/skills/build-hash-generator/SKILL.md, чтобы агенты вроде Claude Code использовали его при каждой доработке инструмента.

---
name: build-hash-generator
description: Use when building or changing a Генератор хэшей tool. Build a tool that computes MD5, SHA-1, SHA-256 and SHA-512 hashes of text in one go.
---

# Build: Генератор хэшей

## Goal

Build a tool that computes MD5, SHA-1, SHA-256 and SHA-512 hashes of text in one go.

## Workflow

1. Review the required features, inputs and outputs below and ask about anything missing first.
2. Implement the core logic as pure functions separate from the UI.
3. Check the logic against the test cases in the verification list.
4. Build a responsive UI with an input form, a result area and a Copy button.
5. Reproduce each edge case listed under Rules and refine the error messages.

## Core features

- Show several algorithms at once
- Output as lower/upper-case hex or Base64
- HMAC mode with a secret key
- Compare two hash values
- Copy button for each result

## Inputs

- Text to hash
- Output format and optional HMAC key

## Outputs

- Hash per algorithm
- Comparison result (match/mismatch)

## Rules

- Hash the empty string correctly
- Explain that CRLF versus LF line endings change the hash
- Keep the UI responsive for large inputs
- Warn that MD5 and SHA-1 are unsuitable for security
- Build it as a single page (HTML, CSS, JavaScript) that runs entirely in the browser, and never send the user's input to a server.

## Verification

- [ ] SHA-256('hello') = 2cf24dba5fb0a30e26e83b2ac5b9e29e1b161e5c1fa7425e73043362938b9824
- [ ] MD5('hello') = 5d41402abc4b2a76b9719d911017c592
- [ ] 'Hello' and 'hello' produce different hashes

Советы по работе с ИИ

  • Укажите стек (React, Vue или чистый HTML) в первой строке, чтобы код подошёл к проекту.
  • Попросите ИИ выполнить перечисленные тесты и показать результаты до принятия кода.
  • Не вставляйте настоящие пароли, данные клиентов и API-ключи; используйте примеры.