本文主要介绍针对PHP网站HTTP响应拆分,站在攻击者的角度,为你演示HTTP响应拆分。HTTP请求的格式1)请求信息:例如“Get /index.php HTTP/1.1”,请求index.php文件2)表头:例如“Host: localhost”,表示服务器地址3)空白行4)信息正文“请求信息”...
分类:
Web程序 时间:
2014-07-14 09:28:35
阅读次数:
288
字符串朴素匹配法相等情况int index(const char * str1, const char * str2, int pos){ int i = pos; int j = 0; while(i = strlen(str2)) // matched and retu...
分类:
其他好文 时间:
2014-07-14 09:00:51
阅读次数:
176
poj2255 Tree Recovery(求后续遍历,二叉树)...
分类:
其他好文 时间:
2014-07-13 00:08:35
阅读次数:
200
一条标准的拓扑题解。
我这里的做法就是:
保存单亲节点作为邻接表的邻接点,这样就很方便可以查找到那些点是没有单亲的节点,那么就可以输出该节点了。
具体实现的方法有很多种的,比如记录每个节点的入度,输出一个节点之后,把这个节点对于其他节点的入度去掉,然后继续查找入度为零的点输出。这个是一般的做法了,效果和我的程序一样的。
有兴趣的也可以参考下我这种做法。
#...
分类:
其他好文 时间:
2014-07-12 22:15:05
阅读次数:
308
实现的菜单效果:
??
选中的是绿色的菜单,其余为灰色的。
实现方法:具体菜单使用图片代替,不采用文字和css组合实现。
主要JS代码:
点击菜单的时候,先遍历移除已有的选中菜单样式,然后再添加新的菜单对应样式
changeC(id,img);
var index=img.indexOf(".");
var imgPath='images/menu/'+img.subst...
分类:
其他好文 时间:
2014-07-12 20:20:47
阅读次数:
267
Given two binary strings, return their sum (also a binary string).
For example,
a = "11"
b = "1"
Return "100".
public class Solution {
public String addBinary(String a, String b) {
...
分类:
其他好文 时间:
2014-07-12 19:42:26
阅读次数:
168
二叉排序树:
二叉排序树(Binary Sort Tree)又称二叉查找树(Binary Search Tree),亦称二叉搜索树。 它或者是一棵空树;或者是具有下列性质的二叉树:
(1)若左子树不空,则左子树上所有结点的值均小于它的根结点的值;
(2)若右子树不空,则右子树上所有结点的值均大于它的根结点的值; (3)左、右子树也分别为二叉排序树;
注:中序遍历一棵二叉排序...
分类:
其他好文 时间:
2014-07-12 19:35:08
阅读次数:
249
Description
Read the statement of problem G for the definitions concerning trees. In the following we define the basic terminology of heaps. A heap is a tree whose internal nodes have each assigned...
分类:
其他好文 时间:
2014-07-12 18:52:12
阅读次数:
285
Given a binary tree, determine if it is a valid binary search tree (BST).
Assume a BST is defined as follows:
The left subtree of a node contains only nodes with keys less than the node's key.Th...
分类:
其他好文 时间:
2014-07-12 17:26:31
阅读次数:
256
在C++中,传统的业务分发,总要写一大串的switch-case,而且每次增加新业务时,都要在原有的switch-case里加一个分支,这就违反了设计模式中的开放封闭原则,
以下这种方案,就完全去除了switch-case,每当要添加业务模块时,只要写一个TEST_MODULE(index, name)就可以了。
思路很简单,直接上代码:#include
#include
#inclu...
分类:
编程语言 时间:
2014-07-12 17:01:38
阅读次数:
179