Jeffrey Zhao 的个人资料Jeffrey's Own Box照片日志列表更多 工具 帮助

Zhao Jeffrey

职业
兴趣
我很知足,没有什么奢望。
我很贪心,我什么都想要。
第 1 张,共 4 张

Calendar

正在加载...

ASP.NET

正在加载...正在加载...

MSDN Magazine

正在加载...正在加载...

Jeffrey's Own Box

I wanna be a technical guy...forever...
11月14日

Test for Windows Live Writer

Hello, I'm trying Windows Live Writer Beta Edtion. The CnBlogs is broken so I can just use it in Windows Live Spaces. Hey!

Eh? Can I edit it?

That's great! Then...what about insert a picture?

I'm a C# programmer, so I'd like to paste Highlighted C# code using Highlight4Writer - a plugin for WLW. Lee see...

public void ProcessRequest(HttpContext context)
{
    string fileName = context.Request.QueryString["fileName"];
    int width = int.Parse(context.Request.QueryString["width"]);
    int height = int.Parse(context.Request.QueryString["height"]);
    string key = string.Format("{0}|{1}|{2}", fileName, width, height);

   
    context.Response.ContentType = "image/png";

    context.Response.WriteFile(GetImageFile(context, fileName, width, height));

    context.Response.End();
}

That's great!

Then...what about ASP.NET Code?

<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Lesson 2 - Demo 2 - AJAX-Style TreeView Control</title>
</head>
<body style="font-family:Verdana; font-size:12px;">
    <form id="form1" runat="server">

        <asp:TreeView runat="server" ID="TreeView1"
            ImageSet="Simple"
            OnTreeNodePopulate="TreeView1_TreeNodePopulate"
            PopulateNodesFromClient="true">
            <Nodes>
                <asp:TreeNode 
                    Text="Visual Studio 2005"
                    Value="E:\My Documents\Visual Studio 2005"
                    PopulateOnDemand="true"
                    Expanded="false" />
            </Nodes>
        </asp:TreeView>

    </form>
</body>
</html>

Cool!

What about this style?

 

Title
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
    <title>Lesson 2 - Demo 2 - AJAX-Style TreeView Control</title>
</head>
<body style="font-family:Verdana; font-size:12px;">
    <form id="form1" runat="server">
    
        <asp:TreeView runat="server" ID="TreeView1"
            ImageSet="Simple"
            OnTreeNodePopulate="TreeView1_TreeNodePopulate"
            PopulateNodesFromClient="true">
            <Nodes>
                <asp:TreeNode 
                    Text="Visual Studio 2005"
                    Value="E:\My Documents\Visual Studio 2005"
                    PopulateOnDemand="true"
                    Expanded="false" />
            </Nodes>
        </asp:TreeView>
    
    </form>
</body>
</html>

 

What about this kind of style?
public void ProcessRequest(HttpContext context)
{
    string fileName = context.Request.QueryString["fileName"];
    int width = int.Parse(context.Request.QueryString["width"]);
    int height = int.Parse(context.Request.QueryString["height"]);
    string key = string.Format("{0}|{1}|{2}", fileName, width, height);

   
    context.Response.ContentType = "image/png";

    context.Response.WriteFile(GetImageFile(context, fileName, width, height));

    context.Response.End();
}

Aha!

9月12日

有感Atlas的优点、缺点以及学习

Atlas的优点是什么?
 
  仁者见仁,智者见智。在这种问题上每个优秀的技术人员应该总是有自己独特的见解。能得到一个能“服众”的结论固然好,但是支持百家争鸣更为重要。我始终认为Atlas的最大长处不在于其Ajax特性,不在于其提供了复杂JS才能实现的多样化功能。在我看来,Atlas是很了不起的,而它的了不起体现在三个地方:
 
1. Declarative Syntax:
  应该有不少人有过在HTML Element中嵌入浏览器无法识别的属性,而在某个地方通过自己编写的Javascript方法读出并加以一些功能。其实我在数年前总觉得这样的方法是tricky solution。我不喜欢tricky的方法,特别是无条理性的tricky solution。这样的方法的确可以work,但是可读性一般比较差。在大多数时刻,我始终把代码的可维护性放在第一位。后来由于在项目中需要开发一个Rich Client,给用户以大量的操作自由度(描述不当,不过估计无法用三句两句话说清了),于是不得不使用了这个方法。在进行了大量尝试后,发现如果合理使用,这的确是一个非常灵活有效,并且易于维护的方法。ASP.NET强大的客户端Element模型又可以说对这种方法合作的几乎天衣无缝。

  Atlas的Declarative Scripts可以说将上面提到的这个方法进行了极大的升华。将一个从一开始似乎十分Tricky的方法变成了另一种开发方式,将程序设计和XML结合在了一起。事实上,这给了许多项目设计一个参考。将客户端代码的结构化也大大地提高了可维护性。

  原来,代码还可以这么写。
 
 
2. Extendable Behavior, Extender, etc.
  它们所作的贡献是提供了良好的设计。能让程序员轻松地写出符合良好设计的代码。

  一个良好设计的代码,其中一个非常基础的特点就是“high cohesion”,也就是“高内聚”。高内聚的组件与外界的依赖很少,这样大大方便了开发,调试,测试,发布和部署。

  就拿开发一个Extender来说,需要的就是写一个Class Library,并编译成一个程序集。使用时只需简单的引入,并像使用普通控件一般即可。在开发时需要的也仅仅是Atlas的基础结构,少得不能再少的一个程序集。

  还是一个典范,还是一个示例。
 
 
3. Powerful Foundational Framework
  这里不提Atlas提供了一个完全面向对象的编成框架,提供了一个Compat层来兼容多个浏览器等。现在来思考一个问题:如何写出高性能的Web应用程序?

  或者换个角度想一下,一个网站的性能是从什么方面体现出来的?这不光是要服务器端的努力,特别是现在客户端越来越Rich,客户端的Load也越来越多。优化PLT(Page Load Time)也是一个越来越重要的议题。这需要对于浏览器,HTML以及HTTP标准有相当完整的认识。通过分析Page Load来优化一个页面能够达到非常了得的效果,经过PLT优化的网页往往能将一张页面的打开时间缩短3-5秒甚至更多,并且往往也能减少服务器端的运算以及流量。

  Atlas的基础代码框架的每一步都是尽量地符合优化PLT的Best Practice。所以使用Declarative Script和Atlas框架所提供的JS类往往效率会比较高。打个比方,浏览器对于相同域名只会并行地使用两个端口进行加载,因此将不同资源从不同域名加载是优化PLT的一个常用方式。但是由于可能JS中任何部分的代码都可能会改变的页面的DOM或者Render出不同的内容(例如使用document.write),因此浏览器在下载JS文件时是会Block住其他任何的资源加载,无论其是否在同一个域名中。加上现在JS文件越写越大,数量越来越多,因此浏览器的加载能力就被削弱了。在Atlas中,Binding机制能比较好地处理JS加载问题,以优化页面的PLT以及Perceived Performance。
 
 
 
Atlas的缺点?
 
  其实我有时候总是会想,Atlas代码是不是写的太庞大了,使用起来方便吗?比如其OO特性,使用起来似乎不是很方便,代码量和代码体积颇高,而且对于没有接触过Atlas的人不是很容易看懂。外界不少提供面向对象机制的JS框架似乎就精炼许多。我也因为某些需要为JS写了一套面向对象机制的扩展,很简单,使用方便,OO机制使用方式也是尽可能地向Java代码靠拢。继承,虚函数等必须的功能也一个不缺。

  不得不说,这个似乎是Atlas的一个瑕疵。但是瑕不掩瑜,Atlas依旧是一套优秀的JS框架。它实现的Ajax,却又远远超越了Ajax本身。冲着Ajax or .NET来接触Atlas的程序员往往总是能从它身上得到惊喜。
 
  另外,有人向我抱怨过Atlas调试非常的不方便。说实话,的确不太容易,需要一些小技巧,不过一般来说,还是可以接受的。
 
 

学习Atlas……
 
  我经常在我身边的开发人员中推荐.NET,虽然无偿,但是冲得就是对这一技术的喜爱。我是技术人员。当然对于Atlas也向别人进行过介绍,也看到不少人学习Atlas的情况。

  似乎Atlas进入了.NET相同的情况,大家纷纷在使用,感觉很爽,而去了解它是如何做的人却很少。知道在什么情况下如何使用的人也很少。而且能够灵活使用的人,往往也对其机理有了相当认识。可能的确只有从一个特定的层次以及角度去看它,才能对它有更好的掌握能力。“使用论”和“深入论”的争锋似乎依旧存在。

  其实我也是“使用论”的支持者,但是我仅仅支持良好的使用方式。这都不是一朝一夕能够炼成,也不是仅仅靠了解一门技术就能做到的。要成为一个优秀的技术人员,所需的技术覆盖之广,其实远超过普通技术人员的想象。

 
9月7日

有人说,搞IT的有70%的人是废渣

  我同意。
 
  不管别人,我反正要做到最好。
8月30日

Foundation of Atlas

  大约花了三天时间,粗粗地看完了这本书。这本书出来也有一段时间了,我却第一次开始阅读,可以说比较落伍。
 
  说实话,我不喜欢这本书,要我打分的话,我只会给三颗星。这本书没有让我有什么收获。
 
  首先,这本书的的确是讲Foundation,因此几乎所有的内容都是和http://atlas.asp.net的内容非常的相像。书中的大部分例子几乎就是对于网站文档的拷贝。其次,由于我在看此书之前,已经看过了Atlas的文档,并且使用了一段不算短的时间,因此我深深觉得,Atlas并不是一个“大书特书”的东西。这并不是说Atlas不好,事实上,我觉得它应该可以算是Best Ajax Solution for ASP.NET 2.0,而且,它继承并超越了一个Ajax框架本身,是一个包含Ajax的Javascript框架。我只是觉得,就Atlas本身来说,它是个相当易于接受的东西。我始终觉得,如果要对于这样的技术写书的话,应该更着重于应用该技术的层次,而不是讲解该技术本身。如果的确想着眼于技术层面,那么可以讲一下如何对原有内容进行扩展。最后,就是版本的问题。Ajax本身还只是处于CTP的阶段,很多东西都在进一步的补充和修改。
 
  诚然,要写好这样一本书很困难,再加上众口难调,即使满足了我的口味,可能也难以让别人满意,甚至反而让别人敬而远之。
 
P.S.
 
  本书目前已经由Dflying兄翻译并即将出版。另外他目前正在努力写一本原创的Atlas书籍,拭目以待。
8月29日

Windows Live的产品越来越稳定,越来越快速了

换上了Windows Live Mail Dogfood。
 
界面更加美观,愈发迅速,愈发方便了……
 
Windows Live Spaces经过了大半个月的运行,一切也趋于稳定。
8月24日

Book List Gadget for Windows Live Spaces - Usage Instruction

Figure 1
 
Picture 1
Figure 2
 
Figure 3
 
Figure 4
 
Figure 5
Contents at a Glance
  1. Introduction
  2. Features
  3. Preference Storage for Windows Live Spaces
  4. Author Mode Instruction
  5. Contact me
  6. Appendix I - Introduction to Book List Manifest
  7. Appendix II - DISCLAIMER
  8. Appendix III - Q & A
 
Introduction
 
    Thanks for paying attention to Book List Gadget for Windows Live Spaces.

    It's my first shippable gadget for Spaces. At first, building a book list for Windows Live Space is just for the purpose of providing the missing function for China market (The Spaces for China market has not a book list with images. Unluckily, my passort was registered from China but I'm a crazy reader and most of my books are brought from Amazon!). But during my work, a desire to make it better increased stronger and stronger in my mind. It's just my style. At last, I built a book list which can be customized and the gadgets will display by the owner's settings. Basicly, it will use the information from the owner. The details from Amazon will be shown if the ower provides the ISBN and something is missing. Want to have a list in the most convenient way? Just provide a list of ISBNs and the gadget will automatically get all the information you need.

    Well, let's begin.
 
 
Features
 
    Please see Figure 1-3. You can possibly gain a proper impression what the gadget look like. As you can see it, it's similar with the book list of Windows Live Spaces. Here're the basic functions of the gadget: It shows the authors, the title and the publisher.
 
  • The text to show can be given by the owner or from Amazon if ISBNs are provided.
  • All the texts will link to some place - if you need them to do so.
  • The format of texts can be defined by the ower by 'template'.
  • The owner can give a title to the book list.
  • The owner can set the position of images - left or right.
  • The details can be show/close by a switch for each book. The details are definitely from Amazon when the gadget is loaded.
  • The color of background, plain texts, anchor links and separate line can be defined by owner. It means the gadget can be configured to work with almost all the themes.
 
Preference Storage for Windows Live Spaces
 
    All the gadgets need saving and loading preferences. Unfortunately, Windows Live Spaces Gadgets haven't build-in function of preferences preserving (It's unlike gadgets for Windows Live since there's a huge difference between them and it will cause serious security and perf issues).
 
    For the reason of that, I wrote a simple storage for saving preferences. It's really simple, not fully stress tested and actually I've no idea whether it's reliable or not (I've tried my best but who knows the host service). So please DO NOT try to break the storage. It seems I've accepted the issues which should be assumed by Windows Live - it's not interesting - wish my service can work properly longer.
 
    Please click here to visit the sign up page (Figure 4) and sign up your space name with password (Your password will be hashed and store into database and will never exist in clear text). And, you can change your password in change password page (Figure 5). Please be careful that you must only register the name of your own space WITHOUT 'space.live.com' (e.g. I should register 'jeffreyzhao1985' as my space name). Any mistake could cause another user's being not able to register. If you find that your space name has been registered by others, please contact me ASAP.
 

Author Mode Instruction
 
    After you add the book list gadget into your space, a control panel like Figure 3 will occurred.
 
    Manifest Url is the url of book list manifest provided by the owner. The manifest is an xml in a specific schema. The schema will be described in Appendix I.
 
    Title...seems it's self-explanatory enough.
 
    Template is the format to show a single book's title, author and publisher. A template is a case-sensitive string contains '{Title}', '{Author}' and '{Publisher}'. They will be replaced by the corresponding information of book. Template is an optional section. If the user leave it blank, the gadget will use '{Author}: {Title} - {Publisher}' as template by default.
 
    Image's Position - left or right.
 
    And then, there're four colors for the owner to input. You can just use "Black" or "White" to indicated a color (All the colors can be found here). Also, a standard #RRGGBB color format can be used.
 
    At last, fill in the password and click Save button to the save your settings. Please register the storage for you space before your saving.
 
 
Contact me
 
    If you found any bugs or you have any suggests, please feel free to contact me via E-mail. My E-mail address is jeffreyzhao1985@hotmail.com. Also, you can just reply the entry and leave any message here.
 
    I'm always waiting for your feedback.
 
 
Appendix I - Introduction to Book List Manifest:
 
    A manifest is an Xml file contains a list of book. The gadget will prase it and display the information in it. Let's begin with a simple example.
 
The Simplest Example
    This example is the manifest of Figure 1. Here's the content:
<?xml version="1.0" encoding="utf-8" ?>
<Books>
    <Book ISBN="0735621632" />
    <Book ISBN="0735619670" />
    <Book ISBN="0201799405" />
</Books>
    The first line (<?xml version="1.0" encoding="utf-8" ?>) of content should be preserved in the manifest. The document element is '<Books />'. There're sub elements '<Book />' in the document element. Each of them indicates a single book. You can simply provide the ISBN for each book like above and all the information will be taken from Amazon.
 
Customize the books
    If you want to show a book which can't be found in Amazon or you just want to show your own information, you can omit ISBN and give something you want to show in manifest:
<?xml version="1.0" encoding="utf-8" ?>
<Books>
    <Book ISBN="0735619670" />
    <Book>
        <Title url="http://www.samplebook.com">Sample Book</Title>
        <Author url="http://www.author1.com">Author 1</Author>
        <Author url="http://www.author2.com">Author 2</Author>
        <Publisher url="http://www.samplepublisher.com">Sample Publisher</Publisher>
    </Book>
</Books>
     Now gadget will show the infomation in manifest. All the texts and links will follow the manifest. Please notice that you can provide more than one authors for a single book.
 
What if...
    Please see the manifest below:
<?xml version="1.0" encoding="utf-8" ?>
<Books>
    <Book ISBN="0735619670" />
    <Book ISBN="0201799405">
        <Title>Sample Book</Title>
        <Author url="http://www.author1.com">Author 1</Author>
        <Author url="http://www.author2.com">Author 2</Author>
    </Book>
</Books>
    If a valid ISBN is assigned to a book, gadget will look up Amazon for details. In the example above, the gadget will display the title without a hyperlink, two authors given by the manifest and the publisher information with link from Amazon.
 
    For some reasons, if a valid ISBN is assigned to a book, a detail page will always be shown. The user can click View details/Close details to switch between breif information and details from Amazon (Figure 2).
 
 
 
Appendix II - DISCLAIMER:
 
PLEASE KEEP IN MIND THAT SOME OF THE CONTENT THAT WE MAKE AVAILABLE TO YOU THROUGH THIS APPLICATION COMES FROM AMAZON WEB SERVICES. ALL SUCH CONTENT IS PROVIDED TO YOU "AS IS." THIS CONTENT AND YOUR USE OF IT ARE SUBJECT TO CHANGE AND/OR REMOVAL AT ANY TIME.
 
 
 
Appendix III - Q & A:
 
TBD
 
 
8月22日

Cool Survey

As a Windows Live Mail desktop beta user, I got a survay from Windows Live Mail Beta Team. When I clicked the link in the email, a simple page with a short question occurred in the screen.
 
Are you currently a Microsoft employee?
Yes
No
 
Of course I picked "Yes" and click next button. Wow...
 
We are sorry but based on your response, you do not qualify for this survey. We appreciate your willingness to participate.
 
8月21日

Book List Gadget Internal Version Released!

Check out the Internal Version!
 
 
  此版本为内部测试版,目的是在正式发布之前由更多的用户对其进行测试和评价,并于最后阶段修补出现的Bug。
 
  这个Gadget是一个图书列表,其作用是弥补Windows Live Spaces对于中国市场功能的不足。该图书列表可读取用户指定的XML并根据XML中的信息进行显示。如果用户指定的ISBN,Gadget还会从Amazon上获取书籍的详细信息,并在书籍描述一侧显示图片(注1)。
 
  如果您是中国市场用户,想在自己的Space上放置Windows Live Spaces不提供的的书籍列表;如果您是国外市场用户,想在自己的Space上显示更加优秀的书籍列表。那么这个Gadget适合您。当然,由于目前是测试的版本,因此只有您自己在登陆之后才能看到这个Gadget。等以后真正发布在Windows Live Gallery以后,则可以随意使用了。
 
  如果有任何疑问,意见和建议,请留言或者通过E-mail联系我
 
  另外,本人最近正在寻找合适的ASP.NET+Sql Server Express空间,如果有建议的话也请告诉我。
 
 
使用方式:
1、为你的Space注册一个Preference Storage(详见相关部分)
2、打开浏览器,使用你的Windows Live ID登陆。
3、点击这里为你的Windows Live Space添加一个Book List Gadget。
 
 
注册Preference Storage for Windows Live Spaces(注2):
2、填写您的Space名称及密码并确定。(注3)
 
 
编辑模式使用说明:
SampleSetting
Manifest Url 每个Book List都需要一个XML文件作为一个清单,该清单提供了书目信息。
Title 标题
Template 显示模版。默认为"{Author}: {Title} - {Publisher}",“{Author}”、“{Title}”和“{Publisher}”会被替换为书目的作者,标题和出版商。用户可以随意选择以什么方式显示书目的信息。
Image's Position 图片是靠左还是靠右。
Background color 背景色,用户可以自行调节以符合自己的Space主题。
Plain text color 普通文本颜色,用户可以自行调节以符合自己的Space主题。
Anchor color 超级链接文字的颜色,用户可以自行调节以符合自己的Space主题。
Separator color 书籍条目之间的分隔线颜色,用户可以自行调节以符合自己的Space主题。
 
 
显示模式使用说明:
Part 1、点击图片将在出现Amazon上的大图
2、点击作者将在Amazon上进行作者搜索
3、点击图书名称将在Amazon上察看该书的详细信息。
4、点击出版社将在Amazon上进行出版社的搜索。
5、点击左下角“Amazon”字样将察看Amazon上关于该书的详细信息。
6、点击“View details”“Close details”将在Gadget内打开/关闭图书的详细信息。
 
 
Manifest XML示例:
<Books>
 <Book ISBN="078214134X" />
 <Book>
  <Title url="http://www.title.com">Sample Title</Title>
  <Publisher url="http://www.publisher">Sample Publisher</Publisher>
  <Author url="http://www.author1.com">Sample Author1</Author>
  <Author url="http://www.author2.com">Sample Author2</Author>
 </Book>
</Books>
 
1、每一个书籍条目由一个Book节点组成。
2、最简单的书籍条目只需要提供ISBN即可,所有信息都从Amazon上获取。
3、用户可以自定义条目显示信息及相关URL。其中Author可以有多个。
4、如果提供了ISBN,而且书目的信息没有填写完整,那么缺少的信息将从Amazon上获取。
5、如果提供的ISBN,则会出现书籍的图片,左下角Amazon和右下角View Detail/Close Detail的功能。
 
 
 
 
一份完整的Book List截图:
 
 
 
注:
1、DISCLAIMER: PLEASE KEEP IN MIND THAT SOME OF THE CONTENT THAT WE MAKE AVAILABLE TO YOU THROUGH THIS APPLICATION COMES FROM AMAZON WEB SERVICES. ALL SUCH CONTENT IS PROVIDED TO YOU "AS IS." THIS CONTENT AND YOUR USE OF IT ARE SUBJECT TO CHANGE AND/OR REMOVAL AT ANY TIME.
 
2、由于某些原因,Windows Live Spaces对于非认证的Gadget不提供SetPreference和GetPreference的功能。简单的说,就是无法为每个用户的Gadget数据自定义的数据。现在的注册只是为了Book List这个Gadget提供一个简单的存储空间。事实上这个空间性能一般,也没有做到很好的安全性,所以请不要设法通过本人Gadgets以外的方式进行访问,以保证其正常运行。
 
3、如果您的Space为http://sample.spaces.live.com,则sample就是您的Space名称,请小心注册,您的无心之失可能就造成了别人无法正常使用。如果您的Space已经被人注册了,请及时与本人联系
 
8月19日

最近使用ADO.NET来操作Access遇到的问题

有种说法是Access的功能随便用用就够了,于是我也随便用了下。
 
忽然被一个问题困扰住了,一个存储过程怎么样都执行不对,让人非常的困惑。
 
最后发现原来是……如果使用OleDbConnection连接Access并使用OleDbCommand + OleDbParameter这样的标准ADO.NET做法,OleDbParameter的name对于传入Access本身是无关的。唯一相关的是Parameter的顺序。
 
打个比方,一个最简单的表:
CREATE TABLE SampleTable(StrVal1 string, StrVal2 string, StrVal3 string)
 
使用一个最简单的存储过程INSERT_NEW_STR:
INSERT INTO SampleTable (StrVal1, StrVal2, StrVal3) VALUE (@str1, @str2, @str3);
 
然后是C#代码:
using (OleDbConnection conn = new OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=DB.mdb"))
{
  conn.Open();
  OleDbCommand cmd = new OleDbCommand("INSERT_NEW_STR", conn);
  cmd.Parameters.Add(new OleDbParameter("@str3", "str3"));
  cmd.Parameters.Add(new OleDbParameter("@str1", "str1"));
  cmd.Parameters.Add(new OleDbParameter("@str2", "str2"));
  cmd.ExecuteNonQuery();
}
 
猜猜看结果?
结果是:
StrVal1    StrVal2    StrVal3
-----------------------------------------------
str3      str1      str2
 
原因就在于,每个OleDbParameter的name没有起作用,Access简单的使用参数的顺序来赋给存储过程。当时我遇到的是一个UPDATE,由于传入参数的顺序不对,WHERE Clause总是不会满足,因此总是没有起效果。作了无数次的试验,总算发现了问题。另外,Access对于参数也没有命名要求,会把与字段名无关的标识都认为是参数。也就是说,如果在一个存储过程中一个字段名有一个字母被拼错了,那么它会被作为参数,还是能正确建立这个存储过程。
 
其实由于Accees比较早,它对于ADO.NET的很多“协议”都无法支持。另外,Access中我一直称为“存储过程”的玩意儿只是“查询”。Access不允许在一个“查询”中使用多条语句,这个已经完全无法胜任几乎所有的开发需要了。再者,由于连接Access时使用的是文件共享方式,其并发数受到了严重的限制,一般十几个连接还行,超过了30个就会有比较难以让人接受的影响了。
 
因此Access其实已经是个“闹着玩”的玩意儿了,如果不是找不到好的托管服务商,我也不会使用Access。
哦不,如果不是Live Spaces的Gadget无法set/getPreference,我也不会做这个玩意儿。
 
8月14日

来想一个问题:如何才能得到尽可能高的安全性

Scenario如下:
  1. 客户端用户使用一个ID与服务器进行交互,每个用户有个独立ID,该ID公开。
  2. 用户无口令。
  3. 客户端和服务器端的交互代码公开。
  4. 无任何加密连接措施,交互的内容为明文。
  5. 无法得到连接条件的任何信息,比如连接的对方IP等,也就是说,获得认证对方用户只有ID一个信息。
 
很容易看出,在这个非常无理头的环境中,是不可能做到完备的用户身份验证。现在的目的就是如何尽可能做到最好的安全性。比如增加身份伪装的难度等等。
 
举个例子:使用混淆器加大代码的破解难度。
 
大家一起来想吧,呀呼嘿。
 

Book List

正在加载...