Re: [Proftpd-user] mod-exec and bitvise-scp client

banda bassotti <[email protected]>
Newsgroups gmane.network.proftpd.user
Message-ID <CAFfuJJGUfwUNTcA7=4RhZAOaVbKjTgmFf-QkDGO_O-JFA_Yg6A@mail.gmail.com>
sorry, but in the previous email I did not enter the whole configuration,
the definition mod-exec is in the global section:

<Global>
        AllowOverwrite          yes
        IdentLookups            off
        ExtendedLog             /var/log/proftpd/access.log WRITE,READ write
        ExtendedLog             /var/log/proftpd/auth.log AUTH auth
        ExtendedLog             /var/log/proftpd/paranoid.log ALL default

        Umask                002
        TimeoutLogin         120
        TimeoutIdle          600
        TimeoutNoTransfer    900
        TimeoutStalled      3600

       <Limit ALL SITE_CHMOD>
          AllowAll
       </Limit>

       <Directory /home/*_*>
         <Limit  MKD RMD >
           DenyAll
         </Limit>
        </Directory>

<IfModule mod_exec.c>
        ExecEngine on
        ExecLog /var/log/proftpd/mod_exec.log
        ExecOnCommand APPE,STOR /usr/local/bin/eow.sh %f %u
</IfModule>

        MaxLoginAttempts        2
        RequireValidShell       no
        MaxClients              50
        AllowOverwrite          yes
        TransferLog             /var/log/proftpd/upload

</Global>


Il giorno mer 8 ago 2018 alle ore 19:00 TJ Saunders <[email protected]> ha
scritto:

>
>
> On Wed, Aug 8, 2018, at 06:14, banda bassotti wrote:
> > hello,
> >
> > I have a client who uses the sftp bitvise client when he sends files the
> > command specified in ExecOnWrite is not executed.
>
> > my conf is:
> >
> > <IfModule mod_exec.c> ExecEngine on ExecLog
> > /var/log/proftpd/mod_exec.log ExecOnCommand
> > APPE,STOR /usr/local/bin/eow.sh %f %u
> > </IfModule>
> >
> > <VirtualHost 192.168.1.2> SFTPEngine On Port 22 AuthPAMConfig proftpd
> AuthOrder
> > mod_auth_pam.c* mod_auth_unix.c VRootEngine on VRootAlias /dev/ ~/dev
> > DefaultRoot
> > ~ SFTPHostKey /etc/ssh/ssh_host_rsa_key SFTPHostKey
> > /etc/ssh/ssh_host_dsa_key SFTPLog /var/log/proftpd/sftp.log
> > SFTPAuthorizedUserKeys
> > file:/etc/proftpd/keys/%u/authorized_keys_rfc4716 SFTPAuthMethods
> publickey
> > password SFTPOptions IgnoreSFTPUploadPerms TransferLog
> > /var/log/proftpd/xferlog </VirtualHost>
> >
> > any hint? thank you.
>
> I think you may need to move the <IfModule mod_exec.c> section *inside* of
> the mod_sftp <VirtualHost> section.
>
> For configurations to be "globally applied" in ProFTPD, i.e. applied to
> any/all virtual hosts, the configurations need to be within those
> <VirtualHost> sections, *or* within a <Global> section.  Configurations
> outside of <VirtualHost> and <Global> are _not_ automatically applied
> globally.
>
> Thus you might try:
>
>   <Global>
>     <IfModule mod_exec.c>
>       ...
>     </IfModule>
>   <Global>
>
>   <VirtualHost 192.168.1.2>
>     SFTPEngine on
>     ...
>   <VirtualHost>
>
> Hope this helps,
> TJ
>
>
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> ProFTPD Users List   <[email protected]>
> Unsubscribe problems?
> http://www.proftpd.org/list-unsub.html
>

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot

_______________________________________________
ProFTPD Users List   <[email protected]>
Unsubscribe problems?
http://www.proftpd.org/list-unsub.html
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.