Commit Graph

51 Commits

Author SHA1 Message Date
BrentHoltsclaw 23b27baff6 Fix error messages and helper loading
Remove dependency for win32helper to find .sys file within init
Fixup logic to better display when driver file cannot be found

Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2019-12-11 09:43:03 -08:00
BrentHoltsclaw 51a1de1a7e Add helper/driver information to chipsec_main and chipsec_util
Add self.name and self.driverpath to Helper baseclass
Add get_info function into Helper baseclass which returns self.name and self.driverpath
Modify helpers to have proper name and driver location for driver loaded

Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2019-12-11 09:43:03 -08:00
Erik Bjorge f20fb71843 Fixed missing () when calling error method
Signed-off-by: Erik Bjorge <erik.c.bjorge@intel.com>
2019-10-24 14:08:41 -07:00
Erik Bjorge 694b1b53ca Converted prints to debug logger messages
Signed-off-by: Erik Bjorge <erik.c.bjorge@intel.com>
2019-10-21 14:48:54 -07:00
Nicholas Armour a0c8a4666e dont convert variable data to string, keep as bytes 2019-10-21 14:48:22 -07:00
BrentHoltsclaw 9094dacdf8 Fix compiler warning with cores.c
Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2019-09-03 10:07:35 -07:00
BrentHoltsclaw 877ecb1ad8 Fixes to make uefivar_fuzz python3 compatible
Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2019-09-03 10:06:46 -07:00
BrentHoltsclaw 1d7fc4efe4 Filehelper use python2/3 compatable features
Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2019-08-19 13:15:30 -07:00
BrentHoltsclaw 2efeda4345 Merge python3-rc2 branch into master (#656) 2019-08-15 14:11:20 -07:00
BrentHoltsclaw 7e95c0e546 Fixes for EFI_SECTION_COMPRESSION logic within decompress routine
added COMPRESSION_ALGORITHMS within chipsec/defines
modified logic witin spi_uefi to rotate through valid algorithms until one is found
modified error within helpers where a list was put inside a list
modified linux helper to use subprocess.call opposed to subprocess.check_output
fixes issues #609, #610, #611

Signed-off-by: BrentHoltsclaw <brent.holtsclaw@intel.com>
2019-07-17 10:10:12 -07:00
Federico Perez 25b390f5cc Fix trailing whitespace on TianoDecompress command call 2019-07-17 10:03:21 -07:00
nha 79506dcecf Native IO read/write fixes 2019-06-10 13:43:51 -07:00
BrentHoltsclaw 9427f40a0a Fixup chipsec_tools path within linux helper 2019-06-06 11:25:53 -07:00
Richard Hughes c31daf5cb8 Use the correct path when trying to find the decompression tools
When started with ~/chipsec/chipsec_util.py we want to use the decompression
tools built in ~/chipsec/chipsec_tools/compression/bin rather than the ones in
the current path.
2019-05-29 09:34:30 -07:00
BrentHoltsclaw ab2016af72 Fix up MacOS helper to support compress and decompress
also fixed up Windows and Linux helper to correctly call tianocompress with --uefi flag
2019-05-10 11:23:47 -07:00
BrentHoltsclaw 0741c1c557 Linux helper cleanup 2019-05-10 11:23:47 -07:00
BrentHoltsclaw c73f1101a2 Compression Changes
-------------------
1. Removed previous compression methodology
  a. All files were removed
2. Using compression tools directly from tianocore/edk2/BaseTools
  a. Downloaded from master branch
  b. Changed Makefiles to build within Chipsec
  c. Added BrotliCompress
3. Reworked Windows and Linux Helper to utilize tools built from compression tools
  a. Both helpers utilize same logic of calling compression tools
  b. Updated to support BrotliCompress
4. Modified GUID functionality within uefi_common to unpack struct as strings opposed to numbers
2019-05-10 11:23:47 -07:00
BrentHoltsclaw 66710206e7 Changes based upon comments 2019-04-25 14:19:08 -07:00
BrentHoltsclaw 789314a142 Normalizing logging for various sections of chipsec:
HAL now only use logger().HAL
helpers now only use logger.DEBUG
modules now only use logger.VERBOSE
2019-04-25 14:19:08 -07:00
BrentHoltsclaw 106d9f2e3e Moving Helper from oshelper to basehelper file 2019-04-25 14:14:27 -07:00
BrentHoltsclaw 904e1b1a78 Changes to linux helper to allow smm return 2019-04-25 14:05:07 -07:00
BrentHoltsclaw 4a13f8cd2b Changes per @erikbjorge 2019-01-29 11:26:25 -08:00
BrentHoltsclaw 0e7c7c100d Fix for issue #386
- Found that native linux helper needs to first map io memory before reading it
  - changed hal and helper functionality to allow base address and offset to be passed
  to the function allowing the call to native_map_io_space to be used without guessing the base address
  - discovered a bug within hal list_MMIO_BARs that failed if a MMIOBAR was unreadable added a try except to fix
2019-01-29 11:26:25 -08:00
BrentHoltsclaw 3a515e9cfb Address issue #249
changed drivers/linux/include/chipsec.h to start from 'C'
added logic to compute ioctl base based upon changes to chipsec.h above
2019-01-17 11:30:20 -08:00
Erik Bjorge 02df863cdd Reverting to previous memory access method.
More debug is required before switching to this updated method for memory access.

Signed-off-by: Erik Bjorge <erik.c.bjorge@intel.com>
2018-10-01 10:32:20 -07:00
Max dc4ee91bb6 Fix extra argument
The self argument is a duplicate (super(...) will insert `self` as the first argument to any method -- just like an instance would).

Note: I suspect, but too lazy to check, that mmap.mmap.__init__ is a no-op, since otherwise this bug would have caused obvious runtime errors.
2018-09-10 10:18:08 -07:00
Sushmith Hiremath ed76b7bc09 Print GetAffinity messages only in verbose mode 2018-05-21 09:34:16 -07:00
BrentHoltsclaw 72fcb5d277 fixed up error handling 2018-03-06 17:50:48 -08:00
BrentHoltsclaw deee07d173 Change linux READ/WRITE Physical Memory Functionality 2018-03-06 17:50:48 -08:00
Erik Bjorge 9a5e095342 Revert "Change linux READ/WRITE Physical Memory Functionality"
This reverts commit 3c1c6906f9.

Signed-off-by: Erik Bjorge <erik.c.bjorge@intel.com>
2018-02-26 10:24:19 -08:00
BrentHoltsclaw 3c1c6906f9 Change linux READ/WRITE Physical Memory Functionality 2018-02-23 09:35:28 -08:00
Federico Perez eb7f7f4d65 Fixed compression bug(#312) 2018-01-19 16:52:59 -03:00
Federico Perez 0a7fe559b5 Fixed (#269) 2017-10-20 11:07:48 -07:00
Federico Perez 841c06dbe4 Fixed (#269) 2017-10-20 11:07:48 -07:00
Nick Mooney 49348dc0db Add mmap support to kernel module 2017-07-24 13:26:08 -07:00
Thiébaud Weksteen bdea49936a Remove unused __version__ (#215) 2017-05-08 22:17:35 -07:00
abazhaniuk 8679a9ad06 fix bugs during decompression (#192) 2017-04-16 10:30:57 -10:00
c7zero 0ad817d479 Fix --no_driver option on macOS (#181) 2017-03-17 01:04:25 -07:00
johnloucaides 9a3c5a6053 add native functions to access port io & msr on linux (#160)
* add native functions to access port io and msr

* remove debug prints and try modprobe msr when not available

* fixed bug in native_read_io_port

* add attempt to load msr kernel module if not present and update error string
2017-03-02 02:06:12 -08:00
abazhaniuk 107de65ce3 fix issues in decompression functionality (#161) 2017-03-02 02:05:21 -08:00
abazhaniuk f12b035458 Ported efi_compressor from uefi-firmware-parser to chipsec_tools (#152)
* Ported efi_compressor from uefi-firmware-parser to chipsec_tools

* moved compression_source_files
2017-02-11 00:05:30 -08:00
abazhaniuk c377a72e28 Deb package (#135)
* merge

* Add Debian packaging

* cleanup

* Removed incorrect info into Copyright.

* One more: removed incorrect info in Copyright.
2017-01-06 12:57:13 -08:00
abazhaniuk f2dd9ad515 add DKMS support (#132)
* add DKMS support

* remove unnecessary functions

* moved get_version to defines

* raise an exception
2016-12-06 00:46:12 -08:00
c7zero 9847ed9357 Fixed ctypes 2016-12-05 17:37:26 -08:00
Thiébaud Weksteen 1edfb70c2a Add MemoryMapping and map_io_space to Linux helper (#120) 2016-12-05 15:49:41 -08:00
Thiébaud Weksteen d670746532 Add native_write_pci_reg to Linux helper (#129)
Also includes two aliases pack1 and unpack1 to easily convert values
in the helpers.
2016-12-01 22:42:06 -08:00
O Bazhaniuk 7fd8b99d9e remove print_cpu_set_t 2016-11-16 16:51:56 -05:00
c7zero 8ee894b880 More generic handling of chipsec tools (#118)
* More generic handling of chipsec_tools

* file extension fix

* Installing chipsec-manual.pdf
2016-11-04 14:38:06 -07:00
Thiébaud Weksteen 63991da054 Improve build_ext (#115) 2016-11-03 15:27:24 -07:00
abazhaniuk 9e42ff337d add compression tools to python package (#111) 2016-10-25 14:01:27 -07:00