From 4fc85a975104ce24725e4203c8a61f9fdbc10bd8 Mon Sep 17 00:00:00 2001 From: CentOS Buildsys Date: Jan 06 2014 23:00:56 +0000 Subject: import esc-1.1.0-27.el7.src.rpm --- diff --git a/SOURCES/esc-1.1.0-fix22.patch b/SOURCES/esc-1.1.0-fix22.patch new file mode 100644 index 0000000..d99af86 --- /dev/null +++ b/SOURCES/esc-1.1.0-fix22.patch @@ -0,0 +1,294 @@ +diff -up ./esc/src/app/xul/esc/application.ini.fix22 ./esc/src/app/xul/esc/application.ini +--- ./esc/src/app/xul/esc/application.ini.fix22 2013-11-27 14:14:24.118638587 -0800 ++++ ./esc/src/app/xul/esc/application.ini 2013-11-27 14:14:24.132638588 -0800 +@@ -25,11 +25,11 @@ Vendor=RedHat + Name=ESC + ; + ; This field specifies your application's version. This field is optional. +-Version=1.1.0-25 ++Version=1.1.0-26 + ; + ; This field specifies your application's build ID (timestamp). This field is + ; required. +-BuildID=0000001025 ++BuildID=0000001026 + ; + ; This ID is just an example. Every XUL app ought to have it's own unique ID. + ; You can use the microsoft "guidgen" or "uuidgen" tools, or go on +diff -up ./esc/src/app/xul/esc/chrome/content/esc/ESC.js.fix22 ./esc/src/app/xul/esc/chrome/content/esc/ESC.js +--- ./esc/src/app/xul/esc/chrome/content/esc/ESC.js.fix22 2013-11-27 14:14:24.016638584 -0800 ++++ ./esc/src/app/xul/esc/chrome/content/esc/ESC.js 2013-11-27 14:30:07.758668142 -0800 +@@ -57,6 +57,7 @@ const ESC_SECURITY_URL="esc.security.ur + const ESC_SECURE_URL="esc.secure.url"; + const ESC_GLOBAL_PHONE_HOME_URL= "esc.global.phone.home.url"; + const ESC_HIDE_FORMAT="esc.hide.format"; ++const ESC_ALLOW_NOTIFICATIONS="esc.allow.notifications"; + + const CLEAN_TOKEN = "cleanToken"; + const UNINITIALIZED = 1; +@@ -76,6 +77,7 @@ const ENROLL_WINDOW = "esc.xul"; + const ADMIN_WINDOW = "settings.xul"; + const HIDDEN_WINDOW = "hiddenWindow.xul"; + const SECURITY_WINDOW = "security.xul"; ++const PHONE_WINDOW = "config.xul"; + + + //Log level constants +@@ -230,10 +232,14 @@ var Status_Messages = new Array( + function DoPhoneHome(keyType,keyID) + { + CoolKeyLogMsg(PR_LOG_ALWAYS,"Attempting to phone home for Key " + keyID); ++ var allowNotify = null; + var callback = function (aResult) { + + recordMessage("In DoPhoneHome callback"); + ++ var allowNotify = DoCoolKeyGetConfigValue(ESC_ALLOW_NOTIFICATIONS); ++ ++ + var issuer = ""; + if(aResult == true) + { +@@ -241,7 +247,10 @@ function DoPhoneHome(keyType,keyID) + if(!issuer) + issuer = getBundleString("unknownIssuer"); + recordMessage("In DoPhoneHome callback success issuer " + issuer); +- TraySendNotificationMessage(getBundleString("keyInserted"),"\"" + issuer +"\"" + " " + getBundleString("keyInsertedComputer"),3,4000,GetESCNotifyIconPath(keyType,keyID)); ++ ++ if(allowNotify == "yes") { ++ TraySendNotificationMessage(getBundleString("keyInserted"),"\"" + issuer +"\"" + " " + getBundleString("keyInsertedComputer"),3,4000,GetESCNotifyIconPath(keyType,keyID)); ++ } + LogKeyInfo(keyType,keyID,"Key Inserted ..."); + UpdateRowWithPhoneHomeData(keyType,keyID); + recordMessage("cached issuer " + issuer); +@@ -262,7 +271,9 @@ function DoPhoneHome(keyType,keyID) + if(!issuer) + issuer = getBundleString("unknownIssuer"); + recordMessage("Phone home callback failed , issuer " + issuer); +- TraySendNotificationMessage(getBundleString("keyInserted"),"\"" + issuer +"\"" + " " + getBundleString("keyInsertedComputer"),3,4000,GetESCNotifyIconPath(keyType,keyID)); ++ if (allowNotify == "yes") { ++ TraySendNotificationMessage(getBundleString("keyInserted"),"\"" + issuer +"\"" + " " + getBundleString("keyInsertedComputer"),3,4000,GetESCNotifyIconPath(keyType,keyID)); ++ } + LogKeyInfo(keyType,keyID,"Key Inserted ..."); + } + } +@@ -271,6 +282,7 @@ function DoPhoneHome(keyType,keyID) + + var home = DoCoolKeyGetIssuerUrl(keyType,keyID); + ++ //home = null; + recordMessage("Returned IssuerURL " + home); + + if(IsPhoneHomeCached(keyID) && home) +@@ -279,7 +291,12 @@ function DoPhoneHome(keyType,keyID) + + recordMessage("Phone home info cached..."); + issuer = GetCoolKeyIssuer(keyType,keyID); +- TraySendNotificationMessage(getBundleString("keyInserted"),"\"" + issuer +"\"" + " " + getBundleString("keyInsertedComputer"),3,4000,GetESCNotifyIconPath(keyType,keyID)); ++ ++ allowNotify = DoCoolKeyGetConfigValue(ESC_ALLOW_NOTIFICATIONS); ++ if (allowNotify == "yes") { ++ TraySendNotificationMessage(getBundleString("keyInserted"),"\"" + issuer +"\"" + " " + getBundleString("keyInsertedComputer"),3,4000,GetESCNotifyIconPath(keyType,keyID)); ++ } ++ + LogKeyInfo(keyType,keyID,"Key Inserted ..."); + + var launchBrowserURL = GetCachedEnrolledTokenBrowserURL(keyID); +@@ -534,7 +551,11 @@ function GetAuthDataFromPopUp(aKeyType,a + keyUITable[aKeyID] = aUiData; + keyTypeTable[aKeyID] = aKeyType; + +- var child = window.open("chrome://esc/content/GenericAuth.xul", aKeyID, "chrome,centerscreen,width=400,height=250"); ++ var child = window.open("chrome://esc/content/GenericAuth.xul", aKeyID, "chrome,centerscreen,width=400,height=250,dialog"); ++ ++ if (child) { ++ child.setTimeout("focus()", 1000); ++ } + + curChildWindow = child; + } +@@ -1275,7 +1296,7 @@ function UpdateEnrollmentArea(keyType,ke + + var numUnenrolledKeys = DoGetNumUnenrolledCoolKeys(); + +- //alert("inserted " + inserted + " showFulUI " + showFullUI + " showExternalUI " + showExternalUI + " already enrolled " + alreadyEnrolled + " numUnenrolledKeys " + numUnenrolledKeys); ++ // alert("inserted " + inserted + " showFulUI " + showFullUI + " showExternalUI " + showExternalUI + " already enrolled " + alreadyEnrolled + " numUnenrolledKeys " + numUnenrolledKeys); + + + var ui_id = document.getElementById("esc-ui"); +@@ -1290,7 +1311,7 @@ function UpdateEnrollmentArea(keyType,ke + { + if(!numUnenrolledKeys) + { +- ui_id.setAttribute("src",null); ++ ui_id.setAttribute("src",""); + } + else + { +@@ -1427,14 +1448,19 @@ function UpdateEnrollmentArea(keyType,ke + HideItem(no_key_area); + } + ++ + if(!alreadyEnrolled && inserted && showExternalUI) + { + UpdateESCSize(); ++ gEnrollmentPage.setTimeout("focus();",3500); + return; + } + + if(!showExternalUI) + UpdateESCSize(); ++ ++ gEnrollmentPage.setTimeout("focus();",3500); ++ + } + + //Evaulate Password Quality +@@ -2006,7 +2032,7 @@ function SelectESCPage(keyType,keyID,pho + break; + } + +- //alert("SelectESCPage initialized " + keyUninitialized + " gEnrollmentPage " + gEnrollmentPage + " gFactoryMode " + gFactoryMode + " gHiddenPage " + gHiddenPage); ++ //alert("SelectESCPage uninitialized " + keyUninitialized + " gEnrollmentPage " + gEnrollmentPage + " gFactoryMode " + gFactoryMode + " gHiddenPage " + gHiddenPage + " phoneHomeFailed " + phoneHomeFailed + " no_launch_external_ui " + no_launch_external_ui); + + //Get the primary page windows if present + +@@ -2022,14 +2048,7 @@ function SelectESCPage(keyType,keyID,pho + + if(keyUninitialized == UNINITIALIZED && !phoneHomeFailed && !no_launch_external_ui ) //formatted uninitialized card + { +- if(enrollWnd) //Enrollment window is already up +- { +- enrollWnd.focus(); +- } +- else +- { +- launchESC(); +- } ++ launchESC(); + } + else + { +@@ -2975,8 +2994,9 @@ function OnCoolKeyInserted(keyType, keyI + + var uninitialized = 0; + +- recordMessage("Key inserted!" + "Window " + IdentifyWindow()); ++ var allowNotify = DoCoolKeyGetConfigValue(ESC_ALLOW_NOTIFICATIONS); + ++ recordMessage("Key inserted!" + "Window " + IdentifyWindow()); + if(gHiddenPage) + { + TrayShowNotificationIcon(); +@@ -2993,6 +3013,7 @@ function OnCoolKeyInserted(keyType, keyI + + gCurrentSelectedRow = row; + UpdateEnrollmentArea(keyType,keyID,1); ++ + } + + if(gAdminPage) +@@ -3017,7 +3038,9 @@ function OnCoolKeyInserted(keyType, keyI + if(!issuer ) + issuer = getBundleString("unknownIssuer"); + +- TraySendNotificationMessage(getBundleString("keyInserted"),"\"" + issuer +"\"" + " " + getBundleString("keyInsertedComputer"),3,4000,GetESCNotifyIconPath(keyType,keyID)); ++ if( allowNotify) { ++ TraySendNotificationMessage(getBundleString("keyInserted"),"\"" + issuer +"\"" + " " + getBundleString("keyInsertedComputer"),3,4000,GetESCNotifyIconPath(keyType,keyID)); ++ } + + } + +@@ -3037,6 +3060,8 @@ function OnCoolKeyRemoved(keyType, keyID + + var row = GetRowForKey(keyType, keyID); + ++ var allowNotify = DoCoolKeyGetConfigValue(ESC_ALLOW_NOTIFICATIONS); ++ + if(gHiddenPage) + { + if(curChildWindow) +@@ -3047,7 +3072,9 @@ function OnCoolKeyRemoved(keyType, keyID + var issuer = GetCoolKeyIssuer(keyType,keyID); + if(!issuer) + issuer = getBundleString("unknownIssuer"); +- TraySendNotificationMessage(getBundleString("keyRemoved"),"\"" + issuer + "\"" + " " + getBundleString("keyRemovedComputer"),1,4000,GetESCNotifyIconPath(keyType,keyID)); ++ if (allowNotify == "yes") { ++ TraySendNotificationMessage(getBundleString("keyRemoved"),"\"" + issuer + "\"" + " " + getBundleString("keyRemovedComputer"),1,4000,GetESCNotifyIconPath(keyType,keyID)); ++ } + LogKeyInfo(keyType,keyID, "Key Removed ..."); + + } +@@ -3345,6 +3372,7 @@ uiListener = + + if(url != esc_enroll_uri) + { ++ + MyAlert(getBundleString("errorEnrollmentUI")); + + if(uiListener) +@@ -3978,17 +4006,24 @@ function launchCONFIG(keyType,keyID) + platform = "mac"; + } + +- var wind = null; ++ var wind = IsPageWindowPresent(PHONE_WINDOW); + +- if(platform == "mac") +- { +- wind = window.openDialog("chrome://esc/content/config.xul",keyID,"chrome,centerscreen,resizable,modal=no"); +- } +- else +- { +- wind = window.openDialog("chrome://esc/content/config.xul",keyID,"chrome,centerscreen,resizable,modal=yes"); ++ if (!wind) { ++ if(platform == "mac") ++ { ++ wind = window.openDialog("chrome://esc/content/config.xul",keyID,"chrome,centerscreen,resizable,modal=no"); ++ } ++ else ++ { ++ wind = window.openDialog("chrome://esc/content/config.xul",keyID,"chrome,centerscreen,resizable"); ++ ++ } ++ } + ++ if(wind) { ++ wind.setTimeout("focus();",1500); + } ++ + } + + //Launch cert viewer if key has certs +@@ -4046,12 +4081,12 @@ function launchESC() + + if(!enrollWnd) + { +- var wind = window.open("chrome://esc/content/esc.xul","","chrome,resizable,centerscreen,dialog"); ++ enrollWnd = window.open("chrome://esc/content/esc.xul","","chrome,resizable,centerscreen,dialog"); + + } +- else +- { +- enrollWnd.focus(); ++ ++ if(enrollWnd) { ++ enrollWnd.setTimeout("focus();",1500); + } + + } +diff -up ./esc/src/app/xul/esc/defaults/preferences/esc-prefs.js.fix22 ./esc/src/app/xul/esc/defaults/preferences/esc-prefs.js +--- ./esc/src/app/xul/esc/defaults/preferences/esc-prefs.js.fix22 2009-03-28 17:54:57.000000000 -0700 ++++ ./esc/src/app/xul/esc/defaults/preferences/esc-prefs.js 2013-11-27 14:14:24.133638588 -0800 +@@ -29,6 +29,10 @@ pref("esc.tps.message.timeout","90"); + + pref("esc.windows.do.capi","yes"); + ++#Do we allow card notifications? Default no. ++ ++pref("esc.allow.notifications", "no"); ++ + + #Sample Security Officer Enrollment UI + diff --git a/SPECS/esc.spec b/SPECS/esc.spec index 646e2f1..ce972cb 100644 --- a/SPECS/esc.spec +++ b/SPECS/esc.spec @@ -1,6 +1,6 @@ Name: esc Version: 1.1.0 -Release: 25%{?dist} +Release: 27%{?dist} Summary: Enterprise Security Client Smart Card Client License: GPL+ URL: http://directory.fedoraproject.org/wiki/CoolKey @@ -37,6 +37,7 @@ Patch18: esc-1.1.0-fix18.patch Patch19: esc-1.1.0-fix19.patch Patch20: esc-1.1.0-fix20.patch Patch21: esc-1.1.0-fix21.patch +Patch22: esc-1.1.0-fix22.patch BuildRequires: doxygen fontconfig-devel freetype-devel >= 2.1 BuildRequires: glib2-devel libIDL-devel atk-devel gtk2-devel libjpeg-devel @@ -74,7 +75,7 @@ AutoReqProv: 0 %define escrpmdir rpm %define escxulchromeicons %{escxuldir}/chrome/icons/default %define escdaemon escd -%define geckoversion 24.0 +%define geckoversion 24.2.0 Source0: http://pki.fedoraproject.org/pki/sources/%name/%{escname}.tar.bz2 Source1: http://pki.fedoraproject.org/pki/sources/%name/esc @@ -113,6 +114,7 @@ cryptographic smartcards. %patch19 -p1 -b .fix19 %patch20 -p1 -b .fix20 %patch21 -p1 -b .fix21 +%patch22 -p1 -b .fix22 %build @@ -252,6 +254,14 @@ if [ -x %{_bindir}/gtk-update-icon-cache ]; then fi %changelog +* Mon Jan 06 2014 Jack Magne - 1.1.0-27 +- Resolves: Bug 1048856 - esc does not build on RHEL 7 +* Fri Dec 27 2013 Daniel Mach - 1.1.0-27 +- Mass rebuild 2013-12-27 + +* Wed Nov 27 2013 Jack Magne =1.1.0-26 +- Resolves: #1033779 - Mouse move on a locked screen display Smart Card Manager smart card insert/removal event notifications. +- Resolves: #1033220 - ESC phone home/authentication dialog should pop it to top of window stack to get focus * Thu Nov 7 2013 Jack Magne =1.1.0-25 - Resolves: #1027777 - rebuild esc against new xulrunner (ESR24). * Mon Nov 4 2013 Jack Magne =1.1.0-24