A tool for checking for lingering free namespaces for private package names referenced in dependency configurationfor Python (pypi) requirements.txt
, JavaScript (npm) package.json
, PHP (composer) composer.json
or MVN (maven) pom.xml
.
On 9th of February 2021, a security researcher Alex Birsan published an articlethat touched different resolve order flaws in dependency management tools present in multiple programming language ecosystems.
Microsoft released a whitepaperdescribing ways to mitigate the impact, while the root cause still remains.
confused
simply reads through a dependency definition file of an application and checks the public package repositoriesfor each dependency entry in that file. It will proceed to report all the package names that are not found in the publicrepositories - a state that implies that a package might be vulnerable to this kind of attack, while this vector has notyet been exploited.
This however doesn't mean that an application isn't already being actively exploited. If you know your software is usingprivate package repositories, you should ensure that the namespaces for your private packages have been claimed by atrusted party (typically yourself or your company).
Some packaging ecosystems like npm have a concept called "scopes" that can be either private or public. In short it meansa namespace that has an upper level - the scope. The scopes are not inherently visible publicly, which means that confused
cannot reliably detect if it has been claimed. If your application uses scoped package names, you should ensure that atrusted party has claimed the scope name in the public repositories.
Download a prebuilt binary from releases page, unpack and run!
or
If you have recent go compiler installed: go get -u github.com/visma-prodsec/confused
(the same command works for updating)
or
git clone https://github.com/visma-prodsec/confused ; cd confused ; go get ; go build
Usage:
./confused [-l LANGUAGENAME] depfilename.ext
Usage of ./confused:
-l string
Package repository system. Possible values: "pip", "npm", "composer", "mvn" (default "npm")
-s string
Comma-separated list of known-secure namespaces. Supports wildcards
-v Verbose output
./confused -l pip requirements.txt
Issues found, the following packages are not available in public package repositories:
[!] internal_package1
./confused -l npm package.json
Issues found, the following packages are not available in public package repositories:
[!] internal_package1
[!] @mycompany/internal_package1
[!] @mycompany/internal_package2
# Example when @mycompany private scope has been registered in npm, using -s
./confused -l npm -s '@mycompany/*' package.json
Issues found, the following packages are not available in public package repositories:
[!] internal_package1
./confused -l mvn pom.xml
Issues found, the following packages are not available in public package repositories:
[!] internal
[!] internal/package1
[!] internal/_package2
I am confused about the recent learnings. 发现自己还是没有找到很好的学习的方法,总是感觉效率比较低,嗯,必须尽快扭转颓势。 Emacs的elisp感觉很奇怪,不想自己之前接触的语言,不过还是很强大啊,多看看,多写写配置,也许就能入门了。 这个清明假期就整天宅在宿舍里了,完全没有想去外面玩,或者是参加其他娱乐项目的冲动,这样也许是一个不错的信号,至少
When two words are confused for one another the results can sometimes be comical, for example when affluent is confused with effluent or desert with dessert. On other occasions mix-ups between commonl
九月份开学季,结束了暑假阶段的跟读,开始静静的听,突然发现,接触到崭新的材料的时候,自己竟然能听懂很多内容。为自己感到高兴地同时,也开始变得迷茫了。 每个月的英语学习都在提高班大的英语计划下,给自己定一个月的小计划,而接下来的十月份,我发现自己没有计划了,因为我找不到自己接下来这个月的目标了。 为什么没有目标呢?是因为到现在,我不知道我到了哪个阶段,突然之间我开始
inner_net = False p_ip = '1.1.1.1' t_ip = '2.2.2.2' def switch_ip(a, b, c): if a: b = c return b return b def read_apps(): # global p_ip p_ip = switch_ip(inner_net,
前言 有一段时间没更新博客了,主要是事情太多。这是上半年的比赛遗留下的问题,决心好好琢磨一番。后续会更新hackgame2019的部分题解和其他平台上的题解。 分析 这是一道ELF64位的虚拟机逆向。首先通过初始化虚拟机函数: void *__fastcall init_vm(VM *vm, const void *input) { vm->reg_0 = 0; vm->reg_1 = 0
1、伪分布式配置完成,配置hosts文件 2、重新运行命令hadoop namenode -format 3、重启hadoop 转载于:https://www.cnblogs.com/dgq-blog/p/10179615.html
Yesterday, I am very confuse after I studied JSP. We must configure the specifically path for very Servlet , because the Servlet Container could execute a Servlet Programme by a xml pat
可能原因1Mac未启动ssh 解决方法1:输入启动命令:【sudo launchctl load -w /System/Library/LaunchDaemons/ssh.plist】。 可能原因2Linux未启动ssh 解决方法2:输入启动命令【sudo /etc/init.d ssh start】 如果找不到ssh ,可能是没有安装openssh-server 解决方法:sudo apt-ge