Bug 1645886 - chntpw fails to read any files
Summary: chntpw fails to read any files
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Fedora
Classification: Fedora
Component: chntpw
Version: 29
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Conrad Meyer
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
: 1701597 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2018-11-04 16:56 UTC by Jia Yuan Lo
Modified: 2019-07-13 01:24 UTC (History)
6 users (show)

Fixed In Version: chntpw-1.00-4.140201.fc30 chntpw-1.00-4.140201.fc29
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-07-13 01:06:17 UTC
Type: Bug


Attachments (Terms of Use)
Patch of reading Hive (648 bytes, patch)
2019-06-22 15:20 UTC, Oleg Samarin
no flags Details | Diff

Description Jia Yuan Lo 2018-11-04 16:56:46 UTC
Description of problem:
chntpw fails to read anything, be it Windows SAM files or any files

Version-Release number of selected component (if applicable): 1.00.140201

How reproducible: Always

Steps to Reproduce:
1. cd /path/to/SYSTEM
2. chntpw -e SYSTEM
3. fail to read file

Actual results (any files):
chntpw version 1.00 140201, (c) Petter N Hagen
openHive(): read error: : No such file or directory
chntpw: Unable to open/read a hive, exiting..


Expected results (SAM files):
chntpw version 0.99.6 110511 , (c) Petter N Hagen
Hive </path/to/SYSTEM> name (from header): <SYSTEM>
ROOT KEY at offset: 0x001020 * Subkey indexing type is: 686c <lh>
File size 18350080 [1180000] bytes, containing 3917 pages (+ 1 headerpage)
Used for data: 280256/18177568 blocks/bytes, unused: 140/22592 blocks/bytes.

Simple registry editor. ? for help.

> 


Expected results (other files):
chntpw version 0.99.6 110511 , (c) Petter N Hagen
openHive(/home/jylo/.bash_history): File does not seem to be a registry hive!
Simple registry editor. ? for help.
get_abs_path: Not a 'nk' node!

> 


Additional info:
0.99 still works fine for reading win10-1803, but not 1.00...

Note that chntpw can tell the difference between a folder and a file, but can't seem to read ANY file...

Comment 1 Emmanuel Franquemagne 2018-12-17 23:42:47 UTC
Exactly the same issue.

Comment 2 Conrad Meyer 2019-04-19 20:00:42 UTC
*** Bug 1701597 has been marked as a duplicate of this bug. ***

Comment 3 Oleg Samarin 2019-06-22 15:20:28 UTC
Created attachment 1583483 [details]
Patch of reading Hive

Please try this patch. It is working for me

Comment 4 Conrad Meyer 2019-06-22 20:19:58 UTC
Thanks for pointing out the problem Oleg.  I see the mistake now.  I think I would do something slightly different and also check for r == 0, but the patch looks mostly good to me.

Comment 5 Conrad Meyer 2019-06-22 20:24:28 UTC
Rawhide: https://koji.fedoraproject.org/koji/taskinfo?taskID=35735984

Comment 7 Fedora Update System 2019-06-22 21:16:24 UTC
FEDORA-2019-03f92e73ee has been submitted as an update to Fedora 30. https://bodhi.fedoraproject.org/updates/FEDORA-2019-03f92e73ee

Comment 8 Fedora Update System 2019-06-23 00:55:23 UTC
chntpw-1.00-4.140201.fc30 has been pushed to the Fedora 30 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-03f92e73ee

Comment 9 Fedora Update System 2019-06-23 11:45:38 UTC
chntpw-1.00-4.140201.fc29 has been pushed to the Fedora 29 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2019-b2e5df19a8

Comment 10 Oleg Samarin 2019-06-27 06:27:14 UTC
Conrad, I couldn't find the sourcecode repository of chntpw. Where is it?

Comment 11 Conrad Meyer 2019-06-27 06:46:12 UTC
Oleg, I don’t know of one.

Comment 12 Conrad Meyer 2019-06-27 06:50:28 UTC
Or do you mean the rpm spec repository? That’s here: https://src.fedoraproject.org/rpms/chntpw/commits/master

Comment 13 Fedora Update System 2019-07-13 01:06:17 UTC
chntpw-1.00-4.140201.fc30 has been pushed to the Fedora 30 stable repository. If problems still persist, please make note of it in this bug report.

Comment 14 Fedora Update System 2019-07-13 01:24:03 UTC
chntpw-1.00-4.140201.fc29 has been pushed to the Fedora 29 stable repository. If problems still persist, please make note of it in this bug report.


Note You need to log in before you can comment on or make changes to this bug.