上一页 1 2 3 4 5 6 ··· 9 下一页
摘要: 使用logrotate管理nginx日志文件logrotatelogrotate第十九章、认识与分析登录档 阅读全文
posted @ 2013-04-20 17:00 firesnow 阅读(145) 评论(0) 推荐(0) 编辑
摘要: 一种基于RSA加密算法的网站敏感数据加密的实现 阅读全文
posted @ 2013-04-20 14:56 firesnow 阅读(147) 评论(0) 推荐(0) 编辑
摘要: 浅谈HTTPS传输协议原理我们常常在使用网上银行时看到的连接都是以“https”开始的,那么这个https是什么呢?这其实是表示目前连接使用了SSL进行加密,能保证客户端到服务器端的通信都在被保护起来,那么浏览器是如果实现的呢?下面让我们来介绍一下SSL基本的实现方法。首先我们有两种基本的加解密算法类型:对称加密,非对称加密(公私钥加密),现在介绍一下这两种加密算法的特点:对称加密:密钥只有一个,加密解密为同一个密码,且加解密速度快,典型的对称加密算法有DES、AES等,示意图如下:图1对称加密非对称加密:密钥成对出现(且根据公钥无法推知私钥,根据私钥也无法推知公钥),加密解密使用不同密钥(公 阅读全文
posted @ 2013-04-20 14:52 firesnow 阅读(149) 评论(0) 推荐(0) 编辑
摘要: # import MySQL moduleimport MySQLdb# get user inputname = raw_input("Please enter a name: ")species = raw_input("Please enter a species: ")# connectdb = MySQLdb.connect(host="localhost", user="joe", passwd="secret",db="db56a")# create a cur 阅读全文
posted @ 2013-04-20 12:04 firesnow 阅读(1078) 评论(0) 推荐(0) 编辑
摘要: 需要用到openpyxl这跟模块安装easy_install openpyxl使用方法from openpyxl.workbook import Workbookfrom openpyxl.writer.excel import ExcelWriterfrom openpyxl.cell import get_column_letterfrom openpyxl.style import Color, Fillfrom openpyxl.cell import Cell#新建一个workbookwb = Workbook()#第一个sheet是wsws = wb.worksheets[0]#设 阅读全文
posted @ 2013-04-20 11:33 firesnow 阅读(1893) 评论(0) 推荐(0) 编辑
摘要: 因为采用data:字符串这种形式,+和&是jquery分隔参数的分隔符,所以会丢失,解决方法就是把text文本中的+和&替换掉,用js里面的encodeURIComponent编码,为了省事,直接写出编码替换..function FixJqText(str) { var tempstr = str.replace(/\+/g, "%2B"); tempstr = tempstr.replace(/\&/g, "%26"); return tempstr;} 阅读全文
posted @ 2013-04-14 14:30 firesnow 阅读(293) 评论(0) 推荐(0) 编辑
摘要: netstat -lnp|grep 80结果tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 2091/apache2 接着kill -9 2091 阅读全文
posted @ 2013-04-13 15:27 firesnow 阅读(217) 评论(0) 推荐(0) 编辑
摘要: 一.Crontab介绍crontab命令的功能是在一定的时间间隔调度一些命令的执行。1.1 /etc/crontab文件在/etc目录下有一个crontab文件,这里存放有系统运行的一些调度程序。每个用户可以建立自己的调度crontab。如:[root@dave ~]# cat /etc/crontabSHELL=/bin/bashPATH=/sbin:/bin:/usr/sbin:/usr/binMAILTO=rootHOME=/# run-parts01 * * * * root run-parts /etc/cron.hourly02 4 * * * root run-parts /et 阅读全文
posted @ 2013-04-13 10:41 firesnow 阅读(159) 评论(0) 推荐(0) 编辑
摘要: import timeclienttime = '2012-04-12 08:35:33'servertime = '2012-04-12 13:35:34'##转化为时间戳c_time = time.mktime(time.strptime(clienttime,'%Y-%m-%d %H:%M:%S'))s_time = time.mktime(time.strptime(servertime,'%Y-%m-%d %H:%M:%S'))##求时间差time_diff = s_time - c_time##取当前时间 时间戳 se 阅读全文
posted @ 2013-04-12 14:09 firesnow 阅读(239) 评论(0) 推荐(0) 编辑
摘要: 安装模块重启apacheapt-get install php5-mcrypt 阅读全文
posted @ 2013-04-11 15:20 firesnow 阅读(2060) 评论(0) 推荐(0) 编辑
上一页 1 2 3 4 5 6 ··· 9 下一页