Quantcast
Channel: Chilkat Forum - latest questions
Viewing all 1061 articles
Browse latest View live

Link Error

$
0
0

I have two main projects. Project #1 links fine in debug and release mode. Project #1 links fine in debug but in release mode the error is LNK2005.

I'm using VS2008 SP1.

I have read the README.html and I have read the Chilkat blog post about Visual C++ linking: http://www.cknotes.com/?p=23

My projects are not Statically Linked.

Compared the Project Properties and they as the same !

What did I do wrong ?


Salesforce OAuth2 with Xojo Cloud Project?

$
0
0

Am evaluating your OAuth2 feature for use in a Xojo Cloud project that will integrate with Salesforce.

First of all, your example code does not compile, but I fixed that.

My questions are about the callback and the redirect. Why is the callback is set to "localhost:3017"? I understand that 3017 is the port... my real question is about the localhost part.

Also, I noticed that at the end of the OAuth2 process the browser redirects to a page on the Chilkat site. How do I control/change this?

ckSSH Bug example function

$
0
0

Hi!

Again problem with 100% CPU Load. Problem in function CksshDispose, if connection unsuccesful, function CkSshDispose(ssh) waiting near 20 seconds, then 1 core load 100% near 30 seconds, then programm continuing... If connection without socks proxy, Ckssh_Dispose work fine. ChilkatDelphiXE.dll

Here is simple function.

function ssh(ip,port,user,pass,socksip,socksport,sockstype:String):string;
var task:HCkTask;
ssh: HCkSsh;
success: Boolean;

begin
 ssh := CkSsh_Create();

 if socksip<>'' then
 begin

  CkSsh_putSocksHostname(ssh,pchar(socksip));
  CkSsh_putSocksPort(ssh,strtoint(socksport));
 if sockstype='SOCKS5' then CkSsh_putSocksVersion(ssh,5) else
 CkSsh_putSocksVersion(ssh,4);
 end;

 task := CkSsh_ConnectAsync(ssh,pchar(ip),strtoint(port));
 success:=CkTask_Run(task);

   CkTask_Wait(task,10000);

if (success <> True) then
  begin
    CkTask_Dispose(task);
    CkSsh_Dispose(ssh);
    Exit;
  end;

success:=CkTask_GetResultBool (task);

if (success <> True) then
  begin

   CkTask_Dispose(task);
   CkSsh_Dispose(ssh);   // HERE IS BUG!!!!!!!!!!!!!!!!!!!!
    Exit;
  end;
 CkTask_Dispose(task);
 CkSsh_Disconnect(ssh);
 CkSsh_Dispose(ssh);
end;

websocket implementation

$
0
0

Hi

Does Chilkat include C++ library that implements the WebSocket Protocol? One that implements the client functionality.

With Regards. alon.

How to Install an Assembly into the Global Assembly Cache?

$
0
0

How to install a .NET assembly into the GAC?

task - documentation?

Read received json data as unicode values for arabic/russian language

$
0
0

Hello, I am stuck with a Problem related to json & http requests.

The page I want to read contains json data, which contain arabic or russian text.

In Firefox I can see a view for "json" and a view for "rawdata". Json shows the correct language chars used in arabic or russian. Rawdata shows instead e.g. "u0643"...

I did try:

http.put_AcceptCharset(L"utf-8");

//  Send the HTTP GET and return the content in a string.
const wchar_t *html = 0;
html = http.quickGetStr(L"https://api.access-some-site.org/mytoken/getdata");

MessageBoxW(0,html,L"My Data",0);

It seems to always get the rawdata and this means "u0643", not the char!

Now my question: Is there a way to Access my URL to the json via CkHttpW somehow?

Java - application has failed to start because its side-by-side configuration is incorrect

$
0
0

I get the following error with the Chilkat Java DLL on a Windows Server 2008 system:

java.lang.UnsatisfiedLinkError: N:\FTP\myApp\chilkat\chilkat.dll: 
The application has failed to start because its side-by-side configuration is incorrect. 
Please see the application event log or use the command-line sxstrace.exe tool for more detail
This uses the 64-bit DLL.


(PowerBuilder) POP3 CopyMail() returns NULL EmailBundle

$
0
0

Hello there,

we are running an automated pop3fetcher (for attachments) powered by Chilkat Mail (Active X) on PB 10.5

It works really well, but we now encounter an error on a Windows 2008 Terminal Server machine when no user is logged in and our application is run as an automated task (windows task scheduler -> security options -> ‘Run whether user is logged on or not‘).

I'm using CopyMail() to get the Emails into the Mailbundle oleobject, wich I then test with:

if isvalid(loo_mailbundle) then

The mailbundle being NULL, I checked with GetLastErrorText to find:

unEnvelope3:
  unEnvelope_encrypted:
    findMatchingPrivateKeyFromSysCerts:
      numRecipientInfos: 1
      certSerialNumber: ---blacked---
      certIssuerCN: COMODO SHA-256 Client Authentication and Secure Email CA
      certIssuerDN: GB, Greater Manchester, Salford, COMODO CA Limited, COMODO SHA-256
Client Authentication and Secure Email CA
      subjectKeyIdentifier: 
      findPrivateKey:
        certGetPrivateKeyAsDER:
          msCertGetPrivateKey:
            openCertKeyContainer:
              acquirePrivateKey:
                WindowsError: Das System kann die angegebene Datei nicht finden.
                WindowsErrorCode: 0x2
              --acquirePrivateKey
            --openCertKeyContainer
            Failed to open key container for certificate.
          --msCertGetPrivateKey
        --certGetPrivateKeyAsDER
        No private key available.
      --findPrivateKey
    --findMatchingPrivateKeyFromSysCerts
    No certificate with private key found.
  --unEnvelope_encrypted
--unEnvelope3
Failed to unenvelope message

I tried solving this issues by using mailman.AddPfxSourceFile() and mailman.SetDecryptCert() respectively, which now results in the same NULL EmailBundle, but I can't seem to be able to find the error in the LastErrorText:

06:30:05 ChilkatLog:
  CopyMail:
    DllDate: Aug 26 2015
    ChilkatVersion: 9.5.0.52
    UnlockPrefix: ISSOFTMAILQ
    Username: EPHTS01:is-software
    Architecture: Little Endian; 32-bit
    Language: ActiveX
    VerboseLogging: 0
    PopCmdSent: STAT
    PopCmdResp: +OK 2 74487
    statResponse: +OK 2 74487
    numMessages: 2
    fetchFullEmails:
      PopCmdSent: LIST
      PopCmdResp: +OK 2 messages (74487) octets
1 62760
2 11727
.
      PopCmdSent: UIDL
      PopCmdResp: +OK 2 messages (74487) octets
      PopCmdResp: 1 201705310141180228
2 201705310430490266
.
      fetchSingleFull:
        PopCmdSent: RETR 1
        PopCmdResp: +OK 62760 octets
        rawMimeToEmail:
          createFromPop3:
            createFromMimeObject:
              unwrapSecurity:
                unwrapInner2:
                  Unwrapping enveloped (encrypted or signed)...
                  unenvelope:
                    loadPkcs7Der:
                      loadPkcs7Xml:
                        Pkcs7_EnvelopedData:
                          AlgorithmIdentifier_loadXml:
                            encryptionAlgorithmOid: 1.2.840.113549.3.7
                            IV: hFTIdpLYdAA=
                          --AlgorithmIdentifier_loadXml
                          numRecipients: 1
                          RecipientInfo:
                            IssuerAndSerialNumber:
                              serialNumber1: ----blacked out----
                              issuerCommonName: COMODO SHA-256 Client Authentication and Secure Email CA
                              issuerCountry: GB
                              issuerState: Greater Manchester
                              issuerLocality: Salford
                              issuerOrganization: COMODO CA Limited
                            --IssuerAndSerialNumber
                            encryptedKeyNumBytes: 256
                          --RecipientInfo
                        --Pkcs7_EnvelopedData
                      --loadPkcs7Xml
                    --loadPkcs7Der
                    unEnvelope3:
                      unEnvelope_encrypted:
                        findMatchingPrivateKeyFromSysCerts:
                          numRecipientInfos: 1
                          certSerialNumber: ----blacked out----
                          certIssuerCN: COMODO SHA-256 Client Authentication and Secure Email CA
                          subjectKeyIdentifier: 
                        --findMatchingPrivateKeyFromSysCerts
                        AlgorithmIdentifier:
                          oid: 1.2.840.113549.1.1.1
                        --AlgorithmIdentifier
                        Decrypting symmetric key...(1)
                        Decrypting data using symmetric key (1)
                        decryptedSymmetricKeyLen1: 24
                        symmetricDecrypt:
                          algId_oid: 1.2.840.113549.3.7
                          DES3_CBC
                          symmetricKeySizeInBytes: 24
                          numBytesToDecrypt: 43552
                          algorithm: des
                          keyLength: 192
                          outputSize: 43545
                          symmetricDecryptOutputSize: 43545
                        --symmetricDecrypt
                      --unEnvelope_encrypted
                    --unEnvelope3
                    cert_issuer: GB, Greater Manchester, Salford, COMODO CA Limited, COMODO SHA-256 Client
Authentication and Secure Email CA
                    cert_subject: ----blacked out-----
                    unenvelopedDataSize: 43545
                  --unenvelope
                  Unwrapping multipart/signed...
                  unwrapMultipartSigned:
                    loadPkcs7Der:
                      loadPkcs7Xml:
                        loadSignedDataXml:
                          NumDigestAlgorithmIdentifiers: 1
                          AlgorithmIdentifier:
                            oid: 2.16.840.1.101.3.4.2.1
                          --AlgorithmIdentifier
                          This is a detached signature.
                          numSigners: 1
                          SignerInfo:
                            signerInfoLoadXml:
                              contentType: 1.2.840.113549.1.7.1
                              messageDigestHex: 5DFE 893D 202B 2865 DA49 D6D1 05BC 1B5C
CC21 F5A0 A57E 0529 0FBA EF9E 0380 FF0F
                              signingTime: 170530234117Z
                            --signerInfoLoadXml
                          --SignerInfo
                        --loadSignedDataXml
                      --loadPkcs7Xml
                      extractCertsFromSignedData:
                        numCerts: 1
                      --extractCertsFromSignedData
                    --loadPkcs7Der
                    verifyDetachedSignature:
                      verifySignature:
                        numSigners: 1
                        numDigestAlgorithms: 1
                        Computing SHA256 message digest.
                        numBytesDigested: 39937
                        numSigners: 1
                        signerDigestAlgOid: 2.16.840.1.101.3.4.2.1
                        messageDigestSize: 32
                        Signer_0:
                          getSignerInfoCert:
                            issuerCN: QuoVadis Swiss Advanced CA G2
                            serialNum: 5D31C5EB69BA6780CE4D46547E18350003085DFA
                          --getSignerInfoCert
                          digestOid: 2.16.840.1.101.3.4.2.1
                          Digest of authenticated attributes DER matches.
                        --Signer_0
                        Signature verified but skipping verification of certificates.
                      --verifySignature
                    --verifyDetachedSignature
                  --unwrapMultipartSigned
                --unwrapInner2
                A signed and encrypted email was received
                All signatures are valid
                All data successfully decrypted
                num_parts_signed: 1
                num_parts_encrypted: 1
              --unwrapSecurity
            --createFromMimeObject
          --createFromPop3
        --rawMimeToEmail
      --fetchSingleFull
      fetchSingleFull:
        PopCmdSent: RETR 2
        PopCmdResp: +OK 11727 octets
        rawMimeToEmail:
          createFromPop3:
            createFromMimeObject:
              unwrapSecurity:
                unwrapInner2:
                  Unwrapping enveloped (encrypted or signed)...
                  unenvelope:
                    loadPkcs7Der:
                      loadPkcs7Xml:
                        Pkcs7_EnvelopedData:
                          AlgorithmIdentifier_loadXml:
                            encryptionAlgorithmOid: 1.2.840.113549.3.7
                            IV: JnLJoCnHeao=
                          --AlgorithmIdentifier_loadXml
                          numRecipients: 1
                          RecipientInfo:
                            IssuerAndSerialNumber:
                              serialNumber1: ----blacked out----
                              issuerCommonName: COMODO SHA-256 Client Authentication and Secure Email CA
                              issuerCountry: GB
                              issuerState: Greater Manchester
                              issuerLocality: Salford
                              issuerOrganization: COMODO CA Limited
                            --IssuerAndSerialNumber
                            encryptedKeyNumBytes: 256
                          --RecipientInfo
                        --Pkcs7_EnvelopedData
                      --loadPkcs7Xml
                    --loadPkcs7Der
                    unEnvelope3:
                      unEnvelope_encrypted:
                        findMatchingPrivateKeyFromSysCerts:
                          numRecipientInfos: 1
                          certSerialNumber: ----blacked out----
                          certIssuerCN: COMODO SHA-256 Client Authentication and Secure Email CA
                          subjectKeyIdentifier: 
                        --findMatchingPrivateKeyFromSysCerts
                        AlgorithmIdentifier:
                          oid: 1.2.840.113549.1.1.1
                        --AlgorithmIdentifier
                        Decrypting symmetric key...(1)
                        Decrypting data using symmetric key (1)
                        decryptedSymmetricKeyLen1: 24
                        symmetricDecrypt:
                          algId_oid: 1.2.840.113549.3.7
                          DES3_CBC
                          symmetricKeySizeInBytes: 24
                          numBytesToDecrypt: 6472
                          algorithm: des
                          keyLength: 192
                          outputSize: 6465
                          symmetricDecryptOutputSize: 6465
                        --symmetricDecrypt
                      --unEnvelope_encrypted
                    --unEnvelope3
                    cert_issuer: GB, Greater Manchester, Salford, COMODO CA Limited, COMODO SHA-256 Client
Authentication and Secure Email CA
                    cert_subject:  ----blacked out-----
                    unenvelopedDataSize: 6465
                  --unenvelope
                  Unwrapping multipart/signed...
                  unwrapMultipartSigned:
                    loadPkcs7Der:
                      loadPkcs7Xml:
                        loadSignedDataXml:
                          NumDigestAlgorithmIdentifiers: 1
                          AlgorithmIdentifier:
                            oid: 2.16.840.1.101.3.4.2.1
                          --AlgorithmIdentifier
                          This is a detached signature.
                          numSigners: 1
                          SignerInfo:
                            signerInfoLoadXml:
                              contentType: 1.2.840.113549.1.7.1
                              messageDigestHex: 675D A97B 677A 11C8 8B86 E392 7F2D 1549
0529 1C40 C58E 3484 6023 C4A2 98D2 DF58
                              signingTime: 170531023048Z
                            --signerInfoLoadXml
                          --SignerInfo
                        --loadSignedDataXml
                      --loadPkcs7Xml
                      extractCertsFromSignedData:
                        numCerts: 1
                      --extractCertsFromSignedData
                    --loadPkcs7Der
                    verifyDetachedSignature:
                      verifySignature:
                        numSigners: 1
                        numDigestAlgorithms: 1
                        Computing SHA256 message digest.
                        numBytesDigested: 2823
                        numSigners: 1
                        signerDigestAlgOid: 2.16.840.1.101.3.4.2.1
                        messageDigestSize: 32
                        Signer_0:
                          getSignerInfoCert:
                            issuerCN: QuoVadis Swiss Advanced CA G2
                            serialNum: 11D2B6AE5FD0234D4A1A1890F5061F2648D066CC
                          --getSignerInfoCert
                          digestOid: 2.16.840.1.101.3.4.2.1
                          Digest of authenticated attributes DER matches.
                        --Signer_0
                        Signature verified but skipping verification of certificates.
                      --verifySignature
                    --verifyDetachedSignature
                  --unwrapMultipartSigned
                --unwrapInner2
                A signed and encrypted email was received
                All signatures are valid
                All data successfully decrypted
                num_parts_signed: 1
                num_parts_encrypted: 1
              --unwrapSecurity
            --createFromMimeObject
          --createFromPop3
        --rawMimeToEmail
      --fetchSingleFull
    --fetchFullEmails
    Success.
  --CopyMail
--ChilkatLog

The thing is, as soon as I log in with the user the background task is already running at, it works and even continues to work flawlessly when logging out again, until the task is restarted over night.

Are there any specific Windows services needed to be running?

Maybe someone encountered a similar issue, or sees more in this protocol than me.

Thank you for your time.

RTSP over SSL configuration using chilkat

$
0
0

I am trying to configure client and server application using chilkat nuget package of ASP.Net but client is not listening server properly, I really don't have any idea about chilkat and wanted to know whether RTSP over SSL is possible in Chilkat or not ?

Thank You.

Chilkat to Xojo example

$
0
0

Hi,

I am very much interested to buy CHILKAT for XOJO. But It seems there is no actual sample that is ready to run after downloading the plugin.

Do we have sample file that we can use to learn how it works?

SyncLocalTree progress

$
0
0

Hi

Is it possible to get overall progress events from SyncLocalTree?

I can hook up OnPercentDone but then I get PER file progress not the overall percentage.

Is there a way perhaps to find out how many file/directories the function will download?

Thank you Peter

Golang Support?

$
0
0

I have two questions:

  1. Are there any plans to port Chilkat to golang?
  2. If not is it possible for golang access the c++ libs and use chilkat that way?

Any info is appreciated.

OpenMyEmbedded help

$
0
0

Hello,

I'm having some difficulties with the Zip library.

My goal is to open and extract a zip file that is an embedded resource.

So from the reference page I do:

public bool OpenMyEmbedded(string resourceName);

But I don't know what to put for resourceName. I have tried the resource name, the file name and a several combinations of the namespace/filename etc.

My zip file is name myData.zip and it's in a folder named Resources in the Solution Explorer in VS.

bool success = zip.OpenMyEmbedded("?? what do I put here ??");

Every time the error I receive is: Resource not found within my EXE

What am I doing wrong?

I'm using ChilkatDotNet4 for .Net 4.0 32-bit

Thanks!

Failed to validate MAC

$
0
0

Hi,

I'm new to Chilkat Plug-in for XOJO and I tried to use it and run some sample from "https://www.example-code.com/xojo/firebase_jwt_authentication.asp"

After the component unlock using trial key, I end up getting a response that say's "Failed to validate MAC".

Anybody here that can enlighten me?


Mail class, address validation

$
0
0

Howdy,

I'd like to know if chilkat has any class/method to validate the address, for example:

kkk dd@domain.tld <= should return false for validation kkk-dd@domain.tld <= should return true ççç-dd@domain.tld <= should return false

Jorge,

http SynchronousRequest 9.5.0.39 vs 9.5.0.54

$
0
0

I have a problem when updating version of chilkat DLL (ActiveX).

I'm using Visual FoxPro 9 to create the .EXE and using the same one with both DLL's.

With version 9.5.0.39 all works fine an I have this LastErrorXml:

<ChilkatLog>
<SynchronousRequest>
    <DllDate>May  9 2014</DllDate>
    <ChilkatVersion>9.5.0.39</ChilkatVersion>
    <UnlockPrefix>ELABORHttp</UnlockPrefix>
    <Username>CTFSVR:Fernanda</Username>
    <Architecture>Little Endian; 32-bit</Architecture>
    <Language>ActiveX</Language>
    <VerboseLogging>1</VerboseLogging>
    <domain>servicos.portaldasfinancas.gov.pt</domain>
    <port>701</port>
    <ssl>1</ssl>
    <httpRequest>
        <httpVersion>1.1</httpVersion>
        <verb>POST</verb>
        <path>/sgdtws/documentosTransporte</path>
        <contentType />
        <charset>windows-1252</charset>
        <sendCharset>0</sendCharset>
        <mimeHeader>SOAPAction: envioDocumentoTransporte</mimeHeader>
    </httpRequest>
    <readTimeout>20</readTimeout>
    <connectTimeout>10</connectTimeout>
    <fullRequest>
        <httpRequest>
            <httpVersion>1.1</httpVersion>
            <verb>POST</verb>
            <path>/sgdtws/documentosTransporte</path>
            <contentType />
            <charset>windows-1252</charset>
            <sendCharset>0</sendCharset>
            <mimeHeader>SOAPAction: envioDocumentoTransporte</mimeHeader>
        </httpRequest>
        <HttpOptions>
            <AddHostHeader>1</AddHostHeader>
            <AllowCookieResponseCaching>0</AllowCookieResponseCaching>
            <AllowGzip>1</AllowGzip>
            <ConnectTimeoutMs>10000</ConnectTimeoutMs>
            <CookieDir />
            <FollowRedirects>1</FollowRedirects>
            <Login />
            <LoginDomain />
            <AuthMethod />
            <MaxResponseSize>0</MaxResponseSize>
            <MaxUrlLen>2000</MaxUrlLen>
            <PasswordLen>0</PasswordLen>
            <ProxyHostname />
            <ProxyLogin />
            <ProxyLogin />
            <ProxyAuthDomain />
            <ProxyPasswordLen>0</ProxyPasswordLen>
            <ProxyPort>80</ProxyPort>
            <ReadTimeoutMs>20000</ReadTimeoutMs>
            <RequiredContentType />
            <ResumePoint>0</ResumePoint>
            <SaveCookies>1</SaveCookies>
            <SendBufferSize>65535</SendBufferSize>
            <SendCookies>1</SendCookies>
            <SslProtocol>0</SslProtocol>
            <UnavailableRetryCount>0</UnavailableRetryCount>
            <UnavailableRetryWaitMs>2000</UnavailableRetryWaitMs>
        </HttpOptions>
        <a_synchronousRequest>
            <generateRequest>
                <httpRequestGenStartLine>
                    <authOnly>0</authOnly>
                    <hasMimeBody>1</hasMimeBody>
                    <genStartLine>
                        <startLine>POST /sgdtws/documentosTransporte HTTP/1.1</startLine>
                    </genStartLine>
                </httpRequestGenStartLine>
                <genHeaderSb>
                    <getMimeHeaderHttp>
                        <headerField>SOAPAction: envioDocumentoTransporte</headerField>
                    </getMimeHeaderHttp>
                </genHeaderSb>
                <addCookies>
                    <info>Not auto-adding cookies.</info>
                </addCookies>
                <addHostHeader>servicos.portaldasfinancas.gov.pt</addHostHeader>
            </generateRequest>
            <fullHttpRequest>
                <domain>servicos.portaldasfinancas.gov.pt</domain>
                <port>701</port>
                <ssl>1</ssl>
                <openHttpConnection>
                    <info>Opening connection directly to HTTP server.</info>
                    <httpHostname>servicos.portaldasfinancas.gov.pt</httpHostname>
                    <httpPort>701</httpPort>
                    <ssl>1</ssl>
                    <bUsingHttpProxy>0</bUsingHttpProxy>
                    <httpProxyAuthMethod />
                    <connect2>
                        <hostname>servicos.portaldasfinancas.gov.pt</hostname>
                        <port>701</port>
                        <ssl>1</ssl>
                        <connectImplicitSsl>
                            <connectSocket>
                                <domainOrIpAddress>servicos.portaldasfinancas.gov.pt</domainOrIpAddress>
                                <port>701</port>
                                <connectTimeoutMs>20000</connectTimeoutMs>
                                <connect_ipv6_or_ipv4>
                                    <info>Multi-threaded domain to IP address resolution</info>
                                    <AddrInfoList>
                                        <AddrInfo>
                                            <ai_flags>0</ai_flags>
                                            <ai_family>2</ai_family>
                                            <ai_socktype>0</ai_socktype>
                                            <ai_protocol>0</ai_protocol>
                                            <ai_addrlen>16</ai_addrlen>
                                            <ai_canonname>(NULL)</ai_canonname>
                                        </AddrInfo>
                                    </AddrInfoList>
                                    <info>connecting to IPV4 address...</info>
                                    <ipAddress>213.13.158.240</ipAddress>
                                    <connect>
                                        <info>Waiting for the connect to complete...</info>
                                        <myIP>192.168.1.94</myIP>
                                        <myPort>1634</myPort>
                                        <info>socket connect successful.</info>
                                    </connect>
                                </connect_ipv6_or_ipv4>
                            </connectSocket>
                            <cacheClientCerts>
                                <info>Found cert with private key.</info>
                            </cacheClientCerts>
                            <clientHandshake2>
                                <sendCertificateVerify>
                                    <info>Sending ClientCertVerify message...</info>
                                    <ModulusLen>257</ModulusLen>
                                    <DLen>256</DLen>
                                    <PLen>129</PLen>
                                    <QLen>129</QLen>
                                    <DPLen>129</DPLen>
                                    <DQLen>128</DQLen>
                                    <InvQLen>129</InvQLen>
                                    <signSslSig>
                                        <signatureSize>256</signatureSize>
                                    </signSslSig>
                                </sendCertificateVerify>
                                <checkServerCert>
                                    <info>Not verifying server certificate...</info>
                                    <info>Set the RequireSslCertVerify property to true to enable verification.</info>
                                </checkServerCert>
                                <info>Secure Channel Established.</info>
                            </clientHandshake2>
                        </connectImplicitSsl>
                        <connectElapsedMs>109</connectElapsedMs>
                        <info>HTTP connection succeeded.</info>
                    </connect2>
                    <connectTime>Elapsed time: 109 millisec</connectTime>
                    <startLine>POST /sgdtws/documentosTransporte HTTP/1.1</startLine>
                    <requestHeader>
                        <requestHeader><![CDATA[SOAPAction: envioDocumentoTransporte Host: servicos.portaldasfinancas.gov.pt:701 Content-Length: 3057]]></requestHeader>
                    </requestHeader>
                    <sendRequestHeader>
                        <sendHeaderElapsedMs>0</sendHeaderElapsedMs>
                    </sendRequestHeader>
                    <sendRequestBody>
                        <sendBodyElapsedMs>0</sendBodyElapsedMs>
                    </sendRequestBody>
                    <readResponseHeader>
                        <responseHeader><![CDATA[HTTP/1.1 200 OK X-Backside-Transport: OK OK Connection: Keep-Alive Transfer-Encoding: chunked Date: Tue, 22 Dec 2015 17:41:25 GMT Set-Cookie: gdtws_JSessionID=VTzpW5LFWGJWJT2yS4y8pTWq8LWfrBp8Z5JyMpLz2N8JmX8rPxmF!285905933; path=/; HttpOnly Content-Type: text/xml X-Client-IP: 10.186.1.65 Set-Cookie: SERVICOS-48386- G_SERVICOS_TCP701=HCIOLPAKLNAC; Expires=Tue, 22-Dec-2015 19:41:25 GMT; Path=/ ]]></responseHeader>
                    </readResponseHeader>
                    <statusCode>200</statusCode>
                    <statusText>OK</statusText>
                    <readResponseBody>
                        <info>Response has no Content-Length header.</info>
                    </readResponseBody>
                </openHttpConnection>
                <success>1</success>
            </fullHttpRequest>
        </a_synchronousRequest>
        <totalTime>Elapsed time: 281 millisec</totalTime>
        <info>Success.</info>
    </fullRequest>
</SynchronousRequest>
</chilkatlog>

With version 9.5.0.54 nothing works an I have this LastErrorXml:

<ChilkatLog>
<SynchronousRequest ms="140">
    <DllDate>Oct 29 2015</DllDate>
    <ChilkatVersion>9.5.0.54</ChilkatVersion>
    <UnlockPrefix>ELABORHttp</UnlockPrefix>
    <Username>WIN7-PC:win7</Username>
    <Architecture>Little Endian; 32-bit</Architecture>
    <Language>ActiveX</Language>
    <VerboseLogging>1</VerboseLogging>
    <domain>servicos.portaldasfinancas.gov.pt</domain>
    <port>701</port>
    <ssl>1</ssl>
    <httpRequest>
        <httpVersion>1.1</httpVersion>
        <verb>POST</verb>
        <path>/sgdtws/documentosTransporte</path>
        <contentType />
        <charset>windows-1252</charset>
        <sendCharset>0</sendCharset>
        <mimeHeader>SOAPAction: envioDocumentoTransporte</mimeHeader>
    </httpRequest>
    <readTimeout>20</readTimeout>
    <connectTimeout>30</connectTimeout>
    <computeRequestDataSize>
        <info>Request body is in a memory buffer..</info>
    </computeRequestDataSize>
    <approxRequestSize>3052</approxRequestSize>
    <fullRequest ms="140">
        <httpRequest>
            <httpVersion>1.1</httpVersion>
            <verb>POST</verb>
            <path>/sgdtws/documentosTransporte</path>
            <contentType />
            <charset>windows-1252</charset>
            <sendCharset>0</sendCharset>
            <mimeHeader>SOAPAction: envioDocumentoTransporte</mimeHeader>
        </httpRequest>
        <HttpOptions>
            <AddHostHeader>1</AddHostHeader>
            <AllowCookieResponseCaching>0</AllowCookieResponseCaching>
            <AllowGzip>1</AllowGzip>
            <CookieDir />
            <FollowRedirects>1</FollowRedirects>
            <Login />
            <LoginDomain />
            <AuthMethod />
            <MaxResponseSize>0</MaxResponseSize>
            <MaxUrlLen>2000</MaxUrlLen>
            <PasswordLen>0</PasswordLen>
            <ReadTimeoutMs>20000</ReadTimeoutMs>
            <RequiredContentType />
            <ResumePoint>0</ResumePoint>
            <SaveCookies>1</SaveCookies>
            <SendBufferSize>65535</SendBufferSize>
            <SendCookies>1</SendCookies>
            <UnavailableRetryCount>0</UnavailableRetryCount>
            <UnavailableRetryWaitMs>2000</UnavailableRetryWaitMs>
        </HttpOptions>
        <a_synchronousRequest ms="140">
            <generateRequest>
                <httpRequestGenStartLine>
                    <authOnly>0</authOnly>
                    <hasMimeBody>1</hasMimeBody>
                    <genStartLine>
                        <startLine>POST /sgdtws/documentosTransporte HTTP/1.1</startLine>
                    </genStartLine>
                </httpRequestGenStartLine>
                <genHeaderSb>
                    <getMimeHeaderHttp>
                        <headerField>SOAPAction: envioDocumentoTransporte</headerField>
                    </getMimeHeaderHttp>
                </genHeaderSb>
                <addCookies>
                    <info>Not auto-adding cookies.</info>
                    <sendCookies>1</sendCookies>
                    <cookieDir />
                </addCookies>
                <addHostHeader>servicos.portaldasfinancas.gov.pt</addHostHeader>
            </generateRequest>
            <fullHttpRequest ms="140">
                <domain>servicos.portaldasfinancas.gov.pt</domain>
                <port>701</port>
                <ssl>1</ssl>
                <openHttpConnection ms="93">
                    <info>Opening connection directly to HTTP server.</info>
                    <httpHostname>servicos.portaldasfinancas.gov.pt</httpHostname>
                    <httpPort>701</httpPort>
                    <ssl>1</ssl>
                    <bUsingHttpProxy>0</bUsingHttpProxy>
                    <httpProxyAuthMethod />
                    <socket2Connect ms="93">
                        <connect2 ms="93">
                            <hostname>servicos.portaldasfinancas.gov.pt</hostname>
                            <port>701</port>
                            <ssl>1</ssl>
                            <connectImplicitSsl ms="93">
                                <info>Clearing TLS client certificates.</info>
                                <connectSocket ms="31">
                                    <domainOrIpAddress>servicos.portaldasfinancas.gov.pt</domainOrIpAddress>
                                    <port>701</port>
                                    <connectTimeoutMs>30000</connectTimeoutMs>
                                    <connect_ipv6_or_ipv4 ms="31">
                                        <info>Multi-threaded domain to IP address resolution</info>
                                        <info>connecting to IPV4 address...</info>
                                        <ipAddress>213.13.158.240</ipAddress>
                                        <createSocket>
                                            <info>Setting SO_SNDBUF size</info>
                                            <sendBufSize>262144</sendBufSize>
                                            <info>Setting SO_RCVBUF size</info>
                                            <recvBufSize>4194304</recvBufSize>
                                        </createSocket>
                                        <connect ms="31">
                                            <info>Waiting for the connect to complete...</info>
                                            <myIP>192.168.1.75</myIP>
                                            <myPort>53945</myPort>
                                            <info>socket connect successful.</info>
                                        </connect>
                                    </connect_ipv6_or_ipv4>
                                </connectSocket>
                                <clientHandshake ms="62">
                                    <certChain>
                                        <subjectDN>C=PT, ST=LISBOA, L=LISBOA, O=AT - Autoridade Tributaria e Aduaneira, OU=ASI, CN=TestesWebServices</subjectDN>
                                        <subjectDN>DC=local, DC=ritta, CN=DGITA Issuing CA1</subjectDN>
                                        <subjectDN>DC=local, DC=ritta, CN=DGITA Root CA</subjectDN>
                                    </certChain>
                                    <cacheClientCerts>
                                        <info>Cached TLS client certificates.</info>
                                        <certChain>
                                            <subjectDN>C=PT, ST=LISBOA, L=LISBOA, O=AT - Autoridade Tributaria e Aduaneira, OU=ASI, CN=TestesWebServices</subjectDN>
                                            <subjectDN>DC=local, DC=ritta, CN=DGITA Issuing CA1</subjectDN>
                                            <subjectDN>DC=local, DC=ritta, CN=DGITA Root CA</subjectDN>
                                        </certChain>
                                    </cacheClientCerts>
                                    <clientHandshake2 ms="62">
                                        <readHandshakeMessages>
                                            <processHandshakeRecord>
                                                <processHandshakeMessage>
                                                    <processServerHello>
                                                        <MajorVersion>3</MajorVersion>
                                                        <MinorVersion>3</MinorVersion>
                                                        <cipherSuite>RSA_WITH_AES_256_CBC_SHA</cipherSuite>
                                                        <cipherSuiteNumeric>00,35</cipherSuiteNumeric>
                                                        <compressionMethod>0</compressionMethod>
                                                        <minAcceptableRsaKeySize>1024</minAcceptableRsaKeySize>
                                                    </processServerHello>
                                                </processHandshakeMessage>
                                            </processHandshakeRecord>
                                        </readHandshakeMessages>
                                        <info>Sending client-side certificate(s)...</info>
                                        <sendClientCertificates>
                                            <buildCertificatesMessage>
                                                <numCerts>3</numCerts>
                                            </buildCertificatesMessage>
                                        </sendClientCertificates>
                                        <buildClientKeyExchange ms="15">
                                            <buildClientKeyExchangeRsa ms="15">
                                                <modulus_bitlen>2048</modulus_bitlen>
                                                <bigEndian>1</bigEndian>
                                                <padding>PKCS 1.5</padding>
                                            </buildClientKeyExchangeRsa>
                                        </buildClientKeyExchange>
                                        <sendCertificateVerify ms="32">
                                            <info>Sending ClientCertVerify message...</info>
                                            <signatureSize>260</signatureSize>
                                        </sendCertificateVerify>
                                    </clientHandshake2>
                                </clientHandshake>
                                <checkServerCert>
                                    <info>Not verifying server certificate...</info>
                                    <info>Set the RequireSslCertVerify property to enable verification.</info>
                                </checkServerCert>
                                <info>SSL/TLS Channel Established.</info>
                            </connectImplicitSsl>
                        </connect2>
                    </socket2Connect>
                    <socketOptions>
                        <SO_SNDBUF>262144</SO_SNDBUF>
                        <SO_RCVBUF>4194304</SO_RCVBUF>
                        <TCP_NODELAY>0</TCP_NODELAY>
                        <SO_KEEPALIVE>1</SO_KEEPALIVE>
                    </socketOptions>
                    <info>HTTPS secure channel established.</info>
                </openHttpConnection>
                <connectTime>Elapsed time: 93 millisec</connectTime>
                <startLine>POST /sgdtws/documentosTransporte HTTP/1.1</startLine>
                <fullRequestHeader>
                    <requestHeader><![CDATA[SOAPAction: envioDocumentoTransporte Host: servicos.portaldasfinancas.gov.pt:701 Content-Length: 3052]]></requestHeader>
                </fullRequestHeader>
                <computeRequestDataSize>
                    <info>Request body is in a memory buffer..</info>
                </computeRequestDataSize>
                <sendRequestHeader>
                    <sendHeaderElapsedMs>0</sendHeaderElapsedMs>
                </sendRequestHeader>
                <sendRequestBody>
                    <idleTimeoutMs>20000</idleTimeoutMs>
                    <sendBodyElapsedMs>0</sendBodyElapsedMs>
                </sendRequestBody>
                <readResponseHeader ms="32">
                    <responseHeader><![CDATA[HTTP/1.1 500 Internal Server Error Content-Type: text/xml X-Backside-Transport: FAIL FAIL Connection: close Set-Cookie: SERVICOS-48386-SG_SERVICOS_TCP701=HCIOLPAKLNAC; Expires=Tue, 22-Dec-2015 19:54:58 GMT; Path=/ ]]></responseHeader>
                </readResponseHeader>
                <statusCode>500</statusCode>
                <statusText>Internal Server Error</statusText>
                <readResponseBody ms="15">
                    <info>Response has no content-length.</info>
                    <info>Non-chunked response with no Content-Length.</info>
                    <readingUntilServerClosesConnection ms="15">
                        <info>Any errors reported within this context are not actual errors...</info>
                        <numBytesRequested>5</numBytesRequested>
                        <error>Connection closed by peer.</error>
                        <passiveClose ms="15">
                            <info>Passive socket closing complete.</info>
                        </passiveClose>
                        <error>Failed to read beginning of SSL/TLS record.</error>
                        <error>Failed to receive more TLS applicaton data.</error>
                        <readNToOutput>Socket connection closed.</readNToOutput>
                    </readingUntilServerClosesConnection>
                </readResponseBody>
                <checkCloseConnection>
                    <info>Response includes connection:close header (or proxy-connection:close header)</info>
                </checkCloseConnection>
            </fullHttpRequest>
            <originalUrl>https://servicos.portaldasfinancas.gov.pt:701/sgdtws/documentosTransporte</originalUrl>
            <success>1</success>
        </a_synchronousRequest>
        <success>1</success>
    </fullRequest>
    <totalTime>Elapsed time: 140 millisec</totalTime>
    <info>Success.</info>
</SynchronousRequest>
</chilkatlog>

Anyone can explain me what's the diference between them, since there is the same code and the same service behind them.

Tried a DIFF tool but couldn't understand diferences.

How to run compiled program using chilkat

$
0
0

My aim is to make "cd /mydirpath" and run my program which was compiled before: "./a.out" Here is how I'm trying to make it:

const char *cmd1 = "cd /home/machinekit/projects";

char *cmd2 = "./a.out";

success = ssh.SendReqExec(channelNum, cmd1);    if (success != true) {      std::cout << ssh.lastErrorText() << "\r\n";         return;     }

    success = ssh.SendReqExec(channelNum, cmd2);    if (success != true) {      std::cout << ssh.lastErrorText() << "\r\n";         return;     }

The first command didn't return an error though the second one gives:

ChilkatLog: SendReqExec: DllDate: May 25 2017 ChilkatVersion: 9.5.0.68 UnlockPrefix: Anything for 30-day trial Architecture: Little Endian; 64-bit Language: Visual C++ 2017 / x64 VerboseLogging: 0 sendReqExec: command: a.out reqExecCharset: ANSI channel: 100 commandQP: a.out Unexpected message type received in response to exec request. messageType: 96 --sendReqExec Failed. --SendReqExec --ChilkatLog

RSASSA-PSS Certs: Invalid PKCS v1.5 PS separator

$
0
0

Hi, I need to use RSASSA-PSS Certs to create sign-files like p7s and I get error at following:

( link text )

ChilkatLog: CreateP7S: DllDate: Jun 23 2015 ChilkatVersion: 9.5.0.51 UnlockPrefix: XXXXX Username: XXXXX Architecture: Little Endian; 32-bit Language: .NET 4.0 VerboseLogging: 0 inFilename: C:C1706291552231.txt outFilename: C:C1706291552231.p7s createDetachedSignature2: createPkcs7Signature: hashAlgorithm: sha1 detachedSignature: 1 numSigningCerts: 1 issuerSerialNum: 41 numAsnBytesToSign: 35 rsaSigLen: 256 buildCertChain: startCertDN: XXXXXXXXXXXX verifyCertSignature: unsignSslSig: Pkcs1_5_decode: Invalid PKCS v1.5 PS separator

Need help to understand how to use chilkat in purebasic

$
0
0

I have to do a lot of programming to crypt file. Can I have someone who can explain to me (in my poor english) how to use chilkat library. I already buy chilkat.

Viewing all 1061 articles
Browse latest View live