Commit Graph

455 Commits

Author SHA1 Message Date
PartialVolume
1220eca2ef Place a space between temperature and model
eg [36C] ST3500... and not [36C]ST3500..
2023-11-29 22:21:01 +00:00
PartialVolume
cca93f845d Fix the config help messages
Some of the help messages that show the
purpose of the keys were inconsistent or
not updated when going back. Now fixed.
2023-11-29 19:40:47 +00:00
PartialVolume
c24e248055 Make smart page titles consistent with page 1
Should now read
Page 1 - Erasure Status
Page 2 - Smart Data
Page 3 - Smart Data

and not as previously
Page 1 - Erasure Status
Smart Data - Page 2
Smart Data - Page 3
2023-11-28 21:21:48 +00:00
PartialVolume
626ca3826c Fix nwipe not auto exiting on completion in non gui mode. 2023-11-27 23:39:50 +00:00
PartialVolume
f61b593093 Merge pull request #529 from PartialVolume/Fix_autopoweroff_and_nowait_when_screen_blank
Fix autopoweroff and nowait when screen blank
2023-11-24 01:14:31 +00:00
PartialVolume
7f39d81548 Fix autopoweroff and nowait when screen blank
If the user had blanked the screen, the autopoweroff
and nowait options did not work. Instead they paused
nwipe on completion of the wipe/s waiting for the b
key to be pressed which reactivated compute_stats()
function who's output indicates whether any wipes were
still active.

This was fixed so that compute_stats() is always
active while wipes are in progress, so that the
nwipe_gui_status() function will exit when all wipe
threads have completed even if the screen has been
blanked.
2023-11-24 01:06:29 +00:00
Gerold Gruber
811c36b65a again garbage after serial number 2023-11-20 00:14:05 +01:00
PartialVolume
2ff23eb02c Update version.c
Bump minor version from 0.35 to 0.35.1
2023-11-17 12:04:48 +00:00
PartialVolume
7a4709da55 Merge pull request #526 from PartialVolume/Identify_mmcblk_devices
Added mmcblk device type MMC

Changed log message from "USB bridge, no pass-through support" to "Smart data unavailable" as no smart data could be caused by a non USB device such as mmcblk as well as USB devices with no ATA pass through and other devices that smartctl does not detect.
2023-11-16 20:00:13 +00:00
PartialVolume
9ee5193673 Added mmcblk device type MMC
Added the abbreviation MMC for mmcblk devices such as SD and
microSD cards and some low budget laptops.

Changed log message from "USB bridge, no pass-through support"
to "Smart data unavailable" as no smart data could be caused by
a non USB device such as mmcblk as well as USB devices with no ATA
pass through and other devices that smartctl does not detect.
2023-11-16 19:35:07 +00:00
Gerold Gruber
470672bc3a modified disk sorting for more than 26 disks 2023-11-05 02:02:39 +01:00
PartialVolume
d14c3da26b Merge pull request #520 from xambroz/patch-4
move the include of time.h
2023-11-04 21:29:34 +00:00
PartialVolume
2abe4975f2 Merge pull request #516 from xambroz/patch-2
move the define off64_t
2023-11-04 21:10:00 +00:00
Gerold Gruber
e77164f710 fix MAX_NUMBER_EXCLUDED_DRIVES, handle exceeding the limit, +README.md 2023-11-04 21:14:05 +01:00
Michal Ambroz
4747ce65c6 move the include of time.h
The definition of the newly used _POSIX_SOURCE affects preprocessing of the time.h. As result on RHEL7 (possibly 6 as well) the timespec structure is not defined.
2023-11-04 15:59:38 +01:00
Gerold Gruber
28a9c70abc formatting fix 2023-11-04 13:55:11 +01:00
Gerold Gruber
2ac6ebe7ea progress dots added 2023-11-04 13:53:26 +01:00
Michal Ambroz
398b03a11a move the define off64_t
Move the definition of the off64_t using int64_t  bellow the include stdint.h, which is actually defining it.

Without change wrong order is breaking the build on RHEL7/8/9.
2023-11-03 22:47:29 +01:00
PartialVolume
edfd982037 Add_check_for_root_execution 2023-11-02 20:14:52 +00:00
PartialVolume
499ad925ae Fix_segfault_on_first_run_as_non_root
Incorrectly trying to close a uninitialised file
pointer stream when the file could not be opened.
2023-11-02 19:47:53 +00:00
PartialVolume
1b37bcef84 Merge pull request #510 from PartialVolume/Bump_version_to_0.35
Bump version to 0.35
2023-11-01 20:13:48 +00:00
PartialVolume
f3179cf748 Bump version to 0.35 2023-11-01 20:07:33 +00:00
PartialVolume
1b9a376186 Create_PDF_Certificate_Group
The code that handles nwipe.conf now checks
an existing nwipe.conf for the correct default
groups. This allows future additions to the
nwipe.conf file to be added to an existing nwipe.conf
file. This makes the code more robust.

The code that handles creation of groups, settings and
values has been made into a function so any future additions
to nwipe.conf can be added with a single call to this function.

i.e
nwipe_conf_populate( "Default_Wipe.Method", "PRNG" );

The code can now handle creation of groups to a arbitrary
depth of four levels, however currently we only use a
group depth of 1.

i.e
CCC :
{
 XXX :
 {
   YYY :
   {
     ZZZ :
     {
     };
     TTT :
     {
     };
   };
 };
};
2023-11-01 19:39:43 +00:00
PartialVolume
26ae763379 Fix_warning_directive_output_may_be_truncated
Fixed the following warning:

create_pdf.c:795:18: warning: ‘/nwipe_report_’ directive
output may be truncated writing 14 bytes into a region of
size between 1 and 4096 [-Wformat-truncation=]
2023-10-24 20:22:23 +01:00
PartialVolume
8ce7b077bf Fix_message_creating_PDF_in
The message that displays where the nwipe PDF certificate
is being saved was being printed multiple times in the
middle of the erasure summary table.

This was corrected so that it only prints once at the end
of the table.
2023-10-23 22:08:23 +01:00
PartialVolume
603716e990 Merge pull request #505 from ggruber/master
sort the device list
2023-10-22 00:47:07 +01:00
PartialVolume
7fb2a77c7a Merge pull request #506 from PartialVolume/temperature_thread
Temperature Thread
2023-10-22 00:45:59 +01:00
PartialVolume
28068ebf97 Temperature Thread
Due to significant delays in obtaining drive temperature
from some drives especially SAS which was causing a noticeable
freeze of a second or two or more in the GUI wipe status
screen, being made worse the more drives that were being
simultaneously wiped.

The temperature update code was separated from the GUI code
by placing the temperature update in it's own thread.
2023-10-22 00:25:01 +01:00
Gerold Gruber
539a023fd7 sort the device list 2023-10-20 18:43:46 +02:00
Gerold Gruber
dcef86fb0b fixed min/max wrong set 2023-10-20 00:56:35 +02:00
PartialVolume
1ee1bb1966 Fix_temperature_colour_part2
Reverted change in wprintw_temperature()
as that was not causing the red temperature
character.
2023-10-17 19:38:22 +01:00
PartialVolume
c02dbe42ce Fix red text on temperature
This was due to incorrectly changing temperature
colour based on historical highest and lowest values.

Also removed some debug nwipe_log code
2023-10-17 18:03:39 +01:00
PartialVolume
7ce28ce61a Merge pull request #498 from ggruber/master
improved SCSI disk handling
2023-10-17 12:43:39 +01:00
PartialVolume
725c79b9d0 Change_HPA_message_to_stop_flashing_&_move_to_end_of_line
The HPA message alternating with the drive model serial
number made reading the serial number quite a challenge
and made the display far too messy looking when displaying
20+ drives or even 10+ drives with differing HPA statuses.

Removed, alternating appearance.
Reduced size of message.
Placed after temperature, before drive model/serial in display.
2023-10-17 09:46:11 +01:00
PartialVolume
508a6d2a62 PDF_Gen37_single_column_smart_data
Previously smart data was completely located
on page 2 in two columns using a variable width font.
This had two issues. The font size had to be very small
to fit on the page which made it difficult to read
and variable width fonts were used because the smart
attribute table took up too much width when all the data
was displayed in two newspaper type columns. This made the
smart attribute table look messy.

This patch now displays the smart data over page two and three
in mono spaced font and with a larger font size so it's easier
to read and the columns with the smart attribute table are now
aligned correctly.

In terms of the code, I placed the header and footer creation
code in it's own function as this is called multiple times
and will make it easier to add additional information pages
in the future.
2023-10-15 23:16:14 +01:00
PartialVolume
0bb9ee33c9 Merge pull request #499 from PartialVolume/PDFGen36_Add_Optional_Org_Customer_Preview_Prior_To_Drive_Selection
PDFGen36_Add_Optional_Org_Customer_Preview_Prior_To_Drive_Selection.
2023-10-14 22:43:14 +01:00
PartialVolume
f12ee921b8 PDFGen36_Add_Optional_Org_Customer_Preview_Prior_To_Drive_Selection.
Added new options in GUI config menu to display preview of
organisation, customer, date/time at startup prior to drive
selection. This preview is disabled as default but can be
enabled in the config menu.

The purpose of the preview is to allow the user to check &
update as required the organisation details, customer &
current date/time so that the details provided on the PDF
certificate/report are correct.
2023-10-14 22:22:14 +01:00
Gerold Gruber
53d91f4b8b fix lowest 2023-10-13 07:44:56 +02:00
Gerold Gruber
de887ea6ee get better timing information for temperature retrieval 2023-10-12 22:15:18 +02:00
Gerold Gruber
b6f97454f1 more temperatur limit fake for SAS disks 2023-10-12 21:44:51 +02:00
Gerold Gruber
6a92755cf2 detect and display if disk is a SSD 2023-10-12 21:15:31 +02:00
Gerold Gruber
68a6002ff1 temp statistics for SAS drives 2023-10-12 12:37:32 +02:00
Gerold Gruber
47112c4de2 some code cleaning, time debugging added 2023-10-11 00:05:57 +02:00
Gerold Gruber
97efd12b93 fixes 2023-10-10 14:32:32 +02:00
Gerold Gruber
3bc3de37ae included hddtemp code for SCSI disk temperatures 2023-10-10 14:01:20 +02:00
Gerold Gruber
f764c39390 bustype detection with smartctl works (again?) 2023-10-06 00:45:44 +02:00
PartialVolume
c6ff341f7e Merge pull request #494 from PartialVolume/fix_endian_model_name
fix_endian_model_name
2023-10-02 22:48:45 +01:00
PartialVolume
59d73107f6 fix_endian_model_name
Some IDE USB adapter chipsets get the endian wrong for model name
This fix identifies a endian swapped model name and corrects it.

The function currently only includes Samsung but I'll add more IDE
drive manufacturers as I come across them.

This is peculiar to some USB IDE adapters. I've never seen this
issue with SATA, ATA drives connected directly to the motherboard.
2023-10-02 22:37:54 +01:00
Gerold Gruber
8124e6b3d5 added -P option for PDFreportpath 2023-10-02 20:28:49 +02:00
Gerold Gruber
c1e943d283 improved formatted fix for issue #492 2023-10-02 17:30:28 +02:00