共享keychain数据
【共享keychain数据】
当往keychain中插入数据时,默认的 kSecAttrAccessGroup 就是App自身的BundleID。
【官方文档】
You can add a keychain-access-groups entitlement to the application and, in the entitlement property list file, specify an array of keychain access groups to which the application belongs.
可以在entitlements文件中指定keychain-access-groups属性。此属性下定义了一组字符串标识。
If you add such a property-list file to the application bundle, then the access group corresponding to the application-identifier entitlement is treated as the last element in the access groups array.
如果添加了keychain-access-group选项,那原有的app BundleID会被加入到最后一项。
If you do not include the kSecAttrAccessGroup key in the attributes dictionary when you call the SecItemAdd function to add an item to the keychain, the function uses the first access group in the array by default.
如果没有指定kSecAttrAccessGroup键,SecItemAdd函数默认使用第一个group值。
If there is no kSecAttrAccessGroup key in the attributes dictionary and there is no keychain-access-groups entitlement in the application bundle, then the access group of a newly created item is the value of the application-identifier entitlement.
如果没有指定kSecAttrAccessGroup键,也没有设置keychain-acess-group选项,则使用App BundleID作为kSecAttrAccessGroup的值。
【其它要求】
When you want to create an app that can share keychain access with an existing app you need to make sure that you use the bundle seed ID of the existing app. You do this when you create the new App ID in the iPhone Provisioning Portal. Instead of generating a new value you select the existing value from the list of all your previous bundle seed IDs.
若要共享keychain数据,两个App的bundle seed id必须相同。
The keychain access group can be named pretty much anything you want as long as it starts with the bundle seed ID.
keychain-acess-group必须以同样的bundle seed id开头。
参考:http://useyourloaf.com/blog/2010/04/03/keychain-group-access.html
共享keychain数据的更多相关文章
- 采用EaglePHP框架解决分布式集群服务器利用MEMCACHE方式共享SESSION数据的问题
一.问题起源 稍大一些的网站,通常都会有好几个服务器,每个服务器运行着不同功能的模块,使用不同的二级域名,而一个整体性强的网 站,用户系统是统一的,即一套用户名.密码在整个网站的各个模块中都是可以登录 ...
- PHP 实现多服务器共享 SESSION 数据
PHP 实现多服务器共享 SESSION 数据 2011 年 12 月 05 日评论暂缺 一.问题起源 稍大一些的网站,通常都会有好几个服务器,每个服务器运行着不同功能的模块,使用不同的二级域名,而一 ...
- 黄聪:多个wordpress网站(不同域名)共享用户数据的方法
WordPress可以自定义用户数据表,这样多个wordpress网站就可以共享用户数据了,有时候这是非常方便的,这些Wordpress站点应该安装在同一个数据库下,数据表前缀各不相同.由于Wordp ...
- win7下设置挂载Linux服务器nfs共享的数据 -- 转
最近学习NFS文件系统的使用,Ubuntu上配置好了,想和Win7共享数据,所以网上搜到了这篇文章.借花献佛,跟大家共享一下: http://www.2cto.com/os/201207/139132 ...
- Android之 内容提供器(1)——使用内容提供器访问其它程序共享的数据
(下面内容是阅读郭霖大神的<第一行代码>总结的) 1 概述 内容提供器是Android实现跨程序共享数据的标准方式. 内容提供器的的使用方法有两种, 一是使用已有的内容提供器对其他程序的数 ...
- 多域名THINKPHP利用MEMCACHE方式共享SESSION数据(转)
一.问题起源 稍大一些的网站,通常都会有好几个服务器,每个服务器运行着不同功能的模块,使用不同的二级域名,而一个整体性强的网站,用户系统是统一的,即一套用户名.密码在整个网站的各个模块中都是可以登录使 ...
- windows笔记-在可执行文件或DLL的多个实例之间共享静态数据
全局数据和静态数据不能被同一个. exe或DLL文件的多个映像共享,这是个安全的默认设置.但是,在某些情况下,让一个. exe文件的多个映像共享一个变量的实例是非常有用和方便的. 每个. exe或DL ...
- 【Android Developers Training】 31. 序言:共享简单数据
注:本文翻译自Google官方的Android Developers Training文档,译者技术一般,由于喜爱安卓而产生了翻译的念头,纯属个人兴趣爱好. 原文链接:http://developer ...
- android中共享全局数据的方法
转自:http://blog.csdn.net/ameyume/article/details/6100756 我们在平时的开发中,有时候可能会需要一些全局数据,来让应用中的所有Activity和Vi ...
随机推荐
- kettle环境变量的设置和获取
1. 变量的类型Kettle 的早期版本中的变量只有系统环境变量目前版本中(3.1) 变量包括系统环境变量, "Kettle变量" 和内部变量三种 系统环境变量的影响范围很广,凡是 ...
- 【转】Java transient关键字使用小记
哎,虽然自己最熟的是Java,但很多Java基础知识都不知道,比如transient关键字以前都没用到过,所以不知道它的作用是什么,今天做笔试题时发现有一题是关于这个的,于是花个时间整理下transi ...
- 【转】Java常量池详解
今天My partner问我一个让他头疼的Java question,求输出结果: /** * * @author DreamSea 2011-11-19 */ public class Intege ...
- jsp---猜数字游戏,深有感触
猜数字游戏注意两点.1.随机数和猜的数字不能放在同一个页面,不然随机数不停出现,猜的数字不可能相等的. 2.数据类型的相互转换.包装类Integer和int的用法,前者是类,后者是基本数据类型 cai ...
- [转]JavaScript RegExp 对象参考手册
JavaScript RegExp 对象参考手册 RegExp 对象 RegExp 对象表示正则表达式,它是对字符串执行模式匹配的强大工具. 直接量语法 /pattern/attributes 创建 ...
- 6.9-JDBC
一.JDBC 步骤: 1.加载驱动 2.创建连接 3.创建Statement或PreparedStatement 4.遍历结果集 5.释放资源 二.PrepareStatement sql注入: Pr ...
- 生成Excel
生成Excel 需要引用MyXls.SL2.dll的类库: 下载地址:http://sourceforge.net/projects/myxls/ 命名空间using org.in2bits.MyXl ...
- 【BZOJ】1801 [Ahoi2009]chess 中国象棋(dp)
题目 传送门:QWQ 分析 发现我们关心的不是棋子的位置,我们只关心棋子数量就ok. 首先每行每列最多两个棋子.这是显然的. 然后我觉得本题最难的部分就是对行进行讨论,蒟蒻我一直被限制在了对格点讨论. ...
- HDFS文件系统
Hadoop 附带了一个名为 HDFS(Hadoop分布式文件系统)的分布式文件系统,专门存储超大数据文件,为整个Hadoop生态圈提供了基础的存储服务. 本章内容: 1) HDFS文件系统的特点,以 ...
- Sublime Text 3 安装+注册+汉化
参考:https://www.cnblogs.com/h--d/p/7555119.html