Kali 软件管理测试案例

这篇具有很好参考价值的文章主要介绍了Kali 软件管理测试案例。希望对大家有所帮助。如果存在错误或未考虑完全的地方,请大家不吝赐教,您也可以点击"举报违法"按钮提交疑问。

案例1 :显示目录树 tree

┌──(root㉿kali)-[~]
└─# tree --help
usage: tree [-acdfghilnpqrstuvxACDFJQNSUX] [-L level [-R]] [-H  baseHREF]
        [-T title] [-o filename] [-P pattern] [-I pattern] [--gitignore]
        [--gitfile[=]file] [--matchdirs] [--metafirst] [--ignore-case]
        [--nolinks] [--hintro[=]file] [--houtro[=]file] [--inodes] [--device]
        [--sort[=]<name>] [--dirsfirst] [--filesfirst] [--filelimit #] [--si]
        [--du] [--prune] [--charset[=]X] [--timefmt[=]format] [--fromfile]
        [--fromtabfile] [--fflinks] [--info] [--infofile[=]file] [--noreport]
        [--version] [--help] [--] [directory ...]
  ------- Listing options -------
  -a            All files are listed.
  -d            List directories only.
  -l            Follow symbolic links like directories.
  -f            Print the full path prefix for each file.
  -x            Stay on current filesystem only.
  -L level      Descend only level directories deep.
  -R            Rerun tree when max dir level reached.
  -P pattern    List only those files that match the pattern given.
  -I pattern    Do not list files that match the given pattern.
  --gitignore   Filter by using .gitignore files.
  --gitfile X   Explicitly read gitignore file.
  --ignore-case Ignore case when pattern matching.
  --matchdirs   Include directory names in -P pattern matching.
  --metafirst   Print meta-data at the beginning of each line.
  --prune       Prune empty directories from the output.
  --info        Print information about files found in .info files.
  --infofile X  Explicitly read info file.
  --noreport    Turn off file/directory count at end of tree listing.
  --charset X   Use charset X for terminal/HTML and indentation line output.
  --filelimit # Do not descend dirs with more than # files in them.
  -o filename   Output to file instead of stdout.
  ------- File options -------
  -q            Print non-printable characters as '?'.
  -N            Print non-printable characters as is.
  -Q            Quote filenames with double quotes.
  -p            Print the protections for each file.
  -u            Displays file owner or UID number.
  -g            Displays file group owner or GID number.
  -s            Print the size in bytes of each file.
  -h            Print the size in a more human readable way.
  --si          Like -h, but use in SI units (powers of 1000).
  --du          Compute size of directories by their contents.
  -D            Print the date of last modification or (-c) status change.
  --timefmt <f> Print and format time according to the format <f>.
  -F            Appends '/', '=', '*', '@', '|' or '>' as per ls -F.
  --inodes      Print inode number of each file.
  --device      Print device ID number to which each file belongs.
  ------- Sorting options -------
  -v            Sort files alphanumerically by version.
  -t            Sort files by last modification time.
  -c            Sort files by last status change time.
  -U            Leave files unsorted.
  -r            Reverse the order of the sort.
  --dirsfirst   List directories before files (-U disables).
  --filesfirst  List files before directories (-U disables).
  --sort X      Select sort: name,version,size,mtime,ctime.
  ------- Graphics options -------
  -i            Don't print indentation lines.
  -A            Print ANSI lines graphic indentation lines.
  -S            Print with CP437 (console) graphics indentation lines.
  -n            Turn colorization off always (-C overrides).
  -C            Turn colorization on always.
  ------- XML/HTML/JSON options -------
  -X            Prints out an XML representation of the tree.
  -J            Prints out an JSON representation of the tree.
  -H baseHREF   Prints out HTML format with baseHREF as top directory.
  -T string     Replace the default HTML title and H1 header with string.
  --nolinks     Turn off hyperlinks in HTML output.
  --hintro X    Use file X as the HTML intro.
  --houtro X    Use file X as the HTML outro.
  ------- Input options -------
  --fromfile    Reads paths from files (.=stdin)
  --fromtabfile Reads trees from tab indented files (.=stdin)
  --fflinks     Process link information when using --fromfile.
  ------- Miscellaneous options -------
  --version     Print version and exit.
  --help        Print usage and this help message and exit.
  --            Options processing terminator.

┌──(root㉿kali)-[~]
└─# dpkg -l | grep tree  
ii  cherrytree                                     0.99.48+dfsg-1                       amd64        hierarchical note taking application
ii  libhtml-tree-perl                              5.07-3                               all          Perl module to represent and create HTML syntax trees
ii  libxml-twig-perl                               1:3.52-2                             all          Perl module for processing huge XML documents in tree mode
ii  libxml-xpathengine-perl                        0.14-2                               all          re-usable XPath engine for DOM-like trees
ii  python3-asciitree                              0.3.3-3                              all          Draw tree structures using (ASCII or Unicode) characters
ii  python3-asttokens                              2.2.1-1                              all          annotate Python asbtract syntax trees with code references (Python 3)
ii  tree                                           2.1.1-1                              amd64        displays an indented directory tree, in color

案例2 :使用dpkg安装软件包

┌──(root㉿kali)-[~] ## 卸载
└─# apt-get remove tree   
正在读取软件包列表... 完成
正在分析软件包的依赖关系树... 完成
正在读取状态信息... 完成  

┌──(root㉿kali)-[~]
└─# cd work/doc  
                                                                                     
┌──(root㉿kali)-[~/work/doc]
└─# pwd   
/root/work/doc

## apt-get download -- 下载指定的二进制包到当前目录
┌──(root㉿kali)-[~/work/doc]
└─# apt-get download tree
获取:1 http://mirrors.ustc.edu.cn/kali kali-rolling/main amd64 tree amd64 2.1.1-1 [54.4 kB]
已下载 54.4 kB,耗时 0(200 kB/s)
W: 由于文件'/root/work/doc/tree_2.1.1-1_amd64.deb'无法被用户'_apt'访问,已脱离沙盒并提权为根用户来进行下载。 - pkgAcquire::Run (13: 权限不够)
 
┌──(root㉿kali)-[~/work/doc]
└─# ls -lh                    
总计 56K
-rw-r--r-- 1 root root 54K  6月27日 02:08 tree_2.1.1-1_amd64.deb

##  dpkg -i 安装本地软件包
┌──(root㉿kali)-[~/work/doc]
└─# dpkg -i tree_2.1.1-1_amd64.deb 
正在选中未选择的软件包 tree。
(正在读取数据库 ... 系统当前共安装有 428197 个文件和目录。)
准备解压 tree_2.1.1-1_amd64.deb  ...
正在解压 tree (2.1.1-1) ...
正在设置 tree (2.1.1-1) ...
正在处理用于 kali-menu (2023.4.2) 的触发器 ...
正在处理用于 man-db (2.11.2-3) 的触发器 ...
                                                                                     
┌──(root㉿kali)-[~/work/doc]
└─# which tree
/usr/bin/tree
  

┌──(root㉿kali)-[~/work/doc]
└─# dpkg -l | grep tree 
ii  cherrytree                                     0.99.48+dfsg-1                       amd64        hierarchical note taking application
ii  libhtml-tree-perl                              5.07-3                               all          Perl module to represent and create HTML syntax trees
ii  libxml-twig-perl                               1:3.52-2                             all          Perl module for processing huge XML documents in tree mode
ii  libxml-xpathengine-perl                        0.14-2                               all          re-usable XPath engine for DOM-like trees
ii  python3-asciitree                              0.3.3-3                              all          Draw tree structures using (ASCII or Unicode) characters
ii  python3-asttokens                              2.2.1-1                              all          annotate Python asbtract syntax trees with code references (Python 3)
ii  tree                                           2.1.1-1                              amd64        displays an indented directory tree, in color
    

案例3 :安装一个集成的开发环境(IDE Visual Studio Code)

## 拿到下载链接
┌──(root㉿kali)-[~/work/doc]
└─#  wget https://az764295.vo.msecnd.net/stable/6c3e3dba23e8fadc360aed75ce363ba185c49794/code_1.81.1-1691620686_amd64.deb
--2023-08-24 15:43:14--  https://az764295.vo.msecnd.net/stable/6c3e3dba23e8fadc360aed75ce363ba185c49794/code_1.81.1-1691620686_amd64.deb
正在解析主机 az764295.vo.msecnd.net (az764295.vo.msecnd.net)... 117.18.232.200
正在连接 az764295.vo.msecnd.net (az764295.vo.msecnd.net)|117.18.232.200|:443... 失败:拒绝连接。

## apt-get install -f  这样的方式 会自动解决依赖  dpkg -i 本地安装不会自动解决依赖
┌──(root㉿kali)-[~/work/doc] 
└─# apt-get install -f ./code_1.81.1-1691620686_amd64.deb
正在读取软件包列表... 完成
正在分析软件包的依赖关系树... 完成
正在读取状态信息... 完成                 
注意,选中 'code' 而非 './code_1.81.1-1691620686_amd64.deb'

Kali 软件管理测试案例,个人学习,linux,运维,服务器

案例4 :安装mtr 路由跟踪工具

window – tracert

linux – traceroute

┌──(root㉿kali)-[~/work/doc]
└─# traceroute --help
Usage:
  traceroute [ -46dFITnreAUDV ] [ -f first_ttl ] [ -g gate,... ] [ -i device ] [ -m max_ttl ] [ -N squeries ] [ -p port ] [ -t tos ] [ -l flow_label ] [ -w MAX,HERE,NEAR ] [ -q nqueries ] [ -s src_addr ] [ -z sendwait ] [ --fwmark=num ] host [ packetlen ]
Options:
  -4                          Use IPv4
  -6                          Use IPv6
  -d  --debug                 Enable socket level debugging
  -F  --dont-fragment         Do not fragment packets
  -f first_ttl  --first=first_ttl
                              Start from the first_ttl hop (instead from 1)
  -g gate,...  --gateway=gate,...
                              Route packets through the specified gateway
                              (maximum 8 for IPv4 and 127 for IPv6)
  -I  --icmp                  Use ICMP ECHO for tracerouting
  -T  --tcp                   Use TCP SYN for tracerouting (default port is 80)
  -i device  --interface=device
                              Specify a network interface to operate with
  -m max_ttl  --max-hops=max_ttl
                              Set the max number of hops (max TTL to be
                              reached). Default is 30
  -N squeries  --sim-queries=squeries
                              Set the number of probes to be tried
                              simultaneously (default is 16)
  -n                          Do not resolve IP addresses to their domain names
  -p port  --port=port        Set the destination port to use. It is either
                              initial udp port value for "default" method
                              (incremented by each probe, default is 33434), or
                              initial seq for "icmp" (incremented as well,
                              default from 1), or some constant destination
                              port for other methods (with default of 80 for
                              "tcp", 53 for "udp", etc.)
  -t tos  --tos=tos           Set the TOS (IPv4 type of service) or TC (IPv6
                              traffic class) value for outgoing packets
  -l flow_label  --flowlabel=flow_label
                              Use specified flow_label for IPv6 packets
  -w MAX,HERE,NEAR  --wait=MAX,HERE,NEAR
                              Wait for a probe no more than HERE (default 3)
                              times longer than a response from the same hop,
                              or no more than NEAR (default 10) times than some
                              next hop, or MAX (default 5.0) seconds (float
                              point values allowed too)
  -q nqueries  --queries=nqueries
                              Set the number of probes per each hop. Default is
                              3
  -r                          Bypass the normal routing and send directly to a
                              host on an attached network
  -s src_addr  --source=src_addr
                              Use source src_addr for outgoing packets
  -z sendwait  --sendwait=sendwait
                              Minimal time interval between probes (default 0).
                              If the value is more than 10, then it specifies a
                              number in milliseconds, else it is a number of
                              seconds (float point values allowed too)
  -e  --extensions            Show ICMP extensions (if present), including MPLS
  -A  --as-path-lookups       Perform AS path lookups in routing registries and
                              print results directly after the corresponding
                              addresses
  -M name  --module=name      Use specified module (either builtin or external)
                              for traceroute operations. Most methods have
                              their shortcuts (`-I' means `-M icmp' etc.)
  -O OPTS,...  --options=OPTS,...
                              Use module-specific option OPTS for the
                              traceroute module. Several OPTS allowed,
                              separated by comma. If OPTS is "help", print info
                              about available options
  --sport=num                 Use source port num for outgoing packets. Implies
                              `-N 1'
  --fwmark=num                Set firewall mark for outgoing packets
  -U  --udp                   Use UDP to particular port for tracerouting
                              (instead of increasing the port per each probe),
                              default port is 53
  -UL                         Use UDPLITE for tracerouting (default dest port
                              is 53)
  -D  --dccp                  Use DCCP Request for tracerouting (default port
                              is 33434)
  -P prot  --protocol=prot    Use raw packet of protocol prot for tracerouting
  --mtu                       Discover MTU along the path being traced. Implies
                              `-F -N 1'
  --back                      Guess the number of hops in the backward path and
                              print if it differs
  -V  --version               Print version info and exit
  --help                      Read this help and exit

Arguments:
+     host          The host to traceroute to
      packetlen     The full packet length (default is the length of an IP
                    header plus 40). Can be ignored or increased to a minimal
                    allowed value
                                      
┌──(root㉿kali)-[~/work/doc]
└─# apt-cache search ^mtr                                
mtr - Full screen ncurses and X11 traceroute tool
mtr-tiny - Full screen ncurses traceroute tool
mtree-netbsd - Validates directory tree against specification

                                                                                     
┌──(root㉿kali)-[~/work/doc]
└─# apt-get install mtr                                  
正在读取软件包列表... 完成
正在分析软件包的依赖关系树... 完成
正在读取状态信息... 完成                 
下列软件包是自动安装的并且现在不需要了:

└─# mtr qq.com    
        

Kali 软件管理测试案例,个人学习,linux,运维,服务器

案例5 :升级软件包

python3的升级文章来源地址https://www.toymoban.com/news/detail-676681.html

┌──(root㉿kali)-[~/work/doc]
└─# python3 -V
Python 3.11.4
                                                                                                         
┌──(root㉿kali)-[~/work/doc]
└─# apt-get upgrade python3


案例6 :通过git方式安装软件

┌──(root㉿kali)-[~/work/doc]
└─# git -h                 
用法:git [-v | --version] [-h | --help] [-C <路径>] [-c <名称>=<取值>]
           [--exec-path[=<路径>]] [--html-path] [--man-path] [--info-path]
           [-p | --paginate | -P | --no-pager] [--no-replace-objects] [--bare]
           [--git-dir=<路径>] [--work-tree=<路径>] [--namespace=<名称>]
           [--config-env=<名称>=<环境变量>] <命令> [<参数>]

这些是各种场合常见的 Git 命令:

开始一个工作区(参见:git help tutorial)
   clone     克隆仓库到一个新目录
   init      创建一个空的 Git 仓库或重新初始化一个已存在的仓库

在当前变更上工作(参见:git help everyday)
   add       添加文件内容至索引
   mv        移动或重命名一个文件、目录或符号链接
   restore   恢复工作区文件
   rm        从工作区和索引中删除文件

检查历史和状态(参见:git help revisions)
   bisect    通过二分查找定位引入 bug 的提交
   diff      显示提交之间、提交和工作区之间等的差异
   grep      输出和模式匹配的行
   log       显示提交日志
   show      显示各种类型的对象
   status    显示工作区状态

扩展、标记和调校您的历史记录
   branch    列出、创建或删除分支
   commit    记录变更到仓库
   merge     合并两个或更多开发历史
   rebase    在另一个分支上重新应用提交
   reset     重置当前 HEAD 到指定状态
   switch    切换分支
   tag       创建、列出、删除或校验一个 GPG 签名的标签对象

协同(参见:git help workflows)
   fetch     从另外一个仓库下载对象和引用
   pull      获取并整合另外的仓库或一个本地分支
   push      更新远程引用和相关的对象

命令 'git help -a''git help -g' 显示可用的子命令和一些概念帮助。
查看 'git help <命令>''git help <概念>' 以获取给定子命令或概念的
帮助。
有关系统的概述,查看 'git help git'

开源的 情报搜集工具 recon-ng

┌──(root㉿kali)-[~/work/doc]
└─# git clone https://github.com/lanmaster53/recon-ng.git
正克隆到 'recon-ng'...
remote: Enumerating objects: 9522, done.
remote: Counting objects: 100% (19/19), done.
remote: Compressing objects: 100% (16/16), done.
remote: Total 9522 (delta 3), reused 14 (delta 3), pack-reused 9503
接收对象中: 100% (9522/9522), 3.06 MiB | 775.00 KiB/s, 完成.
处理 delta 中: 100% (4958/4958), 完成.

┌──(root㉿kali)-[~/work/doc]
└─# ls         
code_1.81.1-1691620686_amd64.deb  recon-ng  tree_2.1.1-1_amd64.deb
                                                                                                         
┌──(root㉿kali)-[~/work/doc]
└─# cd regon-ng
cd: 没有那个文件或目录: regon-ng
                                                                                                         
┌──(root㉿kali)-[~/work/doc]
└─# cd recon-ng
                                                                                                         
┌──(root㉿kali)-[~/work/doc/recon-ng]
└─# ls
docker-compose.yml  LICENSE    recon      recon-ng   REQUIREMENTS
Dockerfile          README.md  recon-cli  recon-web  VERSION

                                                                                                         
┌──(root㉿kali)-[~/work/doc/recon-ng]
└─# pip install -r REQUIREMENTS


┌──(root㉿kali)-[~/work/doc/recon-ng]
└─# recon-ng
[*] Version check disabled.

    _/_/_/    _/_/_/_/    _/_/_/    _/_/_/    _/      _/            _/      _/    _/_/_/
   _/    _/  _/        _/        _/      _/  _/_/    _/            _/_/    _/  _/       
  _/_/_/    _/_/_/    _/        _/      _/  _/  _/  _/  _/_/_/_/  _/  _/  _/  _/  _/_/_/
 _/    _/  _/        _/        _/      _/  _/    _/_/            _/    _/_/  _/      _/ 
_/    _/  _/_/_/_/    _/_/_/    _/_/_/    _/      _/            _/      _/    _/_/_/    


                                          /\
                                         / \\ /\
    Sponsored by...               /\  /\/  \\V  \/\
                                 / \\/ // \\\\\ \\ \/\
                                // // BLACK HILLS \/ \\
                               www.blackhillsinfosec.com

                  ____   ____   ____   ____ _____ _  ____   ____  ____
                 |____] | ___/ |____| |       |   | |____  |____ |
                 |      |   \_ |    | |____   |   |  ____| |____ |____
                                   www.practisec.com

                      [recon-ng v5.1.2, Tim Tomes (@lanmaster53)]                       

[*] No modules enabled/installed.

到了这里,关于Kali 软件管理测试案例的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处: 如若内容造成侵权/违法违规/事实不符,请点击违法举报进行投诉反馈,一经查实,立即删除!

领支付宝红包 赞助服务器费用

相关文章

  • 【软件测试学习笔记3】缺陷管理

    执行结果和预期结果不一样,就叫缺陷,俗称bug 少功能:软件未实现需求(规格)说明书中明确要求的功能 功能错误:软件出现了需求(规格)说明书中指明不应该出现的错误 多功能:软件实现的功能超出需求(规格)说明书指明的范围 隐性功能错误:软件实现需求(规格

    2024年01月18日
    浏览(39)
  • Kali 软件管理

    软件存储库存储在 /etc/apt/sources.list 文件中 还可以把一些自定义或单独的应用配置文件放在 /etc/apt/sources.list.d/*.list 中 1. apt-get update 更新软件包的列表 (索引) 解决更新软件包列表失败: apt-get update --fix-missing 2. apt-get upgrade更新软件包(进行一次升级) 3. apt-get dist-upgrade将系统升级

    2024年02月11日
    浏览(27)
  • 《社区人员管理》实战案例设计&个人案例分享

    作者:京东科技 刘宗恺 北京市疫情防控一体化平台是以“京办”为支撑,集病例流调、排查管控、隔离管理、人员转运、监测评估于一体的疫情防控平台,秉承五位一体统筹、现有体系融通、共性能力支撑、高效部门系统、快速局部突破的理念,进行建设。 功能:多系统协

    2023年04月19日
    浏览(33)
  • 【软件测试学习笔记6】Linux常用命令

    command  [-options] [parameter] command 表示的是命令的名称 []表示是可选的,可有可无 [-options]:表示的是命令的选项,可有一个或多个,也可以没有 [parameter]:表示命令的参数,可以有一个或多个,也可以没有 绝对路径:唯一 /开头    cd/etc/abrt ~/开头  cd/usr/bin ~就是/home/用户  

    2024年01月21日
    浏览(41)
  • 【Kali Linux高级渗透测试】深入剖析Kali Linux:高级渗透测试技术与实践

    📕作者简介: 热爱跑步的恒川 ,致力于C/C++、Java、Python等多编程语言,热爱跑步,喜爱音乐的一位博主。 📗本文收录于恒川的日常汇报系列,大家有兴趣的可以看一看 📘相关专栏C语言初阶、C语言进阶系列、恒川等,大家有兴趣的可以看一看 📙Python零基础入门系列,J

    2024年02月10日
    浏览(36)
  • Kali Linux无法定位软件包

    本想更新一下漏扫程序,结果出现了错误 每次遇到问题都要百度,干脆直接记录下来,省的以后麻烦 在kali中出现了无法定位软件包的错误,造成这种错误的方法也可能有很多,比如源错误,网络连接问题,kali系统长时间未更新 还有仓库冲突问题:可以使用urces.list apt_cac

    2024年02月07日
    浏览(40)
  • 【页面案例汇总】微信小程序个人信息管理页面

    这个小程序页面包含了用户头像、昵称、性别、手机号和地址等信息,用户可以自行编辑手机号和地址,并保存到本地缓存中。用户信息的获取通过调用小程序内置的 wx.getUserInfo() 方法实现,手机号和地址的保存和读取使用了小程序提供的 wx.setStorageSync() 和 wx.getStorageSync() 方

    2024年04月13日
    浏览(35)
  • 【软件测试学习笔记7】Linux指令实操练习

    1.在Linux终端中可以通过哪些命令进入到用户目录 2,在Linux终端中,如何查看用户目录下的所有文件(包含隐藏文件)的详细信息。(使用绝对路径和相对路径) 3.通过linux终端在desktop上创建一个名为adir的目录,该目录中包含一个名为dir1的目录 4.在上一题中的dir1目录下创建

    2024年01月19日
    浏览(38)
  • Kali Linux渗透测试技术详解_渗透测试入门

    知识点 1. Kali Linux是做渗透测试用的 2. 安装VMware Workstation虚拟机 3. 安装kali-linux系统 4. 基本用法-重新设置root密码 5 安装debian11系统-默认命令行模式登录 渗透测试是通过模拟恶意黑客的攻击方法,来评估计算机网络系统安全的一种评估方法,这个过程包括对系统的任何弱点、

    2024年02月13日
    浏览(41)
  • 学习Kali渗透测试笔记

    1. 软件测试 功能 性能:高并发环境下工作效率 安全:访问控制、系统数据的完整性、系统数据的机密性、可靠性 2. 安全测试与渗透测试 比较 安全测试 渗透测试 出发点 找出所有安全隐患 证明存在问题 视角 防护者 攻击者 覆盖性 所有可能的攻击界面更加完善 几个测试点

    2023年04月09日
    浏览(40)

觉得文章有用就打赏一下文章作者

支付宝扫一扫打赏

博客赞助

微信扫一扫打赏

请作者喝杯咖啡吧~博客赞助

支付宝扫一扫领取红包,优惠每天领

二维码1

领取红包

二维码2

领红包