Re: [twsocket] HttpCli / Async in thread problems --- Tryng to trace

2011-02-18 Thread Arno Garrels
Arno Garrels wrote:
 Frans van Daalen wrote:
 Update : Seems there are still scenario's where the problem returns
 also sometimes the proxy settings are lost creating a 407 when a
 relocation happens. Seems to happen when executing a GetAsync and a
 relocate is triggered (with follow relocation set)
 
 Thanks for the report. That's probably because SetReady is skipped
 with it's code related to proxy and www-authentication :(
 The HTTP component is a TRUE beast.
 
 Yes, it is! Is there not something like a full-blown http test tool
 which we can run against it and then start rewriting some parts to
 get it back in it's cage ? I found several on the web but have no
 idea if it has ever been used for THttpcli
 
 Can you locate that setready skipping somewhere?
 
 My suggested fix did skip SetReady when FLocationFlag was set, it has
 to be removed. I have a new idea:
 in procedure THttpCli.StateChange(NewState : THttpState);
 try call TriggerRequestDone only when FLocationFlag is not set.
 However that might also lead to other side-effects I'm currently not
 aware of, it worked with and without proxy connection in a brief test.

That works for me as long as the proxy connection keeps alive after a 
301/302. Otherwise it helps to clear the AuthStates in procedure 
THttpCli.LocationSessionClosed.

{$IFDEF UseNTLMAuthentication}
FAuthNTLMState:= ntlmNone;
FProxyAuthNTLMState   := ntlmNone;
{$ENDIF}
{$IFDEF UseDigestAuthentication}
FAuthDigestState  := digestNone;
FProxyAuthDigestState := digestNone;
{$ENDIF}
FAuthBasicState   := BasicNone;
FProxyAuthBasicState  := BasicNone;

--
Arno Garrels


 
 I have been
 maintenace programmer for a long time so used to reading others code
 but this one is hard to read and understand.
 
 Tracing and debugging is a problem when there's not much on the call
 stack as with the THttpCli where many events are triggered by posting
 messages instead of calling event handlers directly.
 
 --
 Arno Garrels
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


[twsocket] Does SslHttpServer support multippel domains?

2011-02-18 Thread Bjørnar Nielsen
Is it possible to host more than one domain on the same 
SslHttpServer-component? Must I have a special cert with several alternative 
names or can I just add more certs to support more domains?

Regards
Bjørnar Nielsen

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] Webapp pulldown list

2011-02-18 Thread Ruud Kerstens
Ok, I understand Francois, it is related to the web-app server, and not 
midware.


Is there a way to activate the link in the pulldown after selecting it?

The pulldown works perfect!

Best regards,

Ruud

Op 18-2-2011 10:23, Francois PIETTE schreef:


Ruud Kerstens wrote in Midware mailing list:

Now I am able to
get the information in a table in the webscreen, however due to
screenlimitations i need to create a pulldown and fill it with the
variable i retrieve.

The variable works fine in a table, but my dropdown/pulldown box does
not get any entry.


A pulldown list is an html select tag. It has option inner tag similar 
like this:

select
option value=thisRuud/option
option value=thatPeter/option
/select


The option part is just like a table as far as ICS page producer is 
concerned. You use the exact same construction as to build an html 
table, except the html elements are no option instead of tr and td. 
Delphi code is the same.


In ICS webpage template, the TABLE_ROWS system is not tied to html 
table. It can be used whenever you have repeating html code to produce.


Your template should looks like:
select
#TABLE_ROWS PULLDOWN
option value=#VALUE#DISPLAY/option
/#TABLE_ROWS
/select

--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be




--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] Webapp pulldown list

2011-02-18 Thread Francois PIETTE

Is there a way to activate the link in the pulldown after selecting it?


Sorry, I don't understand the question.
Maybe you want to make the pulldown par of a html form. Just give a name 
attribute to the select tag and it will be sent as a field when the form is 
submitted. Your Delphi code can then grab the value of the selected option 
as any other form variable.


--
francois.pie...@overbyte.be
The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)
http://www.overbyte.be

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] SVN update notifications

2011-02-18 Thread RTT

On 17-02-2011 18:50, Angus Robertson - Magenta Systems Ltd wrote:

Nothing mine, but a rapid Google search reveals this two
  http://www.lakraven.com/delphi-stuff/ttwitter/

which use the Indy HTTP component, not ICS.
It's a complex component, not trivial to convert to ICS.
I'm already tweeting from the sample application included with this 
TTwitter component (even Unicode messages, something not possible with 
the original), and without any Indy dependency. All replaced by ICS 
equivalents. ;)

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] TTwitter component

2011-02-18 Thread RTT

On 18-02-2011 13:52, Francois PIETTE wrote:

It starts to become interesting :-)
What other dependency is there ?


None

What is the license for that component ? Could it be added to ICS 
distribution or ICS usermade web page ? 


From what I can see, MIT License for all the code from the author of 
the TTwitter component.
It's using also a modified OAuth.pas, to deal with the OAuth stuff, 
under MPL, and a LkJSON unit, to parse json, that is stated at 
sourceforge as being BDS.


You can check for yourself
http://www.lakraven.com/delphi-stuff/ttwitter/

But this project is currently beta, and it's really very incomplete and 
confuse. In the author site, in the comments, the author posted this, 
and I quote


At present TTwitter only provides the means to read and post Tweets… 
more developments are very-much on the way. Currently I’m rewriting 
TTwitter to make use of a new “Social Delphi” component platform I’ve 
been developing… this new version of TTwitter will be releasing quite 
soon at the launch of the purpose-built website, along with components 
for other social networking websites such as Facebook etc. The new 
platform in-fact DOES allow you to bypass the TComponent layers and 
access the raw API’s directly if you wish (though I don’t expect many 
people will want to do that since the component layers make life so much 
easier)


I do recommend you follow me on Twitter (@LaKraven) so you’ll be 
informed as soon as the new versions are available (on the new website)


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] TTwitter component

2011-02-18 Thread Francois PIETTE

OK, thanks for the infos.

--
francois.pie...@overbyte.be
http://www.overbyte.be

- Original Message - 
From: RTT p...@sapo.pt

To: ICS support mailing twsocket@elists.org
Sent: Friday, February 18, 2011 3:47 PM
Subject: Re: [twsocket] TTwitter component


On 18-02-2011 13:52, Francois PIETTE wrote:

It starts to become interesting :-)
What other dependency is there ?


None

What is the license for that component ? Could it be added to ICS 
distribution or ICS usermade web page ?


From what I can see, MIT License for all the code from the author of
the TTwitter component.
It's using also a modified OAuth.pas, to deal with the OAuth stuff,
under MPL, and a LkJSON unit, to parse json, that is stated at
sourceforge as being BDS.

You can check for yourself
http://www.lakraven.com/delphi-stuff/ttwitter/

But this project is currently beta, and it's really very incomplete and
confuse. In the author site, in the comments, the author posted this,
and I quote

At present TTwitter only provides the means to read and post Tweets…
more developments are very-much on the way. Currently I’m rewriting
TTwitter to make use of a new “Social Delphi” component platform I’ve
been developing… this new version of TTwitter will be releasing quite
soon at the launch of the purpose-built website, along with components
for other social networking websites such as Facebook etc. The new
platform in-fact DOES allow you to bypass the TComponent layers and
access the raw API’s directly if you wish (though I don’t expect many
people will want to do that since the component layers make life so much
easier)

I do recommend you follow me on Twitter (@LaKraven) so you’ll be
informed as soon as the new versions are available (on the new website)

--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be 


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli / Async in thread problems --- Tryng to trace

2011-02-18 Thread Arno Garrels
Arno Garrels wrote:
 Arno Garrels wrote:
 Frans van Daalen wrote:
 Update : Seems there are still scenario's where the problem
 returns also sometimes the proxy settings are lost creating a 407
 when a relocation happens. Seems to happen when executing a
 GetAsync and a relocate is triggered (with follow relocation set)
 
 Thanks for the report. That's probably because SetReady is skipped
 with it's code related to proxy and www-authentication :(
 The HTTP component is a TRUE beast.
 
 Yes, it is! Is there not something like a full-blown http test tool
 which we can run against it and then start rewriting some parts to
 get it back in it's cage ? I found several on the web but have no
 idea if it has ever been used for THttpcli
 
 Can you locate that setready skipping somewhere?
 
 My suggested fix did skip SetReady when FLocationFlag was set, it has
 to be removed. I have a new idea:
 in procedure THttpCli.StateChange(NewState : THttpState);
 try call TriggerRequestDone only when FLocationFlag is not set.
 However that might also lead to other side-effects I'm currently not
 aware of, it worked with and without proxy connection in a brief
 test. 
 
 That works for me as long as the proxy connection keeps alive after a
 301/302. Otherwise it helps to clear the AuthStates in procedure
 THttpCli.LocationSessionClosed.
 
 {$IFDEF UseNTLMAuthentication}
FAuthNTLMState:= ntlmNone;
FProxyAuthNTLMState   := ntlmNone;
 {$ENDIF}
 {$IFDEF UseDigestAuthentication}
FAuthDigestState  := digestNone;
FProxyAuthDigestState := digestNone;
 {$ENDIF}
FAuthBasicState   := BasicNone;
FProxyAuthBasicState  := BasicNone;
 

That's not all, I found and fixed some more problems so far.
I just checked in Rev. #670 into SVN, please test the fix
and report back as soon as possible, thanks for your help.

Log:
Proxy authentication with relocations (hopefully) fixed. SSL not tested yet. 
If it still doesn't work it's probably a buggy proxy server i.e. 3Proxy.
Parse NTLM user codes into domain and user name parts and pass them to 
NtlmGetMessage3 in method GetNTLMMessage3.

-- 
Arno Garrels
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli / Async in thread problems --- Tryng to trace

2011-02-18 Thread Frans van Daalen


That's not all, I found and fixed some more problems so far.
I just checked in Rev. #670 into SVN, please test the fix
and report back as soon as possible, thanks for your help.

Log:
Proxy authentication with relocations (hopefully) fixed. SSL not tested 
yet.

If it still doesn't work it's probably a buggy proxy server i.e. 3Proxy.
Parse NTLM user codes into domain and user name parts and pass them to
NtlmGetMessage3 in method GetNTLMMessage3.



Arno, Thanks again for the work! I will make time next week to test together 
with the user that had the problem, so I know for sure it is solved :-)


In the mean while i wrote a workaround by recalling the get and resetting 
the proxy values when a 407 was received. Easy to do in my application as 
that 407 should never happen at that moment.


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli / Async in thread problems --- Tryng to trace

2011-02-18 Thread Arno Garrels
Frans van Daalen wrote:
 That's not all, I found and fixed some more problems so far.
 I just checked in Rev. #670 into SVN, please test the fix
 and report back as soon as possible, thanks for your help.
 
 Log:
 Proxy authentication with relocations (hopefully) fixed. SSL not
 tested yet.
 If it still doesn't work it's probably a buggy proxy server i.e.
 3Proxy. Parse NTLM user codes into domain and user name parts and
 pass them to NtlmGetMessage3 in method GetNTLMMessage3.
 
 
 Arno, Thanks again for the work! I will make time next week to test
 together with the user that had the problem, so I know for sure it is
 solved :-)

What proxy server does your client use?
Since I implemented HTTP tunnel support at the TWSocket level I've
seen a lot of proxy-bugs :( That's also why it's difficult and very 
time-consuming to test the ICS components with proxy-connections.
If we would strictly follow the rfcs 50% of the proxy servers 
around would just plain fail :(

-- 
Arno Garrels

  
  


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


Re: [twsocket] HttpCli / Async in thread problems --- Tryng to trace

2011-02-18 Thread Frans van Daalen


What proxy server does your client use?


One was using webmarshal and the other ISA.  But i'm not behind a proxy and 
also still keep getting the HTTP component  is busy error message when 
using the async get. 


--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be


[twsocket] MAX_OSSL_VER update

2011-02-18 Thread Eugene Kotlyarov
Hi everyone

I think there were only security fixes in OpenSSL 0.9.8 after 0.9.8n, should 
not MAX_OSSL_VER be changed to OSSL_VER_0908R?
It works for me with NO_OSSL_VERSION_CHECK, but it's not very convenient.

Regards,
Eugene Kotlyarov
--
To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be