I'm trying to scan a remote machine using my own script that I made using OpenSCAP Script Engine. From the different options that offers me oscap-ssh I am using the "--local-files" one that allows me to upload a directory to the remote host so I can transfer the bash check scripts. When I execute the complete command I can establish conection with the remote machine and the files from the local directory are copied to a temporal remote working directory but then, when the main script has to use the local file, an error tells me that there no such file or directory.
oscap 1.3.6
Rocky Linux 8.6
oscap-ssh <user>@<ip> 22 xccdf eval --profile <profile> --report report.html --local-files </path/to/directory/> <my_script>.xml
Finally I had the answer... no references founded in official documentation or anywhere on the Internet.
When you use the option --local-files
the files in the directory you specify are not located in the /tmp/tmp.XXXXXXX/
directory, they are in /tmp/tmp.XXXXXX/local_files/
and these information does not appear anywhere.