Skip to content

SHA-1 hash bug with "Treat each line as a separate string" enabled #13812

@donho

Description

@donho

Description of the Issue

SHA-1 hash result should be 20 bytes (40 characters). However, when "Treat each line as a separate string" is enabled, SHA-1 hash result is 32 bytes (64 characters).

Steps to Reproduce the Issue

  1. Launch SHA-1 dialog via menu Tools->SHA-1->Generate...
  2. Check "Treat each line as a separate string" in the opened dialog.
  3. Type whatever.

Expected Behavior

20 bytes (40 characters) appears as SHA-1 hash result

Actual Behavior

32 bytes (64characters) appears as SHA-1 hash result (40 SHA-1 result with additional 24 times of '0' characters as suffix)

Debug Information

Notepad++ v8.5.4 (64-bit)
Build time : Jun 17 2023 - 20:42:45
Path : C:\Program Files\Notepad++\notepad++.exe
Command Line :
Admin mode : OFF
Local Conf mode : OFF
Cloud Config : OFF
OS Name : Windows 11 Home (64-bit)
OS Version : 22H2
OS Build : 22621.1848
Current ANSI codepage : 1252
Plugins :
mimeTools (2.9)
NppConverter (4.5)
NppExport (0.4)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions