bitburner-src/doc/source/netscript/basicfunctions/hasRootAccess.rst

17 lines
405 B
ReStructuredText
Raw Normal View History

hasRootAccess() Netscript Function
==================================
2021-03-12 08:51:56 +01:00
.. js:function:: hasRootAccess(hostname)
:RAM cost: 0.05 GB
2021-03-12 08:51:56 +01:00
:param string hostname: Hostname of the target server.
:returns: ``true`` if you have root access on the target server.
2021-03-12 08:51:56 +01:00
Example:
2021-03-12 08:51:56 +01:00
.. code-block:: javascript
if (hasRootAccess("foodnstuff") == false) {
nuke("foodnstuff");
}