rejetto forum
February 12, 2012, 01:05:43 AM *
Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
News: This forum is free, you do NOT need to register to post. But you may.
PROBLEMS? QUESTIONS? CLICK HERE!
Fill the survey!
 
   Home   Help Search Login Register  
Pages: [1] 2
  Print  
Author Topic: [Solved] [Usefull] STunnel log displayed in HFS  (Read 7205 times)
0 Members and 1 Guest are viewing this topic.
SilentPliz
Operator
Insane poster
*****
Offline Offline

France France

Posts: 1023


....... chut ! shh!


View Profile WWW
« on: February 11, 2009, 06:45:53 PM »

       
I managed to displayed the Stunnel log in hfs with:

A file hfs.events:

[connected]
{.add to log|{.load|stunnel.log.}|ClBlue.}


But stunnel.log, can't be destroyed when Stunnel runs, the file grows bigger ...

The macro Delete is impossible ... I am looking if someone has an idea.

This kind of thing also does not work:

Just an example:

{.set|hfslog|{.load|hfslog.txt.}.}
{.set|stunnellog|{.load|stunnel.log.}.}
{.save|hfslog.txt|{.cut|{.length|{.^hfslog.}.}|{sub|{.length|{.^stunnellog.}.}|{.length|hfslog.}.}|{.^stunnellog.}.}.}


* Stunnel log hfs.png (120.36 KB, 1132x877 - viewed 512 times.)

* inflate_Stunnel log hfs.png (123.21 KB, 1132x877 - viewed 353 times.)
« Last Edit: February 13, 2009, 04:24:13 AM by SilentPliz » Logged
rejetto
Administrator
Insane programmer
*
Offline Offline

Italy Italy

Posts: 11759


View Profile
« Reply #1 on: February 11, 2009, 06:48:32 PM »

your purpose is to show only new lines of the file?
Logged
SilentPliz
Operator
Insane poster
*****
Offline Offline

France France

Posts: 1023


....... chut ! shh!


View Profile WWW
« Reply #2 on: February 11, 2009, 06:50:17 PM »

Short answer.... yes  Grin
Logged
rejetto
Administrator
Insane programmer
*
Offline Offline

Italy Italy

Posts: 11759


View Profile
« Reply #3 on: February 11, 2009, 07:14:23 PM »

what about this? (untested)

{.set|s|{.load|stunnel.log.}.}
{.set|past|{.load|stunnel.last.}.}
{.save|stunnel.last|{.length|{.^s.}.}.}
{.cut|-{.^past.}||{.^s.}.}
« Last Edit: February 11, 2009, 07:16:17 PM by rejetto » Logged
rejetto
Administrator
Insane programmer
*
Offline Offline

Italy Italy

Posts: 11759


View Profile
« Reply #4 on: February 11, 2009, 07:15:59 PM »

i will introduce a new way for {.length|{.^s.}.}
because it is common but absurdly slow for very long text.
from next build you'll be able to use {.var length|s.}
Logged
SilentPliz
Operator
Insane poster
*****
Offline Offline

France France

Posts: 1023


....... chut ! shh!


View Profile WWW
« Reply #5 on: February 11, 2009, 07:36:59 PM »

Quote
what about this? (untested)

Helas No, not better.
I enclose the result after 1 connection.


Quote
i will introduce a new way for {.length|{.^s.}.}
because it is common but absurdly slow for very long text.
from next build you'll be able to use {.var length|s.}

Good !  Smiley
« Last Edit: February 10, 2010, 11:48:12 PM by SilentPliz » Logged
rejetto forum
« Reply #5 on: February 11, 2009, 07:36:59 PM »

Do you like this software? Consider even $2
 Logged
rejetto
Administrator
Insane programmer
*
Offline Offline

Italy Italy

Posts: 11759


View Profile
« Reply #6 on: February 11, 2009, 08:59:15 PM »

ok, try this

{.cut|{.load|stunnel.last.}||{.load|stunnel.log.}.}
{.save|stunnel.last|{.filesize|stunnel.log.}.}
Logged
SilentPliz
Operator
Insane poster
*****
Offline Offline

France France

Posts: 1023


....... chut ! shh!


View Profile WWW
« Reply #7 on: February 11, 2009, 10:10:20 PM »

EUREKA !

This works perfectly !:

[connected]
{.add to log|{.cut|{.load|stunnel.last.}||{.load|stunnel.log.}.}
{.save|stunnel.last|{.filesize|stunnel.log.}.}|Clblue.}



GRAZIE MILLE !  Smiley


* This is Archirejetto.png (4.23 KB, 204x243 - viewed 261 times.)
« Last Edit: February 12, 2009, 12:25:03 AM by SilentPliz » Logged
SilentPliz
Operator
Insane poster
*****
Offline Offline

France France

Posts: 1023


....... chut ! shh!


View Profile WWW
« Reply #8 on: February 11, 2009, 11:46:55 PM »

PS:  Wink

For those who would get the same thing. (v2.3 since build #239):

1)

- Paste the following section in a file hfs.events that you will put in the folder of hfs.exe:


Script edited 01-18-2010

[connected]
{.set|#log|{.load|stunnel.log|from={.^#stunnel.last.}.}.}
{.set|#stunnel.last|{.filesize|stunnel.log.}.}
{.if|{.^#log.}|{:
{.add to log|.
Stunnel log :
{.^#log.}|Clblue.}
:}.}

[+start]
{.set|#stunnel.last|{.filesize|stunnel.log.}.}
[/color]

2)

- In file stunnel.conf of the folder of stunnel.exe , specify the path of HFS where the file stunnel.log will be created.
(Debug = 6 gives a correct result)

; Some debugging stuff useful for troubleshooting
debug = 6
output = C:\path\of\hfs folder\stunnel.log


3)

- Enjoy HFS and Stunnel !  Smiley

----------------------------------------------------------------------------
Independently, you can add to the section [https] of stunnel.conf, the internal IP of your PC:

[https]
accept  = 0.0.0.0:443
connect = 127.0.0.1:44300

local =
192.168.1.6 *
TIMEOUTclose = 0

* IP example

Then you add in HFS:

Menu > Limits > Bans

\127.0.0.1;192.168.1.6

Then in Adress2name:

Name       IP Mask
Local        127.0.0.1
Stunnel
  192.168.1.6

This will differentiate in the log, the local connections (http), and the distant connections from Stunnel (https).
« Last Edit: January 18, 2010, 03:26:28 PM by SilentPliz » Logged
Dragon_Hunter
Experienced poster
***
Offline Offline

Sweden Sweden

Posts: 49



View Profile Email
« Reply #9 on: February 12, 2009, 03:07:41 PM »

Hi

Can you help and explane about the stunnel log how to get it to work in the hfs.
Logged
SilentPliz
Operator
Insane poster
*****
Offline Offline

France France

Posts: 1023


....... chut ! shh!


View Profile WWW
« Reply #10 on: February 12, 2009, 03:38:51 PM »

With these links, it will be possible.  Smiley

http://www.rejetto.com/wiki/index.php/HFS:_Secure_your_server
http://www.rejetto.com/forum/index.php?topic=3083.0
http://www.rejetto.com/forum/index.php?topic=5718.0

And read my previous message.
« Last Edit: February 12, 2009, 03:48:25 PM by SilentPliz » Logged
Dragon_Hunter
Experienced poster
***
Offline Offline

Sweden Sweden

Posts: 49



View Profile Email
« Reply #11 on: February 12, 2009, 03:47:15 PM »

Oki thx i take a look at it... Do you have stunnel log on your computer?
Logged
SilentPliz
Operator
Insane poster
*****
Offline Offline

France France

Posts: 1023


....... chut ! shh!


View Profile WWW
« Reply #12 on: February 12, 2009, 03:49:48 PM »

   
Yes ... since yesterday ... it's the subject of this topic.  Wink
« Last Edit: February 12, 2009, 03:51:33 PM by SilentPliz » Logged
Dragon_Hunter
Experienced poster
***
Offline Offline

Sweden Sweden

Posts: 49



View Profile Email
« Reply #13 on: February 12, 2009, 04:06:46 PM »

where should openssl be in the computer?
Logged
SilentPliz
Operator
Insane poster
*****
Offline Offline

France France

Posts: 1023


....... chut ! shh!


View Profile WWW
« Reply #14 on: February 12, 2009, 04:15:39 PM »

At the place where you have installed.  Cheesy

It only serves to generate an SSL certificate.
Logged
Pages: [1] 2
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.16 | SMF © 2011, Simple Machines Valid XHTML 1.0! Valid CSS!


Google visited last this page February 11, 2012, 11:13:40 PM
anything