I was able to resolve this issue.
This was the error in Windows events-
Event ID: 11722 Product:
Cisco AnyConnect Secure Mobility Client -- Error 1722.
There is a problem with this Windows Installer package.
A program run as part of the setup did not finish as expected.
Contact your support personnel or package vendor.
Action kdf_acsock64_Install, location:
C:\Program Files (x86)\Cisco\Cisco AnyConnect Secure Mobility Client\VACon64.exe, command: kdf -install "C:\Program Files (x86)\Cisco\Cisco AnyConnect Secure Mobility Client\\" acsock
ISSUE
Virus damaged the Windows Firewall and Firewall service wasn’t running. When AnyConnect tried to register itself with the Firewall, it failed as the Firewall was damaged.
RESOLUTION
We decided to reimage the computer rather than fixing the issue. Reason- the Virus might have caused other damages that we were not able to detect.