diff options
author | mark@chromium.org <mark@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-15 22:11:28 +0000 |
---|---|---|
committer | mark@chromium.org <mark@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2012-05-15 22:11:28 +0000 |
commit | f0c58de58e969865a768f042c0798a8a5ab93d8f (patch) | |
tree | fc19d6805cfdd25330a92b8a2db8401d924cebb0 /base/mac/foundation_util.mm | |
parent | e97990f160025b5fcaed515c2cbc4a6336c2b332 (diff) | |
download | chromium_src-f0c58de58e969865a768f042c0798a8a5ab93d8f.zip chromium_src-f0c58de58e969865a768f042c0798a8a5ab93d8f.tar.gz chromium_src-f0c58de58e969865a768f042c0798a8a5ab93d8f.tar.bz2 |
Activate Keychain reauthorization.
If the KeychainReauthorizeInAppMay2012 preference doesn't exist or is less
than 2, Keychain reauthorization is performed at start-up. On successful
reauthorization, this preference will be set to 2. If unsuccessful, it will be
incremented by 1, giving a maximum of 2 unsuccessful attempts to perform this
procedure before getting on with life.
BUG=108238
TEST=none
Review URL: https://chromiumcodereview.appspot.com/10310174
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@137265 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/mac/foundation_util.mm')
-rw-r--r-- | base/mac/foundation_util.mm | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/base/mac/foundation_util.mm b/base/mac/foundation_util.mm index 891ec13..d62cba7 100644 --- a/base/mac/foundation_util.mm +++ b/base/mac/foundation_util.mm @@ -13,6 +13,14 @@ #include "base/mac/mac_logging.h" #include "base/sys_string_conversions.h" +typedef struct OpaqueSecTrustRef* SecACLRef; +typedef struct OpaqueSecTrustedApplicationRef* SecTrustedApplicationRef; + +extern "C" { +CFTypeID SecACLGetTypeID(); +CFTypeID SecTrustedApplicationGetTypeID(); +} // extern "C" + namespace base { namespace mac { @@ -289,7 +297,7 @@ CFCast<TypeCF##Ref>(const CFTypeRef& cf_val) { \ return NULL; \ } \ if (CFGetTypeID(cf_val) == TypeCF##GetTypeID()) { \ - return reinterpret_cast<TypeCF##Ref>(cf_val); \ + return (TypeCF##Ref)(cf_val); \ } \ return NULL; \ } \ @@ -312,6 +320,9 @@ CF_CAST_DEFN(CFNumber); CF_CAST_DEFN(CFSet); CF_CAST_DEFN(CFString); +CF_CAST_DEFN(SecACL); +CF_CAST_DEFN(SecTrustedApplication); + #undef CF_CAST_DEFN std::string GetValueFromDictionaryErrorMessage( |