aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2022-02-25Merge "Make libelf visible to libbpf-tools" am: 38fd201227 am: c3ccce0b14 ↵t_frc_odp_330442040t_frc_odp_330442000t_frc_ase_330444010android-wear-13.0.0-gpl_r3android-wear-13.0.0-gpl_r2android-wear-13.0.0-gpl_r1android-t-qpr3-beta-3-gplandroid-t-qpr3-beta-1-gplandroid-t-qpr2-beta-3-gplandroid-t-qpr2-beta-2-gplandroid-t-qpr1-beta-3-gplandroid-t-qpr1-beta-1-gplandroid-13.0.0_r83android-13.0.0_r82android-13.0.0_r81android-13.0.0_r80android-13.0.0_r79android-13.0.0_r78android-13.0.0_r77android-13.0.0_r76android-13.0.0_r75android-13.0.0_r74android-13.0.0_r73android-13.0.0_r72android-13.0.0_r71android-13.0.0_r70android-13.0.0_r69android-13.0.0_r68android-13.0.0_r67android-13.0.0_r66android-13.0.0_r65android-13.0.0_r64android-13.0.0_r63android-13.0.0_r62android-13.0.0_r61android-13.0.0_r60android-13.0.0_r59android-13.0.0_r58android-13.0.0_r57android-13.0.0_r56android-13.0.0_r55android-13.0.0_r54android-13.0.0_r53android-13.0.0_r52android-13.0.0_r51android-13.0.0_r50android-13.0.0_r49android-13.0.0_r48android-13.0.0_r47android-13.0.0_r46android-13.0.0_r45android-13.0.0_r44android-13.0.0_r43android-13.0.0_r42android-13.0.0_r41android-13.0.0_r40android-13.0.0_r39android-13.0.0_r38android-13.0.0_r37android-13.0.0_r36android-13.0.0_r35android-13.0.0_r34android-13.0.0_r33android-13.0.0_r32android-13.0.0_r30android-13.0.0_r29android-13.0.0_r28android-13.0.0_r27android-13.0.0_r24android-13.0.0_r23android-13.0.0_r22android-13.0.0_r21android-13.0.0_r20android-13.0.0_r19android-13.0.0_r18android-13.0.0_r17android-13.0.0_r16aml_go_odp_330912000aml_go_ads_330915100aml_go_ads_330915000aml_go_ads_330913000android13-qpr3-s9-releaseandroid13-qpr3-s8-releaseandroid13-qpr3-s7-releaseandroid13-qpr3-s6-releaseandroid13-qpr3-s5-releaseandroid13-qpr3-s4-releaseandroid13-qpr3-s3-releaseandroid13-qpr3-s2-releaseandroid13-qpr3-s14-releaseandroid13-qpr3-s13-releaseandroid13-qpr3-s12-releaseandroid13-qpr3-s11-releaseandroid13-qpr3-s10-releaseandroid13-qpr3-s1-releaseandroid13-qpr3-releaseandroid13-qpr3-c-s8-releaseandroid13-qpr3-c-s7-releaseandroid13-qpr3-c-s6-releaseandroid13-qpr3-c-s5-releaseandroid13-qpr3-c-s4-releaseandroid13-qpr3-c-s3-releaseandroid13-qpr3-c-s2-releaseandroid13-qpr3-c-s12-releaseandroid13-qpr3-c-s11-releaseandroid13-qpr3-c-s10-releaseandroid13-qpr3-c-s1-releaseandroid13-qpr2-s9-releaseandroid13-qpr2-s8-releaseandroid13-qpr2-s7-releaseandroid13-qpr2-s6-releaseandroid13-qpr2-s5-releaseandroid13-qpr2-s3-releaseandroid13-qpr2-s2-releaseandroid13-qpr2-s12-releaseandroid13-qpr2-s11-releaseandroid13-qpr2-s10-releaseandroid13-qpr2-s1-releaseandroid13-qpr2-releaseandroid13-qpr2-b-s1-releaseandroid13-qpr1-s8-releaseandroid13-qpr1-s7-releaseandroid13-qpr1-s6-releaseandroid13-qpr1-s5-releaseandroid13-qpr1-s4-releaseandroid13-qpr1-s3-releaseandroid13-qpr1-s2-releaseandroid13-qpr1-s1-releaseandroid13-qpr1-releaseandroid13-mainline-go-adservices-releaseandroid13-frc-odp-releaseandroid13-devandroid13-d4-s2-releaseandroid13-d4-s1-releaseandroid13-d4-releaseandroid13-d3-s1-releaseandroid13-d2-releaseandroid-wear-13.0.0-gpl_r1Connor O'Brien
am: d8c00f06ba Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1965994 Change-Id: If8133449ee544097197a1e29f8ce66e5e0497af6
2022-02-25Merge "Make libelf visible to libbpf-tools" am: 38fd201227 am: c3ccce0b14Connor O'Brien
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1965994 Change-Id: I1b1d303cd1e35a6c01d4240c87c8f8ff7faaa0e2
2022-02-25Merge "Make libelf visible to libbpf-tools" am: 38fd201227Connor O'Brien
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1965994 Change-Id: I86aeafce750e55d41dec48b463035027684a7105
2022-02-24Merge "Make libelf visible to libbpf-tools"Connor O'Brien
2022-02-23Merge "Make libelf visible to bpftool" am: 8ceef2e4ad am: 653c7f296c am: ↵Connor O'Brien
6af4638e60 Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1985629 Change-Id: Ifdbf38e74f6ed71a59ce235fcce3a1269466f117
2022-02-23Merge "Make libelf visible to bpftool" am: 8ceef2e4ad am: 653c7f296cConnor O'Brien
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1985629 Change-Id: Ice0394b4e9696426e8d2ed22c3862ed13efb7d6f
2022-02-23Merge "Make libelf visible to bpftool" am: 8ceef2e4adConnor O'Brien
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1985629 Change-Id: I5f066c2a9cb3dee0ac37f51e55ad9fb30d41bace
2022-02-23Merge "Make libelf visible to bpftool"Connor O'Brien
2022-02-14Make libelf visible to libbpf-toolsConnor O'Brien
libbpf-tools provides standalone eBPF-based tracing tools. Because they use libbpf to parse/load BPF .o files and kernel BTF, these tools rely on libelf in order to function. Add external/bcc/libbpf-tools to the visibility list for libelf. This directory contains only the libbpf-tools, so other code from the bcc project (e.g. libbpf_bcc) still cannot be built against libelf. Test: m ksnoop Signed-off-by: Connor O'Brien <connoro@google.com> Change-Id: I2d3932fe2b44b1b95f871320d20b2a605fedb180
2022-02-14Make libelf visible to bpftoolConnor O'Brien
bpftool is used in the build process of libbpf-tools and depends on the full upstream libbpf, which means it needs libelf as well in order to build. Bug: 203823368 Test: m bpftool Signed-off-by: Connor O'Brien <connoro@google.com> Change-Id: I634acc27af651660ea4d289c718af4689bb63f0f
2022-02-11[automerger skipped] Empty merge of ↵Xin Li
sc-v2-dev-plus-aosp-without-vendor@8084891 am: a5e7584fb3 -s ours am: 6d7ad9bced -s ours am skip reason: Merged-In Ie8f964b5b2139dce89ac7432613e18478fe195bd with SHA-1 d7b4939cf2 is already in history Original change: https://googleplex-android-review.googlesource.com/c/platform/external/elfutils/+/16843231 Change-Id: I8977aaea2fc1428106074137320a16c34da722e4
2022-02-11[automerger skipped] Empty merge of ↵Xin Li
sc-v2-dev-plus-aosp-without-vendor@8084891 am: a5e7584fb3 -s ours am skip reason: Merged-In Ie8f964b5b2139dce89ac7432613e18478fe195bd with SHA-1 d7b4939cf2 is already in history Original change: https://googleplex-android-review.googlesource.com/c/platform/external/elfutils/+/16843231 Change-Id: I64130f2ca864ae8b96e5c46abfa5ee254f8b2a4c
2022-02-11Empty merge of sc-v2-dev-plus-aosp-without-vendor@8084891Xin Li
Bug: 214455710 Merged-In: Ie8f964b5b2139dce89ac7432613e18478fe195bd Change-Id: I894ca064c76f9093fb765e66f8bf95e0a3379e3b
2022-01-31Merge "dwfl: fix potential overflow when reporting on kernel modules" am: ↵Treehugger Robot
325ecbcd3c am: c7d887b3c9 am: f2fd5fd305 am: c1b5f83040 Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1960724 Change-Id: I23d6ff311195488a3cc3b23bd41bdbbdef4085c2
2022-01-31Merge "dwfl: fix potential overflow when reporting on kernel modules" am: ↵Treehugger Robot
325ecbcd3c am: c7d887b3c9 am: f2fd5fd305 Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1960724 Change-Id: Icfabf226c03642748e1735a261b1288c026a8097
2022-01-31Merge "dwfl: fix potential overflow when reporting on kernel modules" am: ↵Treehugger Robot
325ecbcd3c am: c7d887b3c9 Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1960724 Change-Id: Id167834cf0035246956711bff845b78a496c8653
2022-01-31Merge "dwfl: fix potential overflow when reporting on kernel modules" am: ↵Treehugger Robot
325ecbcd3c Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1960724 Change-Id: I7d44dd32d5129fa9c55107cd2c588dd37dfef6fe
2022-01-31Merge "dwfl: fix potential overflow when reporting on kernel modules"android-t-preview-1android-s-v2-beta-3android-t-preview-1android-s-v2-beta-3Treehugger Robot
2022-01-26dwfl: fix potential overflow when reporting on kernel modulesMatthias Maennich
dwfl_linux_kernel_report_modules_ has an outstanding ancient bug when reading kernel module information from a modules list file. The target buffer for the module name was sized too small to hold potential values. Fix that by increasing the value to account for the null termination. In practice, this unlikely ever happened, but it now got diagnosed by LLVM as part of a stricter -Wfortify-source implementation [1]: libdwfl/linux-kernel-modules.c:1019:7: error: 'sscanf' may overflow; destination buffer in argument 3 has size 128, but the corresponding specifier may require size 129 [-Werror,-Wfortify-source] modname, &modsz, &modaddr) == 3) [1] https://github.com/llvm/llvm-project/commit/2db66f8d48beeea835cb9a6940e25bc04ab5d941 Suggested-by: Paul Pluzhnikov <ppluzhnikov@google.com> Signed-off-by: Matthias Maennich <maennich@google.com> Test: Builds with new clang without warnings (cherry picked from commit 2e3bc18672f0cede0332ae3194eb2e33d4cc5fd7) Change-Id: I19342bb64ff5b973aa3f4c65abed8123eab8367d
2021-11-18Merge changes Ie8f964b5,I644650d7 am: be508084da am: 5180e87dcc am: ↵Treehugger Robot
932e0584e2 am: 4e2923b29b Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1895360 Change-Id: I2669107424a390798672aa0beb6e4c9a09bffcb1
2021-11-18Merge changes Ie8f964b5,I644650d7 am: be508084da am: 5180e87dcc am: 932e0584e2Treehugger Robot
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1895360 Change-Id: I4bb69e9c086b1a18dc6d8467460081a6b93178bc
2021-11-18Merge changes Ie8f964b5,I644650d7 am: be508084da am: 5180e87dccTreehugger Robot
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1895360 Change-Id: Ic492e343cb67c308c9e30e41c67a79c081097462
2021-11-18Merge changes Ie8f964b5,I644650d7 am: be508084daTreehugger Robot
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1895360 Change-Id: Ieef9602118d5afa007831783893f296de1cd0e7f
2021-11-18Merge changes Ie8f964b5,I644650d7Treehugger Robot
* changes: drop recursive documentation symlinks Merge tag 'elfutils-0.186' into master
2021-11-17drop recursive documentation symlinksMatthias Maennich
This upsets soong during globbing. Signed-off-by: Matthias Maennich <maennich@google.com> Change-Id: Ie8f964b5b2139dce89ac7432613e18478fe195bd
2021-11-16Merge "Extend visibility to //external/stg" am: eed13d52bc am: fce080f06b ↵Matthias Maennich
am: 40b262dfad am: a8279ebfed Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1892422 Change-Id: I4f60c07f1eaa76079d51a89abbe9dcc6b0bad2d5
2021-11-16Merge "Extend visibility to //external/stg" am: eed13d52bc am: fce080f06b ↵Matthias Maennich
am: 40b262dfad Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1892422 Change-Id: I72f2973aa841d099421a64b36d241a729e9ffdef
2021-11-16Merge "Extend visibility to //external/stg" am: eed13d52bc am: fce080f06bMatthias Maennich
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1892422 Change-Id: Ie1bd0eec8a59f8287a1e47f11116433cb5801fd7
2021-11-16Merge "Extend visibility to //external/stg" am: eed13d52bcMatthias Maennich
Original change: https://android-review.googlesource.com/c/platform/external/elfutils/+/1892422 Change-Id: I1fb62b9b5eb3e1132912406388ac0997ce4a0118
2021-11-16Merge "Extend visibility to //external/stg"Matthias Maennich
2021-11-16Merge tag 'elfutils-0.186' into masterMatthias Maennich
elfutils 0.186 release * tag 'elfutils-0.186': Prepare for 0.186 PR28430: debuginfod: support --passive mode libdw, readelf: Read inlining info in NVIDIA extended line map libdw: dwarf_elf_begin should use either plain, dwo or lto DWARF sections. Improve building with LTO PR28514: debuginfod: limit groom operation times NEWS: make automake check-news / dist happy NEWS: list some 0.186 debuginfod client & server features PR28240: debuginfod client root-safe negative caching libdw: Don't pass NULL to dwarf_peel_type libdw: Use signedness of subrange type to determine array bounds debuginfod-client: Stick to http:// + https:// + file:// protocols PR27783: switch default debuginfod-urls to drop-in style files tests: Handle dwarf_attr_string returning NULL in show-die-info.c elflint.c: Don't dereference databits if bad PR28242: debuginfod prometheus metric widening RISC-V: PR27925 Add support for LP64 and LP64F ABIs return values debuginfod: Remove checking for unsafe headers debuginfod: Query debuginfod servers before printing response debuginfod: PR27277 - Describe retrieved files when verbose debuginfod: PR28034 - No longer escape '/', and loop efficiency PR28339: debuginfod: fix groom/scan race condition on just-emptied queue debuginfod: Add endl after "fdcache emergency flush for filling tmpdir" log lib: Make error.c more like error(3) libdw: set address size, offset size and version on fake CUs tests: Don't fail run-debuginfod-fd-prefetch-caches.sh if grep -c fails findtextrel: do not use unbound alloca tests: Cleanup error handling and don't share cache between servers/client Use xasprintf instead of asprintf followed by error(EXIT_FAILURE) Introduce xasprintf Remove redundant casts of memory allocating functions returning void * src: add -Wno-error=stack-usage= to AM_LDFLAGS tests: Make sure to wait for initial scan and groom cycle earlier tests: Make sure to wait for initial scan and groom cycle tests: Only export DEBUGINFOD_URLS when necessary tests: Print metrics for both ports on error and fix port selection tests: Set DEBUGINFOD_CACHE_PATH for run-debuginfod-{file,query-retry}.sh tests: Make sure all debuginfod tests use a clean database and cache. tests: Add debuginfod-subr.sh to EXTRA_DIST debuginfod: Fracture tests/run-debuginfod-find.sh into specific tests configure.ac: rework gnu99 ext check to allow clang debuginfod: Turn -d ":memory:" into -d "file::memory:?cache=shared" tests: Use fresh separate databases for debuginfd forwarded-ttl-limit debuginfod: PR27917 - protect against federation loops Add lib/error.c lib: avoid potential problems with `-fno-common` lib: remove unused `STROF` definition (NFC) handle libc implementations which do not provide `error.h` debuginfod, elfclassify: remove unnecessary header inclusion lib: remove usage of `sys/cdefs.h` PR27950 - package new debuginfod-client-config.7 man page in rpm PR28249: correct debuginfod after-you locking debuginfod-doc: PR27950: make distcheck happy debuginfod-doc: PR27950 - Remove redanduncies in man page. tests: Allow an extra pthread_kill frame in backtrace tests debuginfod: PR27982 - added DEBUGINFOD_MAXSIZE and DEBUGINFOD_MAXTIME update Japanese translation debuginfod: PR27983 - ignore duplicate urls lib: Add static inline reallocarray fallback function debuginfod: PR28034 - client-side %-escape url characters debuginfod: Minor run-debuginfod-find.sh test fixes libelf: Optimize elf_strptr.c validate_str by checking last char first readelf: Pull advance_pc() in file scope debuginfod: PR25978 - Created the prefetch fdcache PR27531: retry within default retry_limit will be supported. debuginfod: PR27711 - Use -I/-X regexes during groom phase tests: Fix EXTRA_DIST typo in testfile-largealign.o.bz2 libelf: Fix unaligned d_off offsets for input sections with large alignments readelf: Handle line tables without line number statements correctly readelf: Fix error message when two attribute names differ in in compare_listptr. unstrip: Always check gelf_getrel[a] results strip: Always check gelf_update results. debuginfod-client: Fix client dereference when calloc fails. run-debuginfod-find.sh: Disable valgrind for debuginfod client cache tests debuginfod test: fix groom/stale race condition debuginfod tests: tolerate 000-perm files in cache-copy test debuginfod tests: try to generate diagnostics more reliably on error libdwfl: fix potential NULL pointer dereference when reading link map PR27863: debuginfod optimization for concurrent requests elflint: fix undefined 'buffer_left' reference Prepare for 0.185 PR27859: correct 404-latch bug in debuginfod client reuse elfcompress: fix exit status in case of an error elfcompress: remove redundant assignment elfcompress: fix exit status regression in case of "Nothing to do" Come up with startswith function. elfutils.spec: Add procps as a %check BuildRequires:. Prepare for 0.184 libdw: Document and handle DW_FORM_indirect in __libdw_form_val_compute_len debuginfod: debuginfod client should cache negative results. PR27571: debuginfod client cache - file permissions PR26125: debuginfod client cache - rmdir harder libdw: handle DW_FORM_indirect when reading attributes PR27701: debuginfod client: encourage reused debuginfod_client objects po: update XGETTEXT_OPTIONS debuginfod: only update database stats once per groom debuginfod: Recognize .debug_*-less symtab-laden files as debuginfo nm: Fix file descriptor leak on dwfl_begin failure. unstrip: Fix small leak in handle_output_dir_module. ar: Always close newfd in do_oper_insert. doc/debuginfod.8: fix wrong parameter name for .deb files in description debuginfod: Set child thread names via pthread_setname_np() debuginfod-client: Don't compare a double to a long Update Polish translation Update POTFILES.in build: Check for -Wno-packed-not-aligned support build: Check for -Wtrampolines support debuginfod-client: Fix typo in curl feature detection readelf: Sanity check verneed and verdef offsets in handle_symtab. elfcompress: Replace cleanup() with label build: Check for -Wimplicit-fallthrough=5 separately tests: Pull new_data_buf() into file scope for elfstrmerge. tests: Pull newsecndx() info file scope for elfstrmerge elfcompress: Pull get_sections() into file scope elfcompress: Pull get_section() into file scope elfcompress: Pull set_section() into file scope unstrip: Remove nested next() function unstrip: Pull warn() into file scope unstrip: Inline find_unalloc_section() into only caller unstrip: Pull check_match() into file scope unstrip: Pull adjust_reloc() into file scope elflint: Pull left() in file scope elflint: Pull pos() info file scope debuginfod: filter webapi for bad keywords early testsuite: run-debuginfod-find.sh: Fix grooming test indeterminacy NEWS: add a debuginfod blurb re. bsdtar testsuite: run-debuginfod-find.sh: Be more verbose on failure readelf: Type DIE offset is from start of CU. readelf, libdw: blocks aren't expressions for DWARF version 4 PR27413: use bsdtar to unpack deb-related formats tests: Quote make variables in TESTS_ENVIRONMENT elfutils.spec.in: Escape %%check in comment. tests/run-debuginfod-find.sh: skip test if cpio isn't available. Signed-off-by: Matthias Maennich <maennich@google.com> Change-Id: I644650d79de63796c6acaaabb1474907a6043a6d
2021-11-16Extend visibility to //external/stgMatthias Maennich
Bug: 188176217 Signed-off-by: Matthias Maennich <maennich@google.com> Change-Id: I93b76613968138d8291033cd17d5033b5972c909
2021-11-10Prepare for 0.186Mark Wielaard
Set version to 0.186 Update NEWS and elfutils.spec.in Regenerate po/*.po files Signed-off-by: Mark Wielaard <mark@klomp.org>
2021-11-10PR28430: debuginfod: support --passive modeFrank Ch. Eigler
Add support for a limited mode for debuginfod that uses a pure read-only sqlite index. This mode is useful for load spreading based on naively shared or replicated databases. Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
2021-11-10libdw, readelf: Read inlining info in NVIDIA extended line mapJohn M Mellor-Crummey
As of CUDA 11.2, NVIDIA added extensions to the line map section of CUDA binaries to represent inlined functions. These extensions include - two new fields in a line table row to represent inline information: context, and functionname, - two new DWARF extended opcodes: DW_LNE_NVIDIA_inlined_call, DW_LNE_NVIDIA_set_function_name, - an additional word in the line table header that indicates the offset in the .debug_str function where the function names for this line table begin, and A line table row for an inlined function contains a non-zero "context" value. The “context” field indicates the index of the line table row that serves as the call site for an inlined context. The "functionname" field in a line table row is only meaningful if the "context" field of the row is non-zero. A meaningful "functionname" field contains an index into the .debug_str section relative to the base offset established in the line table header; the position in the .debug_str section indicates the name of the inlined function. These extensions resemble the proposed DWARF extensions (http://dwarfstd.org/ShowIssue.php?issue=140906.1) by Cary Coutant, but are not identical. This commit integrates support for handling NVIDIA's extended line maps into elfutil's libdw library, by adding two functions dwarf_linecontext and dwarf_linefunctionname, and the readelf --debug-dump=line command line utility. Signed-off-by: John M Mellor-Crummey <johnmc@rice.edu> Signed-off-by: Mark Wielaard <mark@klomp.org>
2021-11-09libdw: dwarf_elf_begin should use either plain, dwo or lto DWARF sections.Mark Wielaard
When opening an ELF file that contained a mix of plain, dwo or lto .debug sections the result could be confusing. Add a check to pick just the plain .debug sections, or the .dwo sections or the .gnu.debuglto_.debug sections (in that order of preference). That way there is always a consistent set. https://sourceware.org/bugzilla/show_bug.cgi?id=27367 Signed-off-by: Mark Wielaard <mark@klomp.org>
2021-11-08Improve building with LTOAlexander Miller
Use symver attribute for symbol versioning instead of .symver assembler directive when available. Convert to use double @ syntax for default version in all cases (required when using the attribute). Add the attributes externally_visible, no_reorder if available when using assembler directives to improve the situation for < gcc-10. This is not 100% reliable, though; -flto-partition=none may still be needed in some cases. Bug: https://sourceware.org/bugzilla/show_bug.cgi?id=24498 Signed-off-by: Alexander Miller <alex.miller@gmx.de>
2021-11-05PR28514: debuginfod: limit groom operation timesFrank Ch. Eigler
For large databases and many stale files, it was possible to starve rescan operations by numerous groom "nuke" (database delete ops). Under the theory that including new data is at least as important as aging old, we now impose a rough deadline on groom queries. In the process, we discovered that we were commiting some undefined-behaviour sqlite ops (deleting rows while iterating), which may explain some previous heisenbug occurrences. So the groom nuke operations are split into decision & action phases, with associated progress-tracking metrics. Testing the timeout facility requires hand-testing beyond the testsuite (since it requires LARGE databases to show measurable query times). So confirmed this part by hand. Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
2021-11-04NEWS: make automake check-news / dist happyFrank Ch. Eigler
automake's check-news option requires not too much new content before a line that includes the current version number. Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
2021-11-04NEWS: list some 0.186 debuginfod client & server featuresFrank Ch. Eigler
Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
2021-10-22PR28240: debuginfod client root-safe negative cachingFrank Ch. Eigler
Negative cache (000-permission) files were incorrectly treated as valid cached files for the root user, because root can open even 000-perm files without -EACCES. Corrected this checking sequence. Fixed the debuginfod testsuite to run to completion as root or as an ordinary user, correcting corresponding permission checks: stat -c %A $FILE is right and [ -w $FILE] [ -r $FILE ] were wrong. Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
2021-10-18libdw: Don't pass NULL to dwarf_peel_typeMark Wielaard
commit c3a6a9dfc "libdw: Use signedness of subrange type to determine array bounds" introduced a type check on a DIE which exposed a latent bug in the get_type function. Even if the type of a DIE couldn't be determined it would call dwarf_peel_type on it. The gcc undefined sanitizer would flag this as being undefined behaviour because the second argument of the function is marked as non-NULL. Fix this by checking we actually have a non-NULL type DIE. Signed-off-by: Mark Wielaard <mark@klomp.org>
2021-10-18libdw: Use signedness of subrange type to determine array boundsMark Wielaard
When calculating the array size check if the subrange has an associate type, if it does then check the type to determine whether the upper and lower values need to be interpreted as signed of unsigned values. We default to signed because that is what the testcase run-aggregate-size.sh testfile-size4 expects (this is an hardwritten testcase, we could have chosen a different default). https://sourceware.org/bugzilla/show_bug.cgi?id=28294 Signed-off-by: Mark Wielaard <mark@klomp.org>
2021-10-15debuginfod-client: Stick to http:// + https:// + file:// protocolsMark Wielaard
Make sure we don't use any of the more experimental protocols libcurl might support. URLs can be redirected and we might want to follow http -> https, but not e.g. gopher or pop3. Suggested-by: Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> Signed-off-by: Mark Wielaard <mark@klomp.org>
2021-10-07PR27783: switch default debuginfod-urls to drop-in style filesFrank Ch. Eigler
Rewrote and commented the /etc/profile.d csh and sh script fragments to take the default $DEBUGINFOD_URLS from the union of drop-in files: /etc/debuginfod/*.urls. Hand-tested with csh and bash, with conditions including no prior $DEBUGINFOD_URLS, nonexistent .urls files, multiple entries in .urls files. Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
2021-10-06tests: Handle dwarf_attr_string returning NULL in show-die-info.cMark Wielaard
Reported-by: Jan-Benedict Glaw <jbglaw@lug-owl.de> Signed-off-by: Mark Wielaard <mark@klomp.org>
2021-10-06elflint.c: Don't dereference databits if badMark Wielaard
elflint.c: In function 'check_sections': elflint.c:4105:48: error: null pointer dereference [-Werror=null-dereference] 4105 | idx < databits->d_size && ! bad; | ~~~~~~~~^~~~~~~~ Fix this by testing for ! bad first. Reported-by: Jan-Benedict Glaw <jbglaw@lug-owl.de> Signed-off-by: Mark Wielaard <mark@klomp.org>
2021-10-06PR28242: debuginfod prometheus metric wideningDi Chen
This patch aims to extend http_responses_* metrics with another label "type" by getting the extra artifact-type content added as a new key=value tag. v2, tweaked patch to perform artifact-type sanitization at point of vulnerability rather than in general metric tabulation logic. Signed-off-by: Di Chen <dichen@redhat.com> Signed-off-by: Frank Ch. Eigler <fche@redhat.com>
2021-09-30RISC-V: PR27925 Add support for LP64 and LP64F ABIs return valuesWilliam Cohen
The RISC-V Linux kernel is compiled without floating point (the LP64 ABI) and elfutils could not obtain return value locations for functions in the kernel. This issue was noticed when Systemtap generated RISC-V kernel modules for scripts that used $return target variables in function return probes. This patch adds the needed support to provide return value information for the LP64 and LP64F ABIs. Signed-off-by: William Cohen <wcohen@redhat.com>
2021-09-17debuginfod: Remove checking for unsafe headersNoah Sanci
Some http response header checks were removed such as checking for Connection and Cache-Control. These headers are not guarenteed to be received and depend on proxy and libmicrohttpd versions. Checking for the existance of Content-Length and DEBUGINFOD-* headers is sufficient since Content-Length is added upon creation of an MHD_Response object and DEBUGINFOD-* are added manually. (source on Content-Length being added: https://www.gnu.org/software/libmicrohttpd/manual/libmicrohttpd.html# microhttpd_002dresponse-headers ) Signed-off-by: Noah Sanci <nsanci@redhat.com>