WP8应用程序的通用存储位置 [英] Common storage location for WP8 apps

查看:56
本文介绍了WP8应用程序的通用存储位置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


我正在尝试创建一个WP8应用程序,该应用程序针对门户进行身份验证并获取身份验证cookie。



我希望能够将这个cookie存储在某些"公共存储"中。在手机内,以便其他应用程序也可以访问它。这样,一旦应用程序针对门户进行身份验证,其他需要访问此
cookie的应用程序可以简单地转到公共存储并获取它而不是认证应用程序"传递"。周围的cookie。



换句话说:



  1. 认证应用程序联系人UAG,获取cookie,商店位于一些常见的可访问位置 - 假设文件是​​C:\ tmp \ foo.txt(使用我知道的noddy文件路径)

  2. 当用户现在启动其他应用程序时,应用程序首先检查文件C:\ tmp \ foo.txt是否存在,以及如果它,它消耗它和继续前进



从我所看到的,没有简单的方法这样做。似乎没有一个共同的存储区域适用于所有应用程序。以上是否可能?我试图避免使用skydrive,因为我想要存储在"foo.txt"中的数据是敏感的。



谢谢



PS:其他应用程序可以访问存储照片的地方。这是特定于该文件夹吗?如果是这样,可以我们把其他内容放进去了吗?

解决方案


应用程序模型的设计目的是相互之间的沙盒应用程序,包括共享数据;这消除了应用程序影响其他应用程序的可能性(无意或恶意)。


这会留下Skydrive或您自己的私人服务器。您可以加密数据。


或者,因为从理论上讲,只有您的应用才会知道您的机制,您可以发布实际包含相当于多个应用的​​应用更新(例如,它可能有一个主菜单,用户选择"子应用"。
实际上它是一个应用,所有子应用都可以访问彼此的数据。


希望这会有所帮助,但是b $ b Mark 


I'm trying to create a WP8 application which authenticates against a portal and gets an authentication cookie.

I would like to be able to store this cookie in some "common storage" within the phone, so that other applications are able to access it as well. This way, once the application authenticates against the portal, other apps which need access to this cookie can simply go to the common storage and fetch it rather than the authentication application "passing" the cookie around.

In other words:

  1. Authentication app contacts UAG, gets a cookie, stores is in some common accessible location - lets say the file is C:\tmp\foo.txt (using a noddy filepath I know)
  2. When the user now launches some other app, the app first checks to see if the file C:\tmp\foo.txt exists, and if it does, it consumes it and carries forward

From what I have read, there is no easy way to do so. It seems there isn't a common storage area available for all apps. Is the above possible? I am trying to avoid using skydrive since the data I want to store in "foo.txt" is sensitive.

Thanks

PS: The place where photos are stored is accessible to other apps. Is that specific to that folder? IF so, can we put other content in it?

解决方案

Hi,

The application model was designed to sandbox apps from each other, including sharing data; this eliminates the possibility of apps affecting other apps (inadvertently or maliciously).

This leaves Skydrive or your own private server. You could encrypt the data.

Alternately, since in theory only your apps will be aware of your mechanism, you could release updates of your app that actually contains the equivalent of multiple apps (for example it could have a main menu where the user chooses a "sub-app". Since in reality it is a single app, all the sub-apps have access to each others' data.

Hope this helps,
Mark 


这篇关于WP8应用程序的通用存储位置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆