Friday, June 2, 2017

Files\Java\jdk1.8.0_131) was unexpected at this time.

The possible issue could be related to the JAVA_HOME environment variable value. If the value is referring to a path like below you will most likely get this kind of error.
Ex:
C:\Program Files\Java\jdk1.8.0_131

Solution (that worked for me): 

1. Change the JDK path as provided below:
     C:\Program~1\Java\jdk1.8.0_131

Note for Windows users on 64-bit systems
Progra~1 = 'Program Files'Progra~2 = 'Program Files(x86)'

Please refer the below link knowing more about setting the JAVA_HOME.
Site Link:  Set JAVA_HOME

Friday, February 3, 2017

CSS3114: @font-face failed OpenType embedding permission check. Permission must be Installable (Google Fonts Offline)

Error: CSS3114: @font-face failed OpenType embedding permission check. Permission must be Installable

Solution: Add mimemap to web.config file under <system.webServer> section


Script:
<staticcontent>
      <remove fileextension=".woff"/>
      <mimemap fileextension=".woff" mimetype="application/octet-stream"/>
</staticcontent>


Creating Self Signed Certificate with MAKECERT.EXE - ( HTTPS SHA256)

1. Find MakeCert.Exe in your machine, the path depends on the OS. If you have VisualStudio, open the Visual Studio Command Prompt and run the below scripts.

Script:
#1. Root Cert
makecert -r -n "CN=IPMRootCert" -pe -sv IPMRootCert.pvk -a sha1 -len 2048 -b 01/01/2014 -e 01/21/2050 -cy authority IPMRootCert.cer
pvk2pfx.exe -pvk IPMRootCert.pvk -spc IPMRootCert.cer -pfxIPMRootCert.pfx

#2. Project Cert
makecert.exe -iv IPMRootCert.pvk -ic IPMRootCert.cer -n "CN=cissipm.ed.gov" -pe -sv cissipm.ed.gov.pvk -a sha1 -len 2048 -b 01/21/2010 -e 01/21/2050 -sky exchange cissipm.ed.gov.cer -eku 1.3.6.1.5.5.7.3.1
pvk2pfx.exe -pvk cissipm.ed.gov.pvk -spc cissipm.ed.gov.cer -pfx cissipm.ed.gov.pfx


2. Script 1 above, creates the Root Certificate (three certs .pfx, .pvk, .cer). For Windows OS, import .pfx (To Personal) and .cer (To Trusted Root Folder) certificates using Cert Manager

3. Script 2 above, creates the project or application Certificate (three certs .pfx, .pvk, .cer). For Windows OS, import .pfx (To Personal) and .cer (To Trusted Root Folder) certificates using Cert Manager



Wednesday, November 2, 2016

Refresh FAST Search Certificate With PowerShell

Question: How to refresh/re-apply a FAST Search Certificate in SharePoint 2010 Environment?

Solution: Apply certificate using PowerShell. The below code shows how to generate FAST Search certificate (self signed) and apply it in the environment.


Script:

###################################
# Apply Certificate to FAST
###################################

Clear
Remove-PSSnapin AdminSnapIn -ErrorAction SilentlyContinue
Remove-PSSnapin Microsoft.FASTSearch.PowerShell -ErrorAction SilentlyContinue
Remove-PSSnapin Microsoft.SharePoint.PowerShell -ErrorAction SilentlyContinue

Add-PSSnapin AdminSnapIn
Add-PSSnapin Microsoft.FASTSearch.PowerShell
Add-PSSnapin Microsoft.SharePoint.PowerShell

write-host "Applying Certificate to FAST" -ForegroundColor Green
#Release worker processess with IISRESET
iisreset

stop-service FAST*

$installerdir = $env:FASTSEARCH + "installer\scripts"
echo $installerdir
cd $installerdir
$pw = ConvertTo-SecureString -AsPlainText -force test
.\ReplaceDefaultCertificate.ps1 -generateNewCertificate $true -certificatePassword $pw
$cert = @(dir cert:\LocalMachine\My -recurse | ? { $_.Subject -eq 'CN=FASTSearchCert' })[0]
$thumb = $cert.Thumbprint

Start-service FAST*

.\SecureFASTSearchConnector.ps1 -certThumbprint $thumb -ssaName "FAST Content" -username "domain\FastSearchAccount"


Wednesday, December 16, 2015

Convert VHD file to VHDX - Hyper-V

Requirement: Convert VHD to VHDX using Powershell

Script:
 PS C:\windows\system32> Convert-VHD –Path "C:\Me\IE10 - Win7.vhd" –DestinationPath "C:\ME\My Machines\Windows 7 IE 10\Virtual Hard Disks\IE10 - Win7.vhdx"  
 PS C:\windows\system32>   

Access to XMLHttpRequest at 'from origin has been blocked by CORS policy: Cross origin requests are only supported for protocol schemes: http, data, chrome, chrome-extension, https. .net core angular

Issue: The angular application was getting error from API that the origin has been blocked by CORS policy. Solution: Make sure that the...