mirror of
https://github.com/SoftEtherVPN/SoftEtherVPN.git
synced 2025-09-20 02:09:25 +03:00
v4.17-9566-beta
This commit is contained in:
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
@ -155,7 +155,7 @@ namespace BuildUtil
|
||||
static object lockObj = new object();
|
||||
|
||||
// Digital-sign the data on the memory
|
||||
public static byte[] SignMemory(byte[] srcData, string comment, bool kernelModeDriver, int cert_id)
|
||||
public static byte[] SignMemory(byte[] srcData, string comment, bool kernelModeDriver, int cert_id, int sha_mode)
|
||||
{
|
||||
#if !BU_OSS
|
||||
int i;
|
||||
@ -176,10 +176,11 @@ namespace BuildUtil
|
||||
|
||||
try
|
||||
{
|
||||
out_filename = sign.ExecSign(Path.GetFileName(in_tmp_filename),
|
||||
out_filename = sign.ExecSignEx(Path.GetFileName(in_tmp_filename),
|
||||
kernelModeDriver,
|
||||
comment,
|
||||
cert_id);
|
||||
cert_id,
|
||||
sha_mode);
|
||||
break;
|
||||
}
|
||||
catch (Exception ex)
|
||||
@ -267,7 +268,15 @@ namespace BuildUtil
|
||||
Con.WriteLine("Signing for '{0}'...", Path.GetFileName(destFileName));
|
||||
byte[] srcData = File.ReadAllBytes(srcFileName);
|
||||
|
||||
byte[] destData = SignMemory(srcData, comment, kernelModeDriver, cert_id);
|
||||
int sha_mode = 0;
|
||||
|
||||
if (srcFileName.EndsWith(".msi", StringComparison.InvariantCultureIgnoreCase))
|
||||
{
|
||||
sha_mode = 1;
|
||||
// todo: Set 2 in future !!!
|
||||
}
|
||||
|
||||
byte[] destData = SignMemory(srcData, comment, kernelModeDriver, cert_id, sha_mode);
|
||||
|
||||
try
|
||||
{
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -1,7 +1,7 @@
|
||||
//------------------------------------------------------------------------------
|
||||
//------------------------------------------------------------------------------
|
||||
// <auto-generated>
|
||||
// このコードはツールによって生成されました。
|
||||
// ランタイム バージョン:2.0.50727.5466
|
||||
// ランタイム バージョン:2.0.50727.5485
|
||||
//
|
||||
// このファイルへの変更は、以下の状況下で不正な動作の原因になったり、
|
||||
// コードが再生成されるときに損失したりします。
|
||||
@ -104,7 +104,7 @@
|
||||
|
||||
|
||||
//
|
||||
// このソース コードは Microsoft.VSDesigner、バージョン 2.0.50727.5466 によって自動生成されました。
|
||||
// このソース コードは Microsoft.VSDesigner、バージョン 2.0.50727.5485 によって自動生成されました。
|
||||
//
|
||||
#pragma warning disable 1591
|
||||
|
||||
@ -118,7 +118,7 @@ namespace BuildUtil.HvSignService {
|
||||
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5420")]
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5483")]
|
||||
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
||||
[System.ComponentModel.DesignerCategoryAttribute("code")]
|
||||
[System.Web.Services.WebServiceBindingAttribute(Name="SignSoap", Namespace="http://hvsigncode/")]
|
||||
@ -128,6 +128,8 @@ namespace BuildUtil.HvSignService {
|
||||
|
||||
private System.Threading.SendOrPostCallback ExecSignOperationCompleted;
|
||||
|
||||
private System.Threading.SendOrPostCallback ExecSignExOperationCompleted;
|
||||
|
||||
private bool useDefaultCredentialsSetExplicitly;
|
||||
|
||||
/// <remarks/>
|
||||
@ -172,6 +174,9 @@ namespace BuildUtil.HvSignService {
|
||||
/// <remarks/>
|
||||
public event ExecSignCompletedEventHandler ExecSignCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
public event ExecSignExCompletedEventHandler ExecSignExCompleted;
|
||||
|
||||
/// <remarks/>
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://hvsigncode/HelloWorld", RequestNamespace="http://hvsigncode/", ResponseNamespace="http://hvsigncode/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
||||
public string HelloWorld() {
|
||||
@ -234,6 +239,43 @@ namespace BuildUtil.HvSignService {
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://hvsigncode/ExecSignEx", RequestNamespace="http://hvsigncode/", ResponseNamespace="http://hvsigncode/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
|
||||
public string ExecSignEx(string src_filename, bool driver_mode, string description, int cert_id, int sha_mode) {
|
||||
object[] results = this.Invoke("ExecSignEx", new object[] {
|
||||
src_filename,
|
||||
driver_mode,
|
||||
description,
|
||||
cert_id,
|
||||
sha_mode});
|
||||
return ((string)(results[0]));
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void ExecSignExAsync(string src_filename, bool driver_mode, string description, int cert_id, int sha_mode) {
|
||||
this.ExecSignExAsync(src_filename, driver_mode, description, cert_id, sha_mode, null);
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public void ExecSignExAsync(string src_filename, bool driver_mode, string description, int cert_id, int sha_mode, object userState) {
|
||||
if ((this.ExecSignExOperationCompleted == null)) {
|
||||
this.ExecSignExOperationCompleted = new System.Threading.SendOrPostCallback(this.OnExecSignExOperationCompleted);
|
||||
}
|
||||
this.InvokeAsync("ExecSignEx", new object[] {
|
||||
src_filename,
|
||||
driver_mode,
|
||||
description,
|
||||
cert_id,
|
||||
sha_mode}, this.ExecSignExOperationCompleted, userState);
|
||||
}
|
||||
|
||||
private void OnExecSignExOperationCompleted(object arg) {
|
||||
if ((this.ExecSignExCompleted != null)) {
|
||||
System.Web.Services.Protocols.InvokeCompletedEventArgs invokeArgs = ((System.Web.Services.Protocols.InvokeCompletedEventArgs)(arg));
|
||||
this.ExecSignExCompleted(this, new ExecSignExCompletedEventArgs(invokeArgs.Results, invokeArgs.Error, invokeArgs.Cancelled, invokeArgs.UserState));
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public new void CancelAsync(object userState) {
|
||||
base.CancelAsync(userState);
|
||||
@ -254,11 +296,11 @@ namespace BuildUtil.HvSignService {
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5420")]
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5483")]
|
||||
public delegate void HelloWorldCompletedEventHandler(object sender, HelloWorldCompletedEventArgs e);
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5420")]
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5483")]
|
||||
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
||||
[System.ComponentModel.DesignerCategoryAttribute("code")]
|
||||
public partial class HelloWorldCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
|
||||
@ -280,11 +322,11 @@ namespace BuildUtil.HvSignService {
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5420")]
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5483")]
|
||||
public delegate void ExecSignCompletedEventHandler(object sender, ExecSignCompletedEventArgs e);
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5420")]
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5483")]
|
||||
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
||||
[System.ComponentModel.DesignerCategoryAttribute("code")]
|
||||
public partial class ExecSignCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
|
||||
@ -304,6 +346,32 @@ namespace BuildUtil.HvSignService {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5483")]
|
||||
public delegate void ExecSignExCompletedEventHandler(object sender, ExecSignExCompletedEventArgs e);
|
||||
|
||||
/// <remarks/>
|
||||
[System.CodeDom.Compiler.GeneratedCodeAttribute("System.Web.Services", "2.0.50727.5483")]
|
||||
[System.Diagnostics.DebuggerStepThroughAttribute()]
|
||||
[System.ComponentModel.DesignerCategoryAttribute("code")]
|
||||
public partial class ExecSignExCompletedEventArgs : System.ComponentModel.AsyncCompletedEventArgs {
|
||||
|
||||
private object[] results;
|
||||
|
||||
internal ExecSignExCompletedEventArgs(object[] results, System.Exception exception, bool cancelled, object userState) :
|
||||
base(exception, cancelled, userState) {
|
||||
this.results = results;
|
||||
}
|
||||
|
||||
/// <remarks/>
|
||||
public string Result {
|
||||
get {
|
||||
this.RaiseExceptionIfNecessary();
|
||||
return ((string)(this.results[0]));
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning restore 1591
|
||||
|
@ -29,6 +29,24 @@
|
||||
</s:sequence>
|
||||
</s:complexType>
|
||||
</s:element>
|
||||
<s:element name="ExecSignEx">
|
||||
<s:complexType>
|
||||
<s:sequence>
|
||||
<s:element minOccurs="0" maxOccurs="1" name="src_filename" type="s:string" />
|
||||
<s:element minOccurs="1" maxOccurs="1" name="driver_mode" type="s:boolean" />
|
||||
<s:element minOccurs="0" maxOccurs="1" name="description" type="s:string" />
|
||||
<s:element minOccurs="1" maxOccurs="1" name="cert_id" type="s:int" />
|
||||
<s:element minOccurs="1" maxOccurs="1" name="sha_mode" type="s:int" />
|
||||
</s:sequence>
|
||||
</s:complexType>
|
||||
</s:element>
|
||||
<s:element name="ExecSignExResponse">
|
||||
<s:complexType>
|
||||
<s:sequence>
|
||||
<s:element minOccurs="0" maxOccurs="1" name="ExecSignExResult" type="s:string" />
|
||||
</s:sequence>
|
||||
</s:complexType>
|
||||
</s:element>
|
||||
</s:schema>
|
||||
</wsdl:types>
|
||||
<wsdl:message name="HelloWorldSoapIn">
|
||||
@ -43,6 +61,12 @@
|
||||
<wsdl:message name="ExecSignSoapOut">
|
||||
<wsdl:part name="parameters" element="tns:ExecSignResponse" />
|
||||
</wsdl:message>
|
||||
<wsdl:message name="ExecSignExSoapIn">
|
||||
<wsdl:part name="parameters" element="tns:ExecSignEx" />
|
||||
</wsdl:message>
|
||||
<wsdl:message name="ExecSignExSoapOut">
|
||||
<wsdl:part name="parameters" element="tns:ExecSignExResponse" />
|
||||
</wsdl:message>
|
||||
<wsdl:portType name="SignSoap">
|
||||
<wsdl:operation name="HelloWorld">
|
||||
<wsdl:input message="tns:HelloWorldSoapIn" />
|
||||
@ -52,6 +76,10 @@
|
||||
<wsdl:input message="tns:ExecSignSoapIn" />
|
||||
<wsdl:output message="tns:ExecSignSoapOut" />
|
||||
</wsdl:operation>
|
||||
<wsdl:operation name="ExecSignEx">
|
||||
<wsdl:input message="tns:ExecSignExSoapIn" />
|
||||
<wsdl:output message="tns:ExecSignExSoapOut" />
|
||||
</wsdl:operation>
|
||||
</wsdl:portType>
|
||||
<wsdl:binding name="SignSoap" type="tns:SignSoap">
|
||||
<soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
|
||||
@ -73,6 +101,15 @@
|
||||
<soap:body use="literal" />
|
||||
</wsdl:output>
|
||||
</wsdl:operation>
|
||||
<wsdl:operation name="ExecSignEx">
|
||||
<soap:operation soapAction="http://hvsigncode/ExecSignEx" style="document" />
|
||||
<wsdl:input>
|
||||
<soap:body use="literal" />
|
||||
</wsdl:input>
|
||||
<wsdl:output>
|
||||
<soap:body use="literal" />
|
||||
</wsdl:output>
|
||||
</wsdl:operation>
|
||||
</wsdl:binding>
|
||||
<wsdl:binding name="SignSoap12" type="tns:SignSoap">
|
||||
<soap12:binding transport="http://schemas.xmlsoap.org/soap/http" />
|
||||
@ -94,6 +131,15 @@
|
||||
<soap12:body use="literal" />
|
||||
</wsdl:output>
|
||||
</wsdl:operation>
|
||||
<wsdl:operation name="ExecSignEx">
|
||||
<soap12:operation soapAction="http://hvsigncode/ExecSignEx" style="document" />
|
||||
<wsdl:input>
|
||||
<soap12:body use="literal" />
|
||||
</wsdl:input>
|
||||
<wsdl:output>
|
||||
<soap12:body use="literal" />
|
||||
</wsdl:output>
|
||||
</wsdl:operation>
|
||||
</wsdl:binding>
|
||||
<wsdl:service name="Sign">
|
||||
<wsdl:port name="SignSoap" binding="tns:SignSoap">
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
@ -3,9 +3,9 @@
|
||||
//
|
||||
// SoftEther VPN Server, Client and Bridge are free software under GPLv2.
|
||||
//
|
||||
// Copyright (c) 2012-2014 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2014 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2014 SoftEther Corporation.
|
||||
// Copyright (c) 2012-2015 Daiyuu Nobori.
|
||||
// Copyright (c) 2012-2015 SoftEther VPN Project, University of Tsukuba, Japan.
|
||||
// Copyright (c) 2012-2015 SoftEther Corporation.
|
||||
//
|
||||
// All Rights Reserved.
|
||||
//
|
||||
|
Reference in New Issue
Block a user