I have a problem with chroot sftp an their home folder. I would like to write in user's home but I don't have proper permission for doing that.sshd_configMatch User demo    ChrootDirectory %h    ForceCommand internal-sftp    AllowTcpForwarding no    X11Forwarding noUserdemo:x:1013:1014::/home/ftp/demo2:/bin/falseDirectoryroot@xxx:/# ls -l /home/ftp/drwxr-xr-x  2 root root 4096 Nov  3 13:35 demo2Error messagedebug1: channel 0: new [client-session]debug1: Requesting no-more-sessions@openssh.comdebug1: Entering interactive session.Write failed: Broken pipeI know that I can write into a folder under /home/ftp/demo2 but I need to write in /home/ftp/demo2 not in a inner folder, it's mandatory.I've tried to change demo2 permissions and user/group, but it was not possible to write in it.And.. there are other problem. I have 3 users that have their homes under /home/ftp but, on the other hand, I have some users that have their home in a different path, so I can't use ChrootDirectory /home/ftp/%u, I need to use %hAre there any way to do this?Thanks a lot!
How to write in home user with chrooted sftp
chroot;sftp