> For the complete documentation index, see [llms.txt](https://tenaka.gitbook.io/pentesting/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://tenaka.gitbook.io/pentesting/enumeration/linux/append-to-a-file.md).

# Append to a file

#### #lsattr can the file be append to

lsattr filename.sh

\#'a' means that the file can be append to

\----a-----------e------ filename.sh

echo "cat /root/root.txt >> /home/user/root.txt" | tee -a cronShell.sh

echo "cp file.txt /home/user/file.txt"
