Skip to content

Commit

Permalink
IChromeLink v1.21 update [p2] 2018-03-21
Browse files Browse the repository at this point in the history
  • Loading branch information
kirino17 committed Mar 21, 2018
1 parent c3071f6 commit c7aa684
Show file tree
Hide file tree
Showing 22 changed files with 96 additions and 8 deletions.
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,15 @@
*.la
*.a
*.lib
*.exp
*.iobj
*.ipdb

# Executables
*.exe
*.out
*.app

Projects/.vs
Projects/packages
Projects/Release
62 changes: 62 additions & 0 deletions Projects/IChromeLink/Release/IChromeLink.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\VC\VCTargets\Microsoft.CppBuild.targets(373,5): warning MSB8004: Output 目录未以斜杠结尾。 此生成实例将添加斜杠,因为必须有这个斜杠才能正确计算 Output 目录。
IChromeLink.cpp
..\core\IChromeLink.cpp(36): warning C4018: “<”: 有符号/无符号不匹配
..\core\IChromeLink.cpp(358): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(486): warning C4018: “<”: 有符号/无符号不匹配
..\core\IChromeLink.cpp(372): warning C4101: “szVar”: 未引用的局部变量
..\core\IChromeLink.cpp(558): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(680): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(699): warning C4101: “szVar”: 未引用的局部变量
..\core\IChromeLink.cpp(762): warning C4018: “<”: 有符号/无符号不匹配
..\core\IChromeLink.cpp(899): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1013): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1095): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1145): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1196): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1224): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1264): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1316): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1399): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1440): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1489): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1530): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1571): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1616): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1663): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1712): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1753): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1800): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1846): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1891): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1932): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(1978): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2010): warning C4018: “<”: 有符号/无符号不匹配
..\core\IChromeLink.cpp(2029): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2070): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2112): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2153): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2195): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2256): warning C4018: “<”: 有符号/无符号不匹配
..\core\IChromeLink.cpp(2243): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2323): warning C4018: “<”: 有符号/无符号不匹配
..\core\IChromeLink.cpp(2309): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2381): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2445): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2489): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2524): warning C4018: “<”: 有符号/无符号不匹配
..\core\IChromeLink.cpp(2611): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2676): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2715): warning C4018: “<”: 有符号/无符号不匹配
..\core\IChromeLink.cpp(2750): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2801): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2847): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2902): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(2948): warning C4101: “ex”: 未引用的局部变量
..\core\IChromeLink.cpp(3002): warning C4101: “ex”: 未引用的局部变量
正在创建库 ..\..\实验室\IChromeLink.lib 和对象 ..\..\实验室\IChromeLink.exp
正在生成代码
4 of 5569 functions ( 0.1%) were compiled, the rest were copied from previous compilation.
0 functions were new in current compilation
0 functions had inline decision re-evaluated but remain unchanged
已完成代码的生成
IChromeLink.vcxproj -> G:\C++Studio\IChromeLink\Projects\IChromeLink\..\..\实验室\IChromeLink.dll
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
#TargetFrameworkVersion=v4.0:PlatformToolSet=v141:EnableManagedIncrementalBuild=false:VCToolArchitecture=Native32Bit:WindowsTargetPlatformVersion=10.0.16299.0
Release|Win32|G:\C++Studio\IChromeLink\Projects\|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Empty file.
6 changes: 3 additions & 3 deletions Projects/IChromeLink/ThrowInterface.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -925,11 +925,11 @@ BOOL APIENTRY chrome_struct_cookie_secure(IChromeCookie *pCookie)
return FALSE;
}

__int64 APIENTRY chrome_struct_cookie_expires(IChromeCookie *pCookie)
double APIENTRY chrome_struct_cookie_expires(IChromeCookie *pCookie)
{
if (pCookie != NULL)
{
return pCookie->bSecure;
return pCookie->expires;
}
return FALSE;
}
Expand Down Expand Up @@ -959,7 +959,7 @@ BOOL APIENTRY chrome_accessor_delete_cookie(IChromeLink *pAccessor,const char *s
return FALSE;
}

BOOL APIENTRY chrome_accessor_set_cookie(IChromeLink *pAccessor,const char *szUrl, const char *szName, const char *szValue, const char *szDomain, const char *szPath, BOOL bSecure,__int64 expires, BOOL bHttpOnly)
BOOL APIENTRY chrome_accessor_set_cookie(IChromeLink *pAccessor,const char *szUrl, const char *szName, const char *szValue, const char *szDomain, const char *szPath, BOOL bSecure,double expires, BOOL bHttpOnly)
{
if (pAccessor != NULL)
{
Expand Down
16 changes: 13 additions & 3 deletions Projects/core/IChromeLink.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ using namespace Komari;
*/
BOOL IChromeLink::GetTabs(LPCTSTR szTraceAddr, IChromeCurTabs &Tabs)
{



Tabs.clear();
BOOL bResult = FALSE;
IStream strBuilderUrl;
Expand Down Expand Up @@ -2253,12 +2256,14 @@ BOOL IChromeLink::GetCookies(LPCTSTR szUrl, IChromeCookieVectors &Result)
for (size_t i = 0; i < nMax; i++)
{
json::value objChild = objCookies[i];
//MessageBox(NULL, objChild.serialize().c_str(), NULL, NULL);
Info.strDomain = objChild[U("domain")].as_string();
Info.strName = objChild[U("name")].as_string();
Info.strValue = objChild[U("value")].as_string();
Info.strPath = objChild[U("path")].as_string();
Info.bHttpOnly = objChild[U("httpOnly")].as_bool();
Info.bSecure = objChild[U("secure")].as_bool();
Info.expires = objChild[U("expires")].as_double();
Result.push_back(Info);
}
}
Expand Down Expand Up @@ -2324,7 +2329,7 @@ BOOL IChromeLink::GetAllCookies(IChromeCookieVectors &Result)
Info.strPath = objChild[U("path")].as_string();
Info.bHttpOnly = objChild[U("httpOnly")].as_bool();
Info.bSecure = objChild[U("secure")].as_bool();
Info.expires = objChild[U("expires")].as_number().to_int64();
Info.expires = objChild[U("expires")].as_double();
Result.push_back(Info);
}
}
Expand Down Expand Up @@ -2401,7 +2406,7 @@ szValue: ֵ
bHttpOnly: 默认为false.
返回: 如果返回真则操作是成功的
*/
BOOL IChromeLink::SetCookie(LPCTSTR szUrl, LPCTSTR szName, LPCTSTR szValue, LPCTSTR szDomain, LPCTSTR szPath, BOOL bSecure,__int64 expires, BOOL bHttpOnly)
BOOL IChromeLink::SetCookie(LPCTSTR szUrl, LPCTSTR szName, LPCTSTR szValue, LPCTSTR szDomain, LPCTSTR szPath, BOOL bSecure, double expires, BOOL bHttpOnly)
{
ASSERT_KEEP_LINKEDR(FALSE);
DWORD dwAutoId = this->GetAutoRand();
Expand All @@ -2416,9 +2421,14 @@ BOOL IChromeLink::SetCookie(LPCTSTR szUrl, LPCTSTR szName, LPCTSTR szValue, LPCT
objParams[U("domain")] = json::value::string(szDomain);
objParams[U("path")] = json::value::string(szPath);
objParams[U("secure")] = json::value::boolean(bSecure);
objParams[U("expires")] = json::value::number(expires);
if (expires > 0) {
objParams[U("expires")] = json::value::number(expires);
}

objParams[U("httpOnly")] = json::value::boolean(bHttpOnly);

//MessageBox(NULL, objParams.serialize().c_str(), NULL, NULL);

objRoot[TEXT("params")] = objParams;
std::string strBody = conversions::utf16_to_utf8(objRoot.serialize());
websocket_outgoing_message objMsg;
Expand Down
7 changes: 5 additions & 2 deletions Projects/core/IChromeLink.h
Original file line number Diff line number Diff line change
Expand Up @@ -182,9 +182,12 @@ namespace Komari {
IString strValue;
IString strDomain;
IString strPath;
IString strSameSite;
BOOL bHttpOnly;
BOOL bSecure;
__int64 expires;
BOOL session;
double expires;

};
typedef std::vector<IChromeCookie> IChromeCookieVectors;

Expand Down Expand Up @@ -766,7 +769,7 @@ private: \
bHttpOnly: 默认为false.
返回: 如果返回真则操作是成功的
*/
BOOL SetCookie(LPCTSTR szUrl, LPCTSTR szName, LPCTSTR szValue, LPCTSTR szDomain, LPCTSTR szPath, BOOL bSecure,__int64 expires, BOOL bHttpOnly);
BOOL SetCookie(LPCTSTR szUrl, LPCTSTR szName, LPCTSTR szValue, LPCTSTR szDomain, LPCTSTR szPath, BOOL bSecure,double expires, BOOL bHttpOnly);

/*
函数: GetResourceList
Expand Down
Binary file modified 实验室/IChromeLink.dll
Binary file not shown.
Binary file modified 实验室/module/Chrome DevTools Protocol V1.20.ec
Binary file not shown.
Binary file modified 实验室/src/Chrome 远程调试工具.bak
Binary file not shown.
Binary file modified 实验室/src/Chrome 远程调试工具.e
Binary file not shown.
Binary file modified 实验室/src/IChrome Link(接口).bak
Binary file not shown.
Binary file modified 实验室/src/IChrome Link(接口).e
Binary file not shown.
4 changes: 4 additions & 0 deletions 实验室/更新说明.txt
Original file line number Diff line number Diff line change
Expand Up @@ -207,3 +207,7 @@ IChromeLink V1.20
- ����: �Ż�ʾ������"Chrome Զ�̵��Թ���.e"�еIJ���ϸ������

- ����: ���¹淶�˲��ֺ������Լ���������

IChromeLink V1.21 ��2018/03/20��

- ������- -,cookie����"expires"��������ȷ����

0 comments on commit c7aa684

Please sign in to comment.