根据国家信息安全漏洞共享平台2022年2月7日最新发布信息,几乎所有的Linux发行版都因为Polkit的pkexec组件存在一个获取系统超级权限(即root用户)的安全漏洞,此漏洞的CVE-ID为CVE-2021-4034。

        下图为国外的一个技术网站发布的普通用户提权到root用户的过程截图,可以发现在普通用户下使用gcc编译一个C程序源码后,然后再执行编译出来的可执行程序,即可轻切换到root超级用户。

CentOS 7.5漏洞补丁升级演示:polkit-0.112-14.el7.x86_64 升级到 polkit-0.112-26.el7_9.1.x86_64

[root@centos7-5 ~]# rpm -qa| grep polkit
polkit-0.112-14.el7.x86_64

[root@centos7-5 ~]# yum install -y polkit-0.112-26.el7_9.1.x86_64.rpm 
Loaded plugins: fastestmirror
Examining polkit-0.112-26.el7_9.1.x86_64.rpm: polkit-0.112-26.el7_9.1.x86_64
Marking polkit-0.112-26.el7_9.1.x86_64.rpm as an update to polkit-0.112-14.el7.x86_64
Resolving Dependencies
--> Running transaction check
---> Package polkit.x86_64 0:0.112-14.el7 will be updated
---> Package polkit.x86_64 0:0.112-26.el7_9.1 will be an update
--> Finished Dependency Resolution

Dependencies Resolved

============================================================================================================================================================================================================================================
 Package                                         Arch                                            Version                                                     Repository                                                                Size
============================================================================================================================================================================================================================================
Updating:
 polkit                                          x86_64                                          0.112-26.el7_9.1                                            /polkit-0.112-26.el7_9.1.x86_64                                          480 k

Transaction Summary
============================================================================================================================================================================================================================================
Upgrade  1 Package

Total size: 480 k
Downloading packages:
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Updating   : polkit-0.112-26.el7_9.1.x86_64                                                                                                                                                                                           1/2 
  Cleanup    : polkit-0.112-14.el7.x86_64                                                                                                                                                                                               2/2 
  Verifying  : polkit-0.112-26.el7_9.1.x86_64                                                                                                                                                                                           1/2 
  Verifying  : polkit-0.112-14.el7.x86_64                                                                                                                                                                                               2/2 

Updated:
  polkit.x86_64 0:0.112-26.el7_9.1                                                                                                                                                                                                          

Complete!

[root@centos7-5 ~]# rpm -qa| grep polkit
polkit-0.112-26.el7_9.1.x86_64

CentOS 7升级包:

http://mirror.centos.org/centos/7/updates/x86_64/Packages/polkit-0.112-26.el7_9.1.x86_64.rpm

CentOS 8升级包:

https://koji.mbox.centos.org/pkgs/packages/polkit/0.115/13.el8_5.1/x86_64/polkit-0.115-13.el8_5.1.x86_64.rpm

参考:

  • https://www.cnvd.org.cn/webinfo/show/7351
  • https://www.bleepingcomputer.com/news/security/linux-system-service-bug-gives-root-on-all-major-distros-exploit-released/
  • https://access.redhat.com/security/security-updates/#/?q=polkit&p=1&sort=portal_publication_date%20desc&rows=10&portal_advisory_type=Security%20Advisory&documentKind=PortalProduct
Logo

更多推荐