0

Windows Notepad has a limit: 1024 symbols - max string length.
Download link: https://krakenfiles.com/view/uID2gzKW7K/file.html (189 KB)
How to find this value to increase or remove? Where is it located? Please help.

It is a question about reversing, not about other programs to use instead.

Update:
With suggested in the answer, I found the check after which a forced line break is made (it is COMCTL32.dll+C6E44), increased the limit using code injection, but the text goes out of the field and the scrollbar doesn't work for it. Please help.

6
  • Where did you get that length? From what I know the recent version of notepad has a limitation of 2GB file.
    – SuperUser
    Commented Jun 1 at 7:30
  • @SuperUser After this length, a forced line break is made. And it was discussed several times by users.
    – oleedd
    Commented Jun 1 at 9:30
  • Yeah I know, thanks for the clarification.
    – SuperUser
    Commented Jun 1 at 14:05
  • @SuperUser Please help to find it. I need to learn how to do such tasks.
    – oleedd
    Commented Jun 1 at 16:38
  • 2
    I think this limit may be part of the multiline edit control that Notepad used. For example, archived Microsoft Knowledge Base article Q74225 says "A multiline edit control is also subject to the following limitations: The maximum number of characters in a single line is 1024." If you want to attempt to fix it, you may need to investigate the part of the OS that provides the multiline edit control.
    – Bavi_H
    Commented Jun 4 at 6:48

1 Answer 1

1
  • Install cheat engine
  • Scan for the number of char on the line, add or remove a couple of characters and press next scan with the new number of character on the line
  • Once you have one value left, right click find out what access this address and look for a cmp instruction

You can either change the conditional jmp or the value its comparing to.

4
  • I managed to increase the limit with this, but the text goes out of the field and the scrollbar doesn't work for it. Please help.
    – oleedd
    Commented Jun 4 at 14:56
  • @Lumira I tried that, it's not that simple. see Bavi_H comment.
    – SuperUser
    Commented Jun 4 at 19:26
  • @oleedd: of course it doesn't. The check is there to prevent a buffer overflow. Commented Jun 24 at 0:54
  • @got Maybe there is a scrollbar check for 1024. But I didn't find it for this string length value.
    – oleedd
    Commented Jun 25 at 21:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.