Besclient not running

We are trying to run below command on our Win2k8 & Win2k12 servers but its failing from all server but when we are trying to run it locally (without using besclient) it running fine.

waithidden cmd.exe /C %windir%\system32\inetsrv\appcmd.exe set config /section:requestfiltering /+verbs.[verb='OPTIONS',allowed='false']

Its even not running with fixlet debugger however same command perfectly running on Win2k16 with besclient & fixlet debugger.

I have tried below options too-

waithidden cmd.exe /C {(pathname of system folder)}\inetsrv\appcmd.exe set config /section:requestfiltering /+verbs.[verb='OPTIONS',allowed='false']

dos C:\windows\system32\inetsrv\appcmd.exe set config /section:requestfiltering /+verbs.[verb='OPTIONS',allowed='false']

From Fixlet Debugger I also tried running through batch job but that also failed.

Its showing EXIT CODE 1413 (Invalid Index), I search web for that but no luck.

And while running it through batch file its showing as-
Error (message:unknown attribute "verbs.[verb='OPTIONS',allowed='false']". Replace with -? for help. )

any suggestion please.

For running in Bigfix, you won’t be able to use %variable%, that’s a cmd.exe shell variable.

You’ll also need to disable 32-bit redirection using
action uses wow64 redirection false
on any line before the waithidden. Using pathname of native system folder to locate the windows\system32 folder is a good substitution to use.

As far as getting IIS to work correctly, … I’m afraid that’s up to you. You’ll definitely need to get a working command line before you can deploy it via a task.

1 Like

Yes it could be the one possibility i’ll try that, but Jason, if you have seen my test cases it should be working when I am trying to go with absolute path or putting relevance pathname of native system folder to system folder or even try to run it through batch job.

It really strange when its working with any method I tried earlier for my Win10 64bit & Win 2016 64bit server.

This won’t work, you have to actually use action uses wow64 redirection false to get BigFix to invoke the 64bit stuff, because otherwise windows redirects it.

It would definitely be the first thing I would try. The next would be to try to get more verbose logging.

Try something like this:

action uses wow64 redirection false
waithidden cmd.exe /C /S "C:\windows\system32\inetsrv\appcmd.exe set config /section:requestfiltering /+verbs.[verb='OPTIONS',allowed='false']" > C:\Windows\Temp\bigfix_appcmd.log

This page suggests the error might be related to a parameter issue: https://www.codeproject.com/Questions/226633/Crystal-Report-Invalid-index-Exception-from-HRESUL

Related: CMD.exe (Command Shell) - Windows CMD - SS64.com

1 Like