OpenRport Docs
GITHUB
  • OpenRPort Knowledge Base
  • πŸ‘€WHAT IS RPORT
    • Features and benefits of RPort
      • Full feature list
    • Screenshots
  • πŸš€GETTING STARTED
    • Install the RPort Server
      • Install on-premises
      • Install RPort on any virgin cloud VM
      • Enable two factor authentication
        • Use push on mobile for 2FA
        • Use TOTP
    • Connecting Clients
    • Using the remote access
      • Creating tunnels
        • VNC via browser
      • RDP via Browser
      • Open SSH from the browser
      • Scp,sftp through a tunnel
    • Renaming and tagging of clients
    • Organize clients with groups
    • Activate the vault
    • Manage users and permissions
  • πŸ—£οΈNEED HELP?
    • Troubleshoot common problems
      • Restart rport through a tunnel
      • Attributes file path not set
      • Recover lost passwords
      • Client is not connecting
      • Id is already in use
  • πŸ”¦DIGGING DEEPER
    • Using the API
      • Create client credentials
    • RPort Technology Explained
    • Commands and Scripts
      • Executing commands
      • Executing scripts
      • Tacoscript
    • The scheduler
    • File copy and reception
    • Client Configuration Options
      • Supervision of OS updates
      • Script and command execution
    • Advanced client management
      • Install the RPort client manually
      • Uninstall the RPort client
      • Run with SELinux
    • Server Maintenance
      • Monitoring of RPortd
      • Updating RPort
      • Backing up the rport server
      • Renewing certificates
    • FAQ
      • How to use Cloudflare
Powered by GitBook
On this page
  1. DIGGING DEEPER

Commands and Scripts

Learn how to execute command and scripts from the browser without an interactive login.

PreviousRPort Technology ExplainedNextExecuting commands

Last updated 1 year ago

The difference between commands and scripts

The command’s tab is indented to be used to execute a single command. Entering multiple commands is possible, but if you want to implement complex logic, it's better to use a script.

Why not use scripts always? Security is the reason.

Both command and script execution must explicitly be allowed in the rport client configuration. For the commands, you can create a list of allowed commands and a list of disallowed commands. This fine-grained filtering is not possible with scripts.

rport.conf
[remote-commands]
  ## Enable or disable execution of remote commands sent by server.
  ## Defaults: true
  #enabled = true

  ## Allow commands matching the following regular expressions.
  ## The filter is applied to the command sent. Full path must be used.
  ## See {order} parameter for more details how it's applied together with {deny}.
  ## Defaults: ['^/usr/bin/.*','^/usr/local/bin/.*','^C:\\Windows\\System32\\.*']
  #allow = ['^/usr/bin/.*','^/usr/local/bin/.*','^C:\\Windows\\System32\\.*']

See and more .

If you feel it were better not to give full control over the clients to the RPort server, you should script execution of.

rport.conf
[remote-scripts]
  ## Enable or disable execution of remote scripts sent by server.
  ## Defaults: false
  #enabled = false

If you have installed the client via the pairing script, scripts and commands are either enabled without restictions or fully disabled. To use command filtering you need to change the configuration file manually.

The restrictions for command and scripts always apply regardless of whether it's executed for a single client or many clients concurrently.

Single run vs. concurrency

Both – command and scripts – can be executed on a single client or on many clients in parallel. Selecting a client on the left side gives you access to the command or scripts tab for a single client.

Selecting commands or scripts on the top navigation gives you access to the parallel execution.

Command execution on a single client
parallel command execution
πŸ”¦
all configuration options
configuration examples