Skip site navigation (1)Skip section navigation (2)

FreeBSD Manual Pages

  
 
  

home | help
OpenXPKI::Server(3)   User Contributed Perl Documentation  OpenXPKI::Server(3)

Name
       OpenXPKI::Server	- central server class (the daemon class).

Description
       This is the main	server class of	OpenXPKI. If you want to start an
       OpenXPKI	server then you	must instantiate this class. Please always
       remember	that an	instantiation of this module is	a startup of a
       trustcenter.

Functions
   new
       starts the server. It needs some	parameters to configure	the server but
       if they are correct then	an exec	will be	performed. The parameters are
       the following ones:

       o   DAEMON_USER

       o   DAEMON_GROUP

       o   CONFIG

       o   SILENT (for silent startup with start-stop-daemons during System V
	   init)

       All parameters are required.

   process_request
       is the function which is	called by Net::Server to make the work.	The
       only parameter is the class instance. The communication is handled via
       STDIN and STDOUT.

       The class selects the user interfaces and checks	the pre-initialized
       variables. If all of this is fine then the user interface will be
       initialized and started.

   do_process_request
       does the	actual work of process_request:	determines transport,
       serialization and service from the user input and calls the init() and
       run() methods on	the corresponding service. It also does	some
       housekeeping such as setting permissions, setting the process name,
       etc.

   post_bind_hook
       Is executed (by Net::Server) just after the bind	process	and just
       before any chrooting, change of user, or	change of group	occurs.
       Changes the socket ownership based on the configuration.

   pre_loop_hook
       Drops privileges	to the user configured in the configuration file just
       before starting the main	server loop.

   command
       is normal layer stack where the user interfaces can execute commands.

   Server Configuration
       __redirect_stderr

       Send all	messages to STDERR directly to a file. The file	is specified
       in the XML configuration.

       __init_user_interfaces

       Initialize the supported	user interfaces	(i.e. load classes).

       __get_server_config

       Prepares	the complete server configuration to startup a socket based
       server with Net::Server::Fork. It returns a hashref.

   __set_process_name
       Set the process name that is visible via	e.g. ps.

       Values used inside OpenXPKI (for	easy reference):

       server
	   Initial value of all	childs,	remains	for the	main server process

       watchdog
	   The watchdog	process

       worker: init
	   PreForked child before its first usage

       worker: connecting
	   Worker handling a connection	(if the	worker stays in	this state its
	   likely that the connection attempt failed and the worker is send
	   back	to the pool)

       worker: connected
	   Connected to	a client, waiting for a	session	to be started

       worker: <User> (<Role>)
	   Connected to	a client with active session as	User/Role

       workflow: id <id> (<state>)
	   Worker currently handling a workflow.

       worker: wfc
	   Worker after	finishing a request, back in the pool

perl v5.32.0			  2020-08-29		   OpenXPKI::Server(3)

Name | Description | Functions

Want to link to this manual page? Use this URL:
<https://www.freebsd.org/cgi/man.cgi?query=OpenXPKI::Server&sektion=3&manpath=FreeBSD+12.2-RELEASE+and+Ports>

home | help