Bug 1174551
Summary: | "lstatnslist" and "lstatlist" don't give an error if the API is used wrongly | ||
---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Chao Zhang <chazhang> |
Component: | libguestfs | Assignee: | Richard W.M. Jones <rjones> |
Status: | CLOSED ERRATA | QA Contact: | Virtualization Bugs <virt-bugs> |
Severity: | low | Docs Contact: | |
Priority: | low | ||
Version: | 7.1 | CC: | leiwang, linl, mbooth, ptoscano, wshi, xchen |
Target Milestone: | rc | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | libguestfs-1.32.0-2.el7 | Doc Type: | Bug Fix |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2016-11-03 17:48:44 UTC | Type: | Bug |
Regression: | --- | Mount Type: | --- |
Documentation: | --- | CRM: | |
Verified Versions: | Category: | --- | |
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |
Cloudforms Team: | --- | Target Upstream Version: | |
Embargoed: | |||
Bug Depends On: | 1218766 | ||
Bug Blocks: | 1288337, 1301891 |
Description
Chao Zhang
2014-12-16 02:48:44 UTC
I guess the answer is "don't do that" :-) However yes we can add a check to make sure if you use the API wrongly it will give you an error instead. Moving to 7.2 because the API does currently work if used correctly. This has been fixed upstream with commits https://github.com/libguestfs/libguestfs/commit/7c10cda26650bd0076817b07134c893c28e0adf9 https://github.com/libguestfs/libguestfs/commit/b5a6f899cdf383e07871952dd7378b0787c43687 which are in libguestfs >= 1.31.20. It will be picked by the rebase (bug #1218766). Verified with the packages: libguestfs-1.32.5-6.el7.x86_64 Verify steps: 1. Prepare a RHEL guest image: RHEL-Server-7.2-64-hvm.raw 2. # guestfish -a RHEL-Server-7.2-64-hvm.raw -i ><fs> ll /home/ total 4 drwxr-xr-x. 2 root root 6 May 25 2015 . dr-xr-xr-x. 17 root root 4096 Oct 31 2015 .. ><fs> lstatnslist /home "/bin /root" libguestfs: error: lstatnslist: names: '/bin' is not a file name It gives an obvious error as above. So verified. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHSA-2016-2576.html |