ihsec
ihsec copied to clipboard
Not work in mac
I got you config to my mac! when i run ihsec set conifgname i found the config folder link in .emacs.d/,
the result bellow:
How can i fix it ?
I found i need to remove .emacs.d folder! it works! but some command not friendly for mac, can you make it better?
You'd need to specify what you mean by making it better. I do not use macOS nor do I have access to any devices that use it, so unless you tell me exactly what the issue is I might not be able to help.
https://github.com/daedreth/ihsec/blob/a7d454a1b1e4f222aa2e80c665e5174c167323e2/Makefile#L10
install -D option not in mac:
if you do echo $OSTYPE
in your terminal, what does it show?
Also, what version of macOS are you on?
echo $OSTYPE show me darwin17.0. mac os version 10.13.3 (17D47)!
pushed a fix, see if it works
Hi
Thanks very much for making this public — it's a great solution to a big irritation!
FWIW, the fix was still failing to work on my Macs (both on High Sierra) — the problem seems to be the the $OSTYPE variable is stripped down to STYPE for some reason, so the actual line reads
if [[ "STYPE" == "darwin"* ]] etc
when it is run and it doesn't pick up it's on a Mac. No idea why...
The fix was simple for me (as I don't need it on Linux) — just delete everything apart from the mac relevant branch of the if statement, leaving just
cp ihsec.sh /usr/local/bin/ihsec; chmod 755 /usr/local/bin/ihsec
Everything then works as planned. (I've mentioned it here in case it helps debugging (it's a problem with the if statement, not the cp statement) and in case any other Mac user is reading this.)
Many thanks again for making it public — really appreciate it!
I'll leave it open for people to see, great job figuring it out!
Thanks Dawid!
On 15 Apr 2018, at 18:57, Dawid Eckert [email protected] wrote:
I'll leave it open for people to see, great job figuring it out!
— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/daedreth/ihsec/issues/5#issuecomment-381425150, or mute the thread https://github.com/notifications/unsubscribe-auth/ACxw7FsIWRHLpaJ1r3TRY7ZbWjJJgzL_ks5to4ntgaJpZM4R6Tal.
The 1st problem I found with the 'if' statement is that the regex symbol $
is not escaped properly, thus giving us the output @brookter provides.
It seems there is another issue that I'm still researching on Linux. I don't think that the makefile is being interpreted by bash correctly (or when it is, it spits out the entire statement as if I appended echo before the statement). I will record anything else I find in issue #7 .