PDA

View Full Version : standalone 'site msg' pack


mr_F_2
03-04-2004, 09:37 PM
I looked and couldn't find a standalone one of these for ioFTPD.

what it does?
adds a private messaging system to your ftpd. with this script your messages will not be deleted once you've read them, but once you delete them...

example output:

[20:28:28] site msg
[20:28:28] 200-+-----[SiTE MSG]---------------------------------------------+
[20:28:28] 200-| |
[20:28:28] 200-| read your mail: site msg read <number> |
[20:28:28] 200-| delete a message: site msg del <number> |
[20:28:28] 200-| send a message: site msg <username> "<message>" |
[20:28:28] 200-| |
[20:28:28] 200-| Use 'all' instead of a number to list all messages at once |
[20:28:28] 200-+------------------------------------[SiTE MSG]--------------+



example output when you have a new message:

20:26:26] 150 Opening ASCII mode data connection for directory listing.
[20:26:26] 226-.-================================================== =====-.
[20:26:26] 226- [UL: 26378.44MB] [DL: 69.63MB] [Speed: 0.00K/s] [Free: 37.56GB]
[20:26:26] 226- [Section: root] [Credits: 0.00MB] [Ratio: Unlimited]
[20:26:26] 226-'-================================================== =====-'
[20:26:26] You have 1 message(s) in your inbox. Type 'site msg' for more information.


syntax on read all:

[20:30:01] site msg read all
[20:30:01] 200-[ 1] From: testusr on Thu, Mar 04, 2004 at 20:29:54
[20:30:01] 200- "YAY this is a TEST"
[20:30:01] 200 Command successful.


syntax on read single:

[20:30:27] site msg read 1
[20:30:27] 200-From: testusr on Thu, Mar 04, 2004 at 20:29:54
[20:30:27] 200-"YAY this is a TEST"
[20:30:27] 200-NOTE: Use 'site msg del 1' to delete this message
[20:30:27] 200 Command successful.

get it here (http://www.ioftpd.com/scripts/script.php?id=67)

EDIT:

I forgot to add this information in the readme, (it's added there now):


add this line to your ..\text\ftp\TransferComplete file:
%[execute(EXEC ..\scripts\ioMsg\ioMsg.exe)(alert)]

hot_pit
03-04-2004, 10:13 PM
i think ioA has it ... but thnx for it dude ;)

mr_F_2
03-04-2004, 10:36 PM
yeah it does.

hence "standalone" site msg pack :D

thewarden
03-05-2004, 09:08 AM
Originally posted by mr_F
yeah it does.

hence "standalone" site msg pack :D


Thanks - as well I see the "OTHER FTPD" place is still waiting for
it as I was one of the people there talking to you :)

As I am forced to run it for now...

mr_F_2
03-05-2004, 10:45 AM
yeah i'll hopefully port to "other ftpd" this weekend.

io just has the sexiest script interface i've ever seen though, with the %execute parameter usable as cookie. mmmmm :)

thewarden
03-05-2004, 11:53 AM
Originally posted by mr_F
yeah i'll hopefully port to "other ftpd" this weekend.

io just has the sexiest script interface i've ever seen though, with the %execute parameter usable as cookie. mmmmm :)

Yea, I have it ready to go here myself, just waiting for the right
moment to do the entire xfer over to the 2 sites here...just playing
with the shared area now.

Been meaning to do since the BW control was added to IO, so
it's been awhile :)

_rage_ thegod
03-05-2004, 12:15 PM
<moderated by neoxed: off topic, this thread is about the release of a new script...>

tuff
04-05-2004, 06:42 AM
site msg ioFTPD "YAY This is a test"

produces this crash/error for me using 5.8.5r

AppName: iomsg.exe AppVer: 0.0.0.0 ModName: ntdll.dll
ModVer: 5.1.2600.1217 Offset: 0000b2ab

this crash only occurs when actually trying to add a msg,
the other commands seem to work. although i cant test
them as i cant send a msg ;)

anyhow, i was wanted to add ioMSG support to my ioREQUEST

lemme know if im missing something stupid :)

mr_F_2
04-05-2004, 10:15 AM
Must have set up call in ioFTPD.ini wrong::

[code]
[R] site msg tasteycheese "DOG MAT!!"
[R] 200-Message not sent, user 'tasteycheese' does not exist
[R] 200 Command successful.
[R] site msg testusr "DOG MAT!!"
[R] 200-Message successfully sent to 'testusr'
[R] 200 Command successful.
[/quote]

i attached a "new" version of ioMsg, it's not really new in the sense that I don't remember what I changed, but I do know i played with the code for some time.

mainly what's new are:
-trail message with single parameter "!" will make the message urgent, allowing
retr = EXEC ..\scripts\ioMsg\ioMsg.exe urgent
to block anyone from RETR if they have an urgent message (they can retr after they've dele the urgent message)
-messages are now stored in a /messages dir instead of application root dir
-probably some small changes.

urgent message sample:
site msg testuser "go die!!!" !

i'll update my script profile sometime soon, for now just grab it here (http://nrscripts.staghosting.com/ioMsg.zip)
no docu is included with this little update

tuff
04-05-2004, 10:55 AM
same problem, even with the `new` version

site msg hehe
200 Command successful.
site msg a "hi"
550 Command failed.
site msg ioFTPD io
550 Command failed.
site msg darkone "pfft this doesnt work"
550 Command failed.

each time it crashes with the same offset as before

[FTP_Custom_Commands]
msg = EXEC ..\scripts\ioMsg.exe

[FTP_SITE_Permissions]
msg = *

what else am i missing?

Mouton
04-05-2004, 11:34 AM
mr_F: if u generate a .map file (with line numbers) you should be able to find at what line exactly it crashes. map files are pretty useful. codeproject got a good explanation on how to use them for debugging...

_away_
04-05-2004, 02:46 PM
"All" works fine mr_F. But if i test the script with
SITE msg Admin thisisatest
200-Message successfully sent to 'Admin'
200 Command successful.
SITE msg Admin this is a test
200-Message successfully sent to 'Admin'
200 Command successful.

i get

SITE msg read 1
200-From: Admin on Mon, Apr 05, 2004 at 21:42:08
200-"thisisatest"
200-NOTE: Use 'site msg del 1' to delete this message
200 Command successful.
SITE msg del 1
200 Command successful.
SITE msg read 1
200-From: Admin on Mon, Apr 05, 2004 at 21:42:18
200-"this" <-- cropped,no spaces allowed or something wrong? Rest works like a charme

greetz

mr_F_2
04-05-2004, 05:37 PM
mouton: thanks i'll try that
tuff: to me it sounds like you have a script conflict? i don't know how, are you sure you don't have another call for msg?

away:

consinder this:
SITE msg Admin thisisatest
param -1 = site
param 0 = msg
param 1 = Admin
param 2 = thisisatest
param 3 = blank (would be the urgent signifier if used {!})

and now consider this:
SITE msg Admin this is a test
param -1 = site
param 0 = msg
param 1 = Admin
param 2 = this
param 3 = is
param 4 = a
param 5 = test

the way it works is param 2 is the message, so you need to use
site msg Admin "this is a test"
with the quotes

If i had time right now i would change it, but i don't, and the source code is publically available so you are free to change it to accept unlimited parameters, but as it is, the syntax is
site msg <username> "<message>"