* @param pcrData: White list data sent by the user
* @return : true if the call is successful or else exception.
*/
public String updatePCRWhiteList(PCRWhiteList pcrData) {
TblMle tblMle;
TblPcrManifest tblPcr;
try {
tblMle = getMleDetails(pcrData.getMleName(),
pcrData.getMleVersion(), pcrData.getOsName(),
pcrData.getOsVersion(), pcrData.getOemName());
if (tblMle == null && pcrData.getOemName() != null) {
throw new ASException(ErrorCode.WS_MLE_OEM_DOES_NOT_EXIST, pcrData.getMleName(), pcrData.getMleVersion(), pcrData.getOemName());
}
if (tblMle == null && pcrData.getOsName() != null) {
throw new ASException(ErrorCode.WS_MLE_OS_DOES_NOT_EXIST, pcrData.getMleName(), pcrData.getMleVersion(), pcrData.getOsName(),pcrData.getOsVersion());
}
// Now we need to check if PCR is already configured. If yes, then
// we ned to ask the user to use the Update option instead of create
tblPcr = getPCRWhiteListDetails(tblMle.getId(), pcrData.getPcrName());
if (tblPcr == null) {
throw new ASException(ErrorCode.WS_PCR_WHITELIST_DOES_NOT_EXIST, pcrData.getPcrName());
}
// Now update the pcr in the database.
tblPcr.setValue(pcrData.getPcrDigest());
pcrManifestJpaController.edit(tblPcr);
} catch (ASException ase) {
throw ase;
} catch (Exception e) {