更改虚拟机KVM中的root密码

时间:2023-01-19 09:27:10

I was curious as DigitalOcean provide us with root password reset option, as I have been working towards virtualization about 3 months and never came across direct way to do so.

我很好奇,因为DigitalOcean为我们提供了root密码重置选项,因为我一直致力于虚拟化大约3个月,并且从未遇到直接的方式。

Like openstack offers such option only for xen, where as if I am not wrong Digital Ocean provides for KVM. Also proxmox and other stacks do not provide this option. So I need to know how these guys managed to do so.

就像openstack只为xen提供这样的选项,就好像我没有错误,Digital Ocean为KVM提供了。 proxmox和其他堆栈也不提供此选项。所以我需要知道这些人是如何设法做到的。

One thing I know is that if I can access the file system then I can edit the shadow file but, In virtual environment Machine is in templete form not in Open File system state.

我知道的一件事是,如果我可以访问文件系统,那么我可以编辑影子文件,但是,在虚拟环境中,机器处于模板形式而不是处于打开文件系统状态。

I was wondering if there is any root backdoor in OS itself provided by DO using which they change password on request ?

我想知道在DO提供的操作系统本身是否有任何root后门使用它们根据请求更改密码?

Thanks

谢谢

1 个解决方案

#1


1  

If you turn off your virtal machine, all you have is the whole "virtual hard drive" file on "real hard drive" in a real machine. It's a common file system that can be parsed and managed from outside with no problem (unless it is encrypted).

如果您关闭了自己的虚拟机,那么您所拥有的就是真实机器中“真实硬盘”上的整个“虚拟硬盘”文件。这是一个通用的文件系统,可以从外部解析和管理,没有问题(除非它是加密的)。

So there's no reason for you to NOT be able to access the filesystem of the virtual machine, including the shadow file.

因此,您没有理由无法访问虚拟机的文件系统,包括影子文件。

#1


1  

If you turn off your virtal machine, all you have is the whole "virtual hard drive" file on "real hard drive" in a real machine. It's a common file system that can be parsed and managed from outside with no problem (unless it is encrypted).

如果您关闭了自己的虚拟机,那么您所拥有的就是真实机器中“真实硬盘”上的整个“虚拟硬盘”文件。这是一个通用的文件系统,可以从外部解析和管理,没有问题(除非它是加密的)。

So there's no reason for you to NOT be able to access the filesystem of the virtual machine, including the shadow file.

因此,您没有理由无法访问虚拟机的文件系统,包括影子文件。