• send2mail transfer protocol

    From Ragnarok@VERT/DOCKSUD to All on Tuesday, December 04, 2018 19:35:35
    I'm research to make a idea if possible.

    I want to write a transfer protocol to send the file via email instead of download..(i maybe ear previous but i can find if exist)

    The five step are:

    1- The user select the file for download
    2- Select this protocol from list
    3- Prompt for email address
    4- Generate and send mail with the attach file (or maybe a link to direct dowload)
    5- Return with "file download ok"

    I test with a script in javascript and discover that i can use the raw socket to interact with this session.

    I get the client.socket and write to him socket.send("Give me your email, please"), this is ok.

    i now, i think that i must use socket.receiv() the get the user input

    Then, how to return to synch and advertise that the file "was download" successfully? because i get a "the file was not downloaded" error

    i need to know how to implement the step 3 and 5 basically

    any info or doc i'll be very grearful!

    thanks!
    Saludos!










    Ragnarok
    ---
    Dock sud BBS
    http://bbs.docksud.com.ar
    þ Synchronet þ Dock Sud BBS TLD 24 HS - http://bbs.docksud.com.ar - telnet://bbs.docksud.com.ar
  • From Ragnarok@VERT/DOCKSUD to Ragnarok on Tuesday, December 04, 2018 22:09:22
    I'm research to make a idea if possible.

    I want to write a transfer protocol to send the file via email instead of download..(i maybe ear previous but i can find if exist)

    The five step are:

    1- The user select the file for download
    2- Select this protocol from list
    3- Prompt for email address
    4- Generate and send mail with the attach file (or maybe a link to direct dowload)
    5- Return with "file download ok"

    I test with a script in javascript and discover that i can use the raw socket to interact with this session.

    I get the client.socket and write to him socket.send("Give me your email, please"), this is ok.

    i now, i think that i must use socket.receiv() the get the user input

    Then, how to return to synch and advertise that the file "was download" successfully? because i get a "the file was not downloaded" error

    i need to know how to implement the step 3 and 5 basically

    any info or doc i'll be very grearful!

    thanks!
    Saludos!

    Good. Reading the sexys source code i found that it using a file called protocol.log i will investigate =)

    Ragnarok
    ---
    Dock sud BBS
    http://bbs.docksud.com.ar
    þ Synchronet þ Dock Sud BBS TLD 24 HS - http://bbs.docksud.com.ar - telnet://bbs.docksud.com.ar
  • From Digital Man@VERT to Ragnarok on Tuesday, December 04, 2018 22:22:21
    Re: send2mail transfer protocol
    By: Ragnarok to All on Tue Dec 04 2018 07:35 pm

    I'm research to make a idea if possible.

    I want to write a transfer protocol to send the file via email instead of download..(i maybe ear previous but i can find if exist)

    The five step are:

    1- The user select the file for download
    2- Select this protocol from list
    3- Prompt for email address

    Why not just use the user's configure email address (user.netmail in JS)?

    4- Generate and send mail with the attach file (or maybe a link to direct dowload)
    5- Return with "file download ok"

    I test with a script in javascript and discover that i can use the raw socket to interact with this session.

    You can, but it'd be better if you didn't. Use the various print methods instead.

    I get the client.socket and write to him socket.send("Give me your email, please"), this is ok.

    i now, i think that i must use socket.receiv() the get the user input

    No, use prompt() or console.getstr() or something similar instead.

    Then, how to return to synch and advertise that the file "was download" successfully?

    If it's configured as a DSZLOG protocol driver, you need to write to the file with the correct info (and 0 errors) - else, just returning 0 indicates successful download.

    because i get a "the file was not downloaded" error

    Try returning 0 from your script.

    i need to know how to implement the step 3 and 5 basically

    File attachments in email could be interesting... I can't think of any easy examples, but I'd start with exec/sendmail.js.

    digital man

    Synchronet/BBS Terminology Definition #30:
    FTS = FidoNet Technical Standard
    Norco, CA WX: 52.5øF, 32.0% humidity, 0 mph W wind, 0.00 inches rain/24hrs

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Tony Langdon@VERT to Ragnarok on Wednesday, December 05, 2018 17:56:00
    On 12-04-18 19:35, Ragnarok wrote to All <=-

    3- Prompt for email address

    What would be better and less prone to abuse would be to use the user's email address as stors in their user record. Also means no extra prompting needed.

    4- Generate and send mail with the attach file (or maybe a link to
    direct dowload)
    5- Return with "file download ok"

    Doable.

    I test with a script in javascript and discover that i can use the raw socket to interact with this session.

    I get the client.socket and write to him socket.send("Give me your
    email, please"), this is ok.

    As I said, what about reading the user's email from their record?


    ... My karma just ran over your dogma.
    === MultiMail/Win v0.51
    --- SBBSecho 3.03-Linux
    * Origin: Freeway BBS Bendigo,Australia freeway.apana.org.au (3:633/410)
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Tony Langdon@VERT to Digital Man on Wednesday, December 05, 2018 17:59:00
    On 12-04-18 22:22, Digital Man wrote to Ragnarok <=-

    Why not just use the user's configure email address (user.netmail in
    JS)?

    You read my mind! :)

    File attachments in email could be interesting... I can't think of any easy examples, but I'd start with exec/sendmail.js.

    You'd need to MIME encode the file, for inclusion in the message. Can Synchronet do this or is this something that has to be done externally?


    ... The best audience is intelligent, well-educated and a little drunk.
    === MultiMail/Win v0.51
    --- SBBSecho 3.03-Linux
    * Origin: Freeway BBS Bendigo,Australia freeway.apana.org.au (3:633/410)
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Ragnarok@VERT/DOCKSUD to Tony Langdon on Wednesday, December 05, 2018 09:05:18
    El 5/12/18 a las 04:56, Tony Langdon escribió:
    On 12-04-18 19:35, Ragnarok wrote to All <=-

    3- Prompt for email address

    What would be better and less prone to abuse would be to use the user's email address as stors in their user record. Also means no extra prompting needed.

    4- Generate and send mail with the attach file (or maybe a link to direct dowload)
    5- Return with "file download ok"

    Doable.

    I test with a script in javascript and discover that i can use the raw socket to interact with this session.

    I get the client.socket and write to him socket.send("Give me your email, please"), this is ok.

    As I said, what about reading the user's email from their recor

    Yes of course, it's a option too.

    ---
    þ Synchronet þ Dock Sud BBS TLD 24 HS - http://bbs.docksud.com.ar - telnet://bbs.docksud.com.ar
  • From Ragnarok@VERT/DOCKSUD to Digital Man on Wednesday, December 05, 2018 11:56:27
    El 5/12/18 a las 03:22, Digital Man escribió:
    Re: send2mail transfer protocol
    By: Ragnarok to All on Tue Dec 04 2018 07:35 pm

    I'm research to make a idea if possible.

    I want to write a transfer protocol to send the file via email instead of download..(i maybe ear previous but i can find if exist)

    The five step are:

    1- The user select the file for download
    2- Select this protocol from list
    3- Prompt for email address

    Why not just use the user's configure email address (user.netmail in JS)?

    Done!

    4- Generate and send mail with the attach file (or maybe a link to direct dowload)
    5- Return with "file download ok"

    I test with a script in javascript and discover that i can use the raw socket to interact with this session.

    You can, but it'd be better if you didn't. Use the various print methods instead.

    Ggood. I test with writeln() and partial works (see below)


    I get the client.socket and write to him socket.send("Give me your email, please"), this is ok.

    i now, i think that i must use socket.receiv() the get the user input

    No, use prompt() or console.getstr() or something similar instead.


    I found a issue here:
    At download session, after use console.getstr() or prompt() to get user
    input, any other methods before (like writeln()) to output string show
    nothing. Do not send the content to the screen or for the syslog.

    At upload session (i'm not support uploads, just only for dedbug
    purposes) any method show nothing output to the user.

    Must i set as Native Excecutable to handle i/o? I leave this option as
    NO or Socket I/O enabled?


    Then, how to return to synch and advertise that the file "was download" successfully?

    If it's configured as a DSZLOG protocol driver, you need to write to the file with the correct info (and 0 errors) - else, just returning 0 indicates successful download.

    I test using this method writing the file in the node dir and work.

    because i get a "the file was not downloaded" error

    Try returning 0 from your script

    I try using exit(0) from javascript but sbbs still detect as error
    .

    i need to know how to implement the step 3 and 5 basically

    File attachments in email could be interesting... I can't think of any easy examples, but I'd start with exec/sendmail.js.

    Yeah, as initial test i using external mailer (mutt) but i will like
    avoid external depends.

    I put my (WIP) source code here:

    ftp://bbs.docksud.com.ar/dsmailer.js

    Thanks DM , your help is greatly appreciated

    ---
    þ Synchronet þ Dock Sud BBS TLD 24 HS - http://bbs.docksud.com.ar - telnet://bbs.docksud.com.ar
  • From Ragnarok@VERT/DOCKSUD to Tony Langdon on Wednesday, December 05, 2018 12:02:05
    El 5/12/18 a las 04:59, Tony Langdon escribió:
    On 12-04-18 22:22, Digital Man wrote to Ragnarok <=-

    Why not just use the user's configure email address (user.netmail in JS)?

    You read my mind! :)

    ja! =)


    File attachments in email could be interesting... I can't think of any easy examples, but I'd start with exec/sendmail.js.

    You'd need to MIME encode the file, for inclusion in the message. Can Synchronet do this or is this something that has to be done externally?


    i test using external mail program (mutt) i hope that synchonet will
    supported it asap.

    ---
    þ Synchronet þ Dock Sud BBS TLD 24 HS - http://bbs.docksud.com.ar - telnet://bbs.docksud.com.ar
  • From Digital Man@VERT to Tony Langdon on Wednesday, December 05, 2018 13:21:12
    Re: Re: send2mail transfer protocol
    By: Tony Langdon to Digital Man on Wed Dec 05 2018 05:59 pm

    On 12-04-18 22:22, Digital Man wrote to Ragnarok <=-

    Why not just use the user's configure email address (user.netmail in JS)?

    You read my mind! :)

    :)


    File attachments in email could be interesting... I can't think of any easy examples, but I'd start with exec/sendmail.js.

    You'd need to MIME encode the file, for inclusion in the message. Can Synchronet do this or is this something that has to be done externally?

    The Synchronet mail server will MIME-encode file attachments automatically.

    digital man

    This Is Spinal Tap quote #43:
    I feel my role in the band is ... kind of like lukewarm water.
    Norco, CA WX: 49.5øF, 83.0% humidity, 0 mph WSW wind, 0.13 inches rain/24hrs

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Digital Man@VERT to Ragnarok on Wednesday, December 05, 2018 13:28:52
    Re: Re: send2mail transfer protocol
    By: Ragnarok to Digital Man on Wed Dec 05 2018 11:56 am

    El 5/12/18 a las 03:22, Digital Man escribió:
    Re: send2mail transfer protocol
    By: Ragnarok to All on Tue Dec 04 2018 07:35 pm

    I'm research to make a idea if possible.

    I want to write a transfer protocol to send the file via email instead of download..(i maybe ear previous but i can find if exist)

    The five step are:

    1- The user select the file for download
    2- Select this protocol from list
    3- Prompt for email address

    Why not just use the user's configure email address (user.netmail in JS)?

    Done!

    4- Generate and send mail with the attach file (or maybe a link to direct dowload)
    5- Return with "file download ok"

    I test with a script in javascript and discover that i can use the raw socket to interact with this session.

    You can, but it'd be better if you didn't. Use the various print methods instead.

    Ggood. I test with writeln() and partial works (see below)


    I get the client.socket and write to him socket.send("Give me your email, please"), this is ok.

    i now, i think that i must use socket.receiv() the get the user input

    No, use prompt() or console.getstr() or something similar instead.


    I found a issue here:
    At download session, after use console.getstr() or prompt() to get user input, any other methods before (like writeln()) to output string show nothing. Do not send the content to the screen or for the syslog.

    try using log() to be sure your script is executing the portion you expect.

    It could be that while in binary telnet mode, your terminal is sending CR (instead of CR/LF or CR/Nul) and that's hanging you up.

    At upload session (i'm not support uploads, just only for dedbug
    purposes) any method show nothing output to the user.

    Must i set as Native Excecutable to handle i/o? I leave this option as
    NO or Socket I/O enabled?

    So long as your command-line is "?module", those options (Native, I/O) have no effect.

    Then, how to return to synch and advertise that the file "was download" successfully?

    If it's configured as a DSZLOG protocol driver, you need to write to the file with the correct info (and 0 errors) - else, just returning 0 indicates successful download.

    I test using this method writing the file in the node dir and work.

    because i get a "the file was not downloaded" error

    Try returning 0 from your script

    I try using exit(0) from javascript but sbbs still detect as error

    Maybe you had the protocol driver configured as using DSZLOG (but you weren't writing to the file)?

    digital man

    Synchronet/BBS Terminology Definition #41:
    LF = Line Feed (ASCII 10, Ctrl-J)
    Norco, CA WX: 49.1øF, 84.0% humidity, 0 mph WSW wind, 0.13 inches rain/24hrs

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Tony Langdon@VERT to Ragnarok on Thursday, December 06, 2018 10:50:00
    On 12-05-18 09:05, Ragnarok wrote to Tony Langdon <=-

    As I said, what about reading the user's email from their recor

    Yes of course, it's a option too.

    Simpler and less prone to abuse or error (like fat fingering an email address in a hurry). :)


    ... Come on baby light my fire...
    === MultiMail/Win v0.51
    --- SBBSecho 3.03-Linux
    * Origin: Freeway BBS Bendigo,Australia freeway.apana.org.au (3:633/410)
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Tony Langdon@VERT to Ragnarok on Thursday, December 06, 2018 10:51:00
    On 12-05-18 12:02, Ragnarok wrote to Tony Langdon <=-

    You'd need to MIME encode the file, for inclusion in the message. Can Synchronet do this or is this something that has to be done externally?


    i test using external mail program (mutt) i hope that synchonet will supported it asap.

    Oh, OK. Yeah a Synchronet (JS) based email "transfer protocol" would be nice.


    ... The views expressed above aren't necessarily those of the author.
    === MultiMail/Win v0.51
    --- SBBSecho 3.03-Linux
    * Origin: Freeway BBS Bendigo,Australia freeway.apana.org.au (3:633/410)
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Tony Langdon@VERT to Digital Man on Thursday, December 06, 2018 10:55:00
    On 12-05-18 13:21, Digital Man wrote to Tony Langdon <=-

    The Synchronet mail server will MIME-encode file attachments automatically.

    Even better. :)


    ... An aquarium is just interactive television for cats.
    === MultiMail/Win v0.51
    --- SBBSecho 3.03-Linux
    * Origin: Freeway BBS Bendigo,Australia freeway.apana.org.au (3:633/410)
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Ragnarok@VERT/DOCKSUD to Digital Man on Thursday, December 06, 2018 00:18:05
    Re: Re: send2mail transfer protocol
    By: Digital Man to Ragnarok on Wed Dec 05 2018 13:28:52

    try using log() to be sure your script is executing the portion you expect.

    It could be that while in binary telnet mode, your terminal is sending CR (instead of CR/LF or CR/Nul) and that's hanging you up.

    Yes i use log() en several points and work fine
    example

    log("one");
    writeln("two");
    log("three");

    one an three are send to syslog, but two wont show =|

    It could be that while in binary telnet mode, your terminal is sending CR (instead of CR/LF or CR/Nul) and that's hanging you up.

    how to change it? mus i use telnet_mode() or telnet_cmd() ?

    So long as your command-line is "?module", those options (Native, I/O) have no effect.

    okay my command are configured as ?module

    Maybe you had the protocol driver configured as using DSZLOG (but you weren't writing to the file)?

    if i understand, if was configure as use DSZLOG the return code are omited? and if use DSZLOG are disabled, it check for return code?

    thanks a lot!


    Ragnarok
    ---
    Dock sud BBS
    http://bbs.docksud.com.ar
    þ Synchronet þ Dock Sud BBS TLD 24 HS - http://bbs.docksud.com.ar - telnet://bbs.docksud.com.ar
  • From Digital Man@VERT to Ragnarok on Thursday, December 06, 2018 01:03:32
    Re: Re: send2mail transfer protocol
    By: Ragnarok to Digital Man on Thu Dec 06 2018 12:18 am

    Re: Re: send2mail transfer protocol
    By: Digital Man to Ragnarok on Wed Dec 05 2018 13:28:52

    try using log() to be sure your script is executing the portion you expect.

    It could be that while in binary telnet mode, your terminal is sending CR (instead of CR/LF or CR/Nul) and that's hanging you up.

    Yes i use log() en several points and work fine
    example

    log("one");
    writeln("two");
    log("three");

    one an three are send to syslog, but two wont show =|

    I can't think of any reason why that would be. You say that only happens *after* something your script does?

    It could be that while in binary telnet mode, your terminal is sending CR (instead of CR/LF or CR/Nul) and that's hanging you up.

    how to change it? mus i use telnet_mode() or telnet_cmd() ?

    It sounds like that may not be the problem anyway.

    So long as your command-line is "?module", those options (Native, I/O) have no effect.

    okay my command are configured as ?module

    Maybe you had the protocol driver configured as using DSZLOG (but you weren't writing to the file)?

    if i understand, if was configure as use DSZLOG the return code are omited?

    It's not ommitted, just ignored.

    and if use DSZLOG are disabled, it check for return code?

    Correct (and 0 means "no error").

    digital man

    Synchronet/BBS Terminology Definition #26:
    FF = Form Feed (ASCII 12, Ctrl-L)
    Norco, CA WX: 49.4øF, 91.0% humidity, 2 mph SW wind, 0.24 inches rain/24hrs

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Ragnarok@VERT/DOCKSUD to Tony Langdon on Thursday, December 06, 2018 10:20:59
    El 5/12/18 a las 21:51, Tony Langdon escribió:
    On 12-05-18 12:02, Ragnarok wrote to Tony Langdon <=-

    You'd need to MIME encode the file, for inclusion in the message. Can Synchronet do this or is this something that has to be done externally?


    i test using external mail program (mutt) i hope that synchonet will supported it asap.

    Oh, OK. Yeah a Synchronet (JS) based email "transfer protocol" would be nice.


    i'm working on it:

    ftp://bbs.docksud.com.ar/dsmailer.js

    ---
    þ Synchronet þ Dock Sud BBS TLD 24 HS - http://bbs.docksud.com.ar - telnet://bbs.docksud.com.ar
  • From Tony Langdon@VERT to Ragnarok on Friday, December 07, 2018 09:17:00
    On 12-06-18 10:20, Ragnarok wrote to Tony Langdon <=-

    Oh, OK. Yeah a Synchronet (JS) based email "transfer protocol" would be
    nice.


    i'm working on it:

    ftp://bbs.docksud.com.ar/dsmailer.js

    Cool, when it's ready, I'll be installing it on my BBS.


    ... Even though it's a cliche, it's true.
    === MultiMail/Win v0.51
    --- SBBSecho 3.03-Linux
    * Origin: Freeway BBS Bendigo,Australia freeway.apana.org.au (3:633/410)
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From mark lewis@VERT to Digital Man on Sunday, December 09, 2018 13:09:42
    On 2018 Dec 04 22:22:20, you wrote to Ragnarok:

    The five step are:

    1- The user select the file for download
    2- Select this protocol from list
    3- Prompt for email address

    Why not just use the user's configure email address (user.netmail in JS)?

    what if there isn't one? should it query and store it or just query and use it this one time?

    )\/(ark

    Always Mount a Scratch Monkey
    Do you manage your own servers? If you are not running an IDS/IPS yer doin' it wrong...
    ... It's a sad, sad day when ice tea is sweetened.
    ---
    * Origin: (1:3634/12.73)
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Tony Langdon@VERT to mark lewis on Monday, December 10, 2018 09:56:00
    On 12-09-18 13:09, mark lewis wrote to Digital Man <=-

    what if there isn't one? should it query and store it or just query and use it this one time?

    Or simply inform the user that they need to set their email address before they can use that protocol.


    ... A noisy exhaust to some almost amounts to a mating call.
    === MultiMail/Win v0.51
    --- SBBSecho 3.03-Linux
    * Origin: Freeway BBS Bendigo,Australia freeway.apana.org.au (3:633/410)
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net