kali 2017 更新源 错误解决 1、更新源#清华deb http://mirrors.tuna.tsinghua.edu.cn/kali kali-rolling main contrib non-free加到文件/etc/apt/sources.list中2、更新apt-get update3、错误W: An error occurred during the signature verification....
vmware 报错 :"internal error" 内部错误 网上的方法: 1、services.msc查看服务,检查所有服务均已开启,该方法无效; 2、管理员权限运行vmware,同样报错,无效;3、删除报错虚拟机文件夹下的最近的*.vmem文件(记录最近使用的状态和每个快照的状态),重启虚拟机,会提示说找不到快照,要选discard 当前状态。点击确定,虚拟机系统正常重启。 —该方法成功。...
Linux下安装Libnids1.24 Libnids需要libpcap和libnet库的支持,首先安装这两个开发包。1、安装 libpcap 下载libpcap包。 ./configure configure: error: yacc is insufficient to compile libpcap. libpcap requires Bison, Berkeley YACC, or another YACC com
Windows7下多版本python与pip安装和pip使用 一、安装多版本python 1、官网下载安装包 官网:https://www.python.org/ 2、分别安装python27和python36 进入各自安装目录,将python.exe重命名为python2.exe和python3.exe3、设置环境变量 C:\Python36-32\Scripts\; C:\Python36-32\; C:\Python27; C:\Pyt
C语言生成调用DLL 一、生成DLL文件 生成DLL文件需要用到两个文件,一个头文件,dll.h,和一个源文件,dll.c头文件dll.h内容: #ifndef _DLL_DEMO_H_ #define _DLL_DEMO_H_ #ifdef DLLDEMO_EXPORTS #define DLL_DEMO _declspec( dllexport ) #else #d
FindFirstFile 错误: ERROR_FILE_NOT_FOUND 错误:hFindFile = FindFirstFile( tCurrentDirecory , &findData );hFindFile = INVALID_HANDLE_VALUE GetLastError()得到的错误提示是2 ERROR_FILE_NOT_FOUND 无法找到要打开的文件。warning C4133: “函数”: 从“char [66]”到“LPCWSTR”的类
Error LNK2001 无法解析的外部符号 查找资料: VC++时经常会遇到链接错误LNK2001,该错误非常讨厌,因为对于编程者来说,最好改的错误莫过于编译错误,而一般说来发生连接错误时,编译都已通过。产生连接错误的原因非常多,尤其LNK2001错误,常常使人不明其所以然。如果不深入地学习和理解VC++,要想改正连接错误LNK2001非常困难。 初学者在学习VC++的过程中,遇到的LNK2001错误的错误消息主要为: unreso
The capture file appears to be damaged or corrupt. 背景通过libpcap库对数据包进行处理,提取离线pcap文件中的部分内容保存为新的pcap文件,使用函数:pcap_open_offline( );pcap_loop( )等。错误The capture file appears to be damaged or corrupt.(pcap: File has 2944323888-byte packet, bigger than maximum
编译调用openssl库出错:d1_enc.c:(text+0x3b):undefined refrence to 'EVP_MD_CTX_md' 编译命令:gcc -g -o xxx xxx.c -I/usr/local/ssl/include/ -L/usr/local/ssl/lib/ -lssl错误: 查询原因:修改命令:gcc -g -o xxx xxx.c -I/usr/local/ssl/include/ -L/usr/local/ssl/lib/ -lssl -lcrypto -ldl结果: OK
error LNK2019: 无法解析的外部符号 _SQLConnect@28,该符号在函数 error:error LNK2019: 无法解析的外部符号 _SQLConnect@28,该符号在函数 "xxx 中被引用error LNK2019: 无法解析的外部符号 _SQLSetEnvAttr@16,该符号在函数 "xxx 中被引用error LNK2019: 无法解析的外部符号 _SQLAllocHandle@12,该符号在函数 "xxx中被引用解决方法:#include <afxd
vs2013 error:Building an MFC project for a non-Unicode character set is deprecated 1、VS2013多字节工程问题使用VS2013编译旧版VC++程序时,提示Building an MFC project for a non-Unicode character set is deprecated,微软提供了解决方案。2、错误信息1>------ 已启动生成: 项目: Decrypt, 配置: Debug Win32 ------1>C:\Program Files (x86)\
OpenSSL命令之:---genrsa 用途:生成RSA私有密钥的工具。用法:openssl genrsa [-out filename] [-passout arg] [-f4] [-3] [-rand file(s)] [-engine id] [numbits] [-des] [-des3] [-idea] 选项说明:-out filename:私有密钥输出文件名,缺省为标准输出。-passout arg:输出文件口令保护存放方
windows下编译wireshark错误 win7 wireshark 1.8.3error:tools/textify.sh: line 50: u2d: command not foundNMAKE : fatal error U1077 : "c:\cygwin\bin\bash.EXE" : 返回代码 “0x7f”解决:需安装:dos2unix Cygwin packageBy:https://ask.wireshark.or
CentOS gdb core 调试错误: error reading variable: can't compute CFA for this frame 1、./test 程序运行错误 Segmentation fault (core dumped)通常都是指针错误引起的。但这不像编译错误一样会提示到文件一行,而是没有任何信息。一种办法是用gdb的step, 一步一步寻找。但要step一个上万行的代码让人难以想象。 我们还有更好的办法,这就是core file。2、gdb core 调试如果想让系统在信号中断造成的错误时产生core文件, 我们需
selenium与firefox不兼容 error: os.path.basename(self.path), self.start_error_message) WebDriverException: Message: ‘geckodriver’ executable needs to be in PATH. 环境: firefox50.0 selenium 3.0.2 python2.7解决: 安装驱动: geckodr
selenium与firefox不兼容 error: os.path.basename(self.path), self.start_error_message) WebDriverException: Message: ‘geckodriver’ executable needs to be in PATH. 环境: firefox50.0 selenium 3.0.2 python2.7解决: 安装驱动: geckodr
selenium与firefox不兼容 error: os.path.basename(self.path), self.start_error_message) WebDriverException: Message: ‘geckodriver’ executable needs to be in PATH. 环境: firefox50.0 selenium 3.0.2 python2.7解决: 安装驱动: geckodr
selenium与firefox不兼容 error: os.path.basename(self.path), self.start_error_message) WebDriverException: Message: ‘geckodriver’ executable needs to be in PATH. 环境: firefox50.0 selenium 3.0.2 python2.7解决: 安装驱动: geckodr
selenium与firefox不兼容 error: os.path.basename(self.path), self.start_error_message) WebDriverException: Message: ‘geckodriver’ executable needs to be in PATH. 环境: firefox50.0 selenium 3.0.2 python2.7解决: 安装驱动: geckodr
Ubuntu10.04 更新源 安装ia32-libs成功 Ubuntu10.04更新源sudo gedit /etc/apt/sources.listdeb http://mirror.bjtu.edu.cn/ubuntu lucid main restricted universe multiversedeb http://mirror.bjtu.edu.cn/ubuntu lucid-security main restricted universe
VC++操作 Excel 的方法总结 转载自:http://blog.csdn.net/davidhsing/article/details/4231592一、最常用的 OLE 自动化方式这个方式应该说是功能最全的方式,可能也是应用的最多的方式。由于这种方式采用的是隐藏启动 Office Excel 的方式,所以几乎是全能,任何功能都可以完成。不过缺点也是比较明显的:1、采用 OLE 方式,需要用户计算机上安装有 Office Exce
C语言在TXT文件中搜索字符串 方法一:bool CBrowseDir::SearchTXT(const char *filename){ string filename1( filename ); string keyword( "word" ); ifstream in( filename1.c_str()); if( in ) { ostringstream os
c++ 遍历目录下文件 function:遍历目录下所有文件,返回文件总数,子文件夹总数#include "stdlib.h" #include "direct.h" #include "string.h" #include "io.h" #include "stdio.h" #include "iostream" using namespace std; class CBrowseDir
VC 打开 Excel 文件后,excel.exe进程无法退出 测试代码:vc6.0 office2000 以下代码需要MFC的支持,而且工程中还要包含EXCEL2000的定义文件:EXCEL9.H,EXCEL9.CPP _Application ExcelApp; Workbooks wbsMyBooks; _Workbook wbMyBook; Worksheets wssMysheet
[Linux] undefined reference to `itoa' 本文转至http://blog.csdn.net/joeblackzqq/article/details/6934921在linux写了个简单的C程序,里面用到了itoa,但是编译时提示“undefined reference to `itoa’”,本以为加上-lc就行了,可结果还是一样。上网发现,有人说这个函数在linux中是不存在的,一般用sprintf来代替。看下面代码及注释吧:#includ
Ubuntu下安装Freetds,并编程连接MSSQL 1. 环境 Ubuntu14.04.05 freetds-stable.tar.gz2. 安装freetds 下载freetds : http://www.freetds.org 解压 : tar zxvf freetds-stable.tar.gzcd freetds1.00sudo ./configure --prefix=/usr/local/freet
linux下C获取文件的大小 获取文件大小这里有两种方法:方法一范例:unsigned long get_file_size(const char *path) { unsigned long filesize = -1; FILE *fp; fp = fopen(path, "r"); if(fp == NULL) return filesize;
DNS协议 : RFC1035 中文 RFC1035 中文一、域名和资源记录的定义1、Name space definitions2、资源记录定义(RR definitions) 2.1 格式 后面分析报文的时候详细解释。 2.2 类型值(TYPE values) 类型主要用在资源记录中,注意下面的值是QTYPE的一个子集。 类型 值和含义
ftp上传文件失败,大小始终为0 主机:win7 虚拟机:ubuntu14.04 ubuntu中安装vsftpd,配置writing_enable=yes以及其它配置。上传文件大小始终为0。原因:磁盘空间被占满,没有空间写入: df -lh 查看磁盘空间。 解决:删除部分不用文件或日志文件,释放空间。
清除本地DNS cmd下运行: ipconfig/flushdns错误: Windows IP Configuration Could not flush the DNS Resolver Cache: Function failed during execution.解决:打开dns client 和 dhcp client 两个服务
Linux下struct的成员对齐问题-结构体实际大小 1 、自然对界 struct 是一种复合数据类型,其构成元素既可以是基本数据类型(如int、long、float 等)的变量,也可以是一些复合数据类型(如array、struct、union 等)的数据单元。对于结构体,编译器会自动进行成员变量的对齐,以提高运算效率。缺省情况下,编译器为结构体的每个成员按其自然对界(natural alignment)条件分配空间。各个成员按照它们被声明的顺序在内
Ubuntu14.04 运行程序错误,调试记录 Ubuntu14.04上运行程序出现如下错误: 运行 ./program no such file 提示没有那个文件或目录 分析:程序为32位程序,uname –m查看系统为x86_64,64位系统,不兼容。安装ia32-libs解决兼容性问题:sudo apt-get install ia32-libsPackage ia32-libs is not available, but is
libpcap error. error1:include<pcap.h> no such filesudo apt-get install libpcap-deverror2:sniffer.c:(.text+0x43): undefined reference to `pcap_findalldevs'sniffer.c:(.text+0x142): undefined reference to `pcap_ope
*.pyc文件无法执行 python生成*.pyc文件后执行出错的问题:$./*.py 运行成功;$./*.pyc 运行失败;解决: 运行.pyc文件要通过python *.pyc来执行:$python *.pyc 运行成功;
chapcrack编译过程中的python错误 from passlib.utils import desImportError: No module named passlib.utilsapt-get install python-passlibfrom dpkt import pcapImportError: No module named dpktsudo apt-get install python-dpktfrom M2Crypt
tcpdump抓取TCP协议、GRE协议数据 tcpdump抓取tcp数据 1、tcpdump -i eth0 port 11751 and src host 192.168.1.34 -x -s0tcpdump: verbose output suppressed, use -v or -vv for full protocol decodelistening on eth0, link-type EN10MB (Ethernet), c
mysql.h: No such file or directory error 1: mysql.h: No such file or directory解决: apt-get install libmysqlclient-dev find /usr/ -name ‘mysql.h’ /usr/include/mysql/mysql.herror 2: /tmp/ccDay78L.o: In function main': ***.c:(.text+0
python下编译py成pyc 生成单个pyc文件: 命令:python -m py_compile file.pypython -m py_compile /root/src/{file1,file2}.py脚本:import py_compilepy_compile.compile('path') //path是包括.py文件名的路径批量生成pyc文件: 命令:python -m compileall /root/sr
直接用编译器按ctrl+F5运行和Release、Debug下双击运行结果不一样 是因为进程权限的问题,需要添加下面的代码:BOOL EnableDebugPrivilege(){HANDLE hToken;BOOL fOk=FALSE;if(OpenProcessToken(GetCurrentProcess(),TOKEN_ADJUST_PRIVILEGES,&hToken)){TOKEN_PRIVILEGES tp;tp.PrivilegeCount=1;i
Windows平台下fwrite函数0x0A变成0x0D 0x0A 在Windows环境下,用fwrite向文件中写数据时,当写入0x0A时,其前面总会被加上一个0x0D。后来发现出现这个问题的原因是fwrite 在以文本方式写文件时,碰到0x0A,会自动在前面加上0x0D,以够成回车换行符,因为Windows平台的换行符默认是:0x0D 0x0A。解决办法是以二进制方式打开文件,然后进行写文件。分析问题代码:fopen( "openfile", "a+" );修改
firefox不安全连接 firefox47.0 突然不能打开https://www.baidu.com等网站。显示不安全链接。解决: firefox输入:about:support 点击:显示文件夹 删除:cert8.db文件 重启firefox。
python实现跨文件全局变量的方法 在使用Python编写的应用的过程中,有时候会遇到多个文件之间传递同一个全局变量的情况。 文件1:globalvar.py#!/usr/bin/env python2.7 class GlobalVar: db_handle = None mq_client = None def set_db_handle(db): GlobalVar.db_handle = db def
数据类型变换uint8_t uint16_t等等 #include <limits.h>#ifdef WIN32#include <windows.h>#endif /* WIN32 */#ifdef _MSC_VER /* WIN32 *//* from http://code.google.com/p/msinttypes/ */#if _MSC_VER > 1000#pragma once#endif#if (_MSC_VER <
fatal error C1010: unexpected end of file while looking for precompile 在编译VC++6.0是,出现fatal error C1010: unexpected end of file while looking for precompiled header directive 的错误.解决方法:1、如果发生错误的文件是由其他的C代码文件添加进入当前工程而引起的,则Alt+F7进入当前工程的 Settings,选择C/C++选项卡,从Category组合框中选中Preco
网络协议结构体定义(eth,ip,tcp,udp,icmp...) 网络协议结构体定义// i386 is little_endian. #ifndef LITTLE_ENDIAN #define LITTLE_ENDIAN (1) //BYTE ORDER #else #error Redefine LITTLE_ORDER #endif//Mac头部,总长度14字节 typedef struct _eth_hdr
PostMessaget ON_MESSAGE PostMessage是Windows API(应用程序接口) 中的一个常用函数,用于将一条消息放入到消息队列中。函数功能:该函数将一个消息放入(寄送)到与指定窗口创建的线程相联系消息队列里,不等待线程处理消息就返回,是异步消息模式。 消息队列里的消息通过调用GetMessage和PeekMessage取得。原型与参数函数原型: B00L PostMessage(HWNDhWnd,UINTMsg
python强制类型转换(dpkt) http://dpkt.readthedocs.io/en/latest/_modules/dpkt/ppp.html#PPPclass PPP(dpkt.Packet): 类型为:dpkt.ppp.PPPppp_packet = (dpkt.ppp.PPP)(udp_packet.data[6:])ppp_packet = (dpkt.ppp.PPP)(udp_packet.data[8:])
pyinstaller生成exe后无法执行 使用命令:pyinstaller.py -F c:\mypy\mypy.py 运行结果:cmd中运行,缺少module; 原因分析:-F参数打包成一个文件,但其中单独调用的模块没有加 载进来,需要手动设置; 解决方法:-p参数,指向所需的module 新的命令:pyinstaller.py -F -p d:\mymodule\lib; c:\mypy\m
Pyinstaller : ImportError: No module named pefile 使用Pyinstaller对.py程序打包成.exe pyinstaller3.2 python2.7windows环境下安装pyinstaller3.2 : 先安装pywin32-217.win32-py2.7.exe; 解压pyinstaller3.2 后直接可以执行:python pyinstaller.py -F -w C:\mypy\mypy.pypython pyinstal
windows下telepot install Telepot 是开发Telegram API 所需的Python包;安装方法(linux): pip:$ sudo pip install telepot$ sudo pip install telepot --upgrade #UPGRADEeasy_install:$ easy_install telepot$ easy_install --upgrade telepot #UPGRAD
ImportError: No module named setuptools 解决方案 下载setuptools并安装wget http://pypi.python.org/packages/source/s/setuptools/setuptools-0.6c11.tar.gz tar zxvf setuptools-0.6c11.tar.gz cd setuptools-0.6c11 python setup.py build python setup.py install
DMZ下使用web_delivery 介绍 From : http://evi1cg.me/archives/Use_Web_delivery_Under_DMZ.html?utm_source=tuicool&utm_medium=referral之前碰到的问题,自己的主机做了DMZ,设置[b]web_delivery[/b]时,发现将lhost设置成外网ip,则脚本不能运行,如果设置成内网ip,则反弹payload反弹的
jsfuck编码---idf实验室“一种编码而已”笔记 [][(![]+[])[!![]+!![]+!![]]+({}+[])[+!![]]+(!![]+[])[+!![]]+(!![]+[])[+[]]][({}+[])[!![]+!![]+!![]+!![]+!![]]+({}+[])[+!![]]+({}[[]]+[])[+!![]]+(![]+[])[!![]+!![]+!![]]+(!![]+[])[+[]]+(!![]+[])[+!![]]
Linux定时器(计时器) 【实现功能】:Linux下的C编程:编写一个程序(库),实现定时器(计时器)的功能,它能为用户提供在同一进程中多次使用的定时器。这里要求用信号来实现。【解题思路】:编写一个结构体Timer代表一个计时器,然后再定义Timer类型的数组myTimer[N],用来保存我们设置的定时器;再定义函数setTimer()生成计时器,并将生成的计时器保存到myTimer中,这样通过多次调用,就可以在同一个进程中生成多个计时器;定义timeout()信号处理函数,每隔一秒产生一个信号,通过调用ti
Libpcap library/headers not found.... 编译snort2.4,问题仍然没有解决,Mark一下。。。 首先出现的问题: ERROR! Libpcap library/headers not found, go get it fromhttp://www.tcpdump.orgor use the --with-libpcap-* options, if you have it installedin unusual place 因为少了libpcap库
linux 创建连接命令 ln -s 软链接 这是linux中一个非常重要命令,请大家一定要熟悉。它的功能是为某一个文件在另外一个位置建立一个同不的链接,这个命令最常用的参数是-s,具体用法是:ln -s 源文件 目标文件。当 我们需要在不同的目录,用到相同的文件时,我们不需要在每一个需要的目录下都放一个必须相同的文件,我们只要在某个固定的目录,放上该文件,然后在其它的 目录下用ln命令链接(link)它就可以,不必重复的占用磁盘空间。例如:ln -s /bin/less /usr/local/bin/less-s 是代号(symb
RedHat Linux AS4 安装openssl 安装OpenSSL 的步骤如下: (1)获取源代码: 创建存放软件的目录: mkdir /root/software (可以存放在任何自己想存放的目录) 到http://www.openssl.org/source/ 下载源代码包, 放到/root/software/。 本案例中下载的是openssl-0.9.8.tar.gz (2)解压软件 tar -zxvf openssl-0.9.8.tar.gz (3)进入源代码目录:
Nginx编译选项说明 Nginx的configure脚本的编译选项说明: --prefix=<path> - Nginx安装路径。如果没有指定,默认为 /usr/local/nginx。 --sbin-path=<path> - Nginx可执行文件安装路径。只能安装时指定,如果没有指定,默认为<prefix>/sbin/nginx。 --conf-path=<path> - 在没有给定-c选项下默认的nginx.conf的路径。如果没有指定,默认为<prefix>/conf/
Linux编译问题1 错误:make: *** 没有规则可以创建“pattern.o”需要的目标“/usr/include/iso/stdlib_iso.h”。 停止。原因:缺少该头文件方法:打开Makefile文件,找到该位置,修改其为stdlib_iso.h安装的正确位置。
Makefile中指示符“include”、“-include”和“sinclude”的区别 保留学习。。。 指示符“include”、“-include”和“sinclude”如果指示符“include”指定的文件不是以斜线开始(绝对路径,如/usr/src/Makefile...),而且当前目录下也不存在此文件;make将根据文件名试图在以下几个目录下查找:首先,查找使用命令行选项“-I”或者“--include-dir”指定的目录,如果找到指定的文件,则使用这个文件;否则继续依此搜索以下几个目录(如果其存在):“/usr/gn
RFC1994------CHAP:PPP 挑战握手认证协议 挑战握手认证协议(CHAP)通过三次握手周期性的校验对端的身份,在初始链路建立时完成,可以在链路建立之后的任何时候重复进行。 1. 链路建立阶段结束之后,认证者向对端点发送“challenge”消息。 2. 对端点用经过单向哈希函数计算出来的值做应答。 3. 认证者根据它自己计算的哈希值来检查应答,如果值匹配,认证得到承认;否则,连接应该终止。 4. 经过一定的随机间隔,认证者发送一个新的 c
Ubuntu 2.6.25内核编译小结 说明:借鉴了很多资料,对内核编译的过程中也有很多别人没有的问题,这个和环境或时间有关系了,在此做备忘……环境:a、系统是:ubuntu-7.04-desktop-i386 ,内核是: 2.6.20-15-generic b、要编译的内核是:linux-2.6.25.10主要参考文章:http://www.cyberciti.biz/tips/compiling-linux-kernel-26.htmlhttp://forum.ubuntu.org.cn/viewtopic.php?t=134
ARC4算法(加密) #include "StdAfx.h" #include "Arc4EnDe.h" CArc4EnDe::CArc4EnDe(void) { } CArc4EnDe::~CArc4EnDe(void) { } void CArc4EnDe::fz_arc4init(fz_arc4 *arc4, BYTE *key, DWORD keylen) { unsigned int t, u; unsi
IP/TCP/UDP checksum unsigned short checksum(unsigned short *buf, int nword){ unsigned long sum = 0; for(int i=0; i<nword; i++) { sum += *buf++; } sum = (sum >> 16) + (sum & 0xffff); sum += (sum >> 16); return (unsigned sho