<?xml version="1.0"?>
<!DOCTYPE service_bundle SYSTEM "/usr/share/lib/xml/dtd/service_bundle.dtd.1">
<!--
	Copyright 2006 Jens Elkner. All rights reserved.
	$Id$
-->

<service_bundle type='manifest' name='LNFcyrus-sasl:saslauthd'>

<service name='network/saslauthd' type='service' version='1'>
	<single_instance />

	<dependency name='filesystem_minimal' grouping='require_all'
		restart_on='none' type='service'>
		<service_fmri value='svc:/system/filesystem/local' />
	</dependency>

	<dependency name='loopback' grouping='require_any'
		restart_on='error' type='service'>
		<service_fmri value='svc:/network/loopback' />
	</dependency>

	<dependency name='network' grouping='optional_all'
		restart_on='error' type='service'>
		<service_fmri value='svc:/milestone/network' />
	</dependency>

	<instance name='default' enabled='false' >
		<!-- dependency name='config-file' grouping='require_all'
			restart_on='refresh' type='path'>
			<service_fmri value='file://localhost/etc/sasl2/Sendmail.conf'/>
		</dependency -->
		<exec_method type='method' name='start' timeout_seconds='60'
			exec='/lib/svc/method/saslauthd %m %i'>
			<method_context>
				<method_credential user='root' group='root'
					privileges='basic,!proc_session,!proc_info,!file_link_any,net_privaddr,file_dac_read,file_dac_search,sys_resource,proc_chroot' />
			</method_context>
		</exec_method>

		<exec_method type='method' name='stop' timeout_seconds='60'
			exec=':kill' />

		<property_group name='general' type='framework'>
			<!-- manage saslauthd server state -->
			<propval name='action_authorization' type='astring'
				value='solaris.smf.manage.saslauthd' />
			<propval name='value_authorization' type='astring'
				value='solaris.smf.manage.saslauthd' />
		</property_group>

		<!-- Default property settings for saslauthd instance. -->
		<property_group name='config' type='application'>
			<!-- auth mechanism to use -->
			<propval name='authmech' type='astring' value='shadow' />
			<!-- working directory for sockets -->
			<propval name='sockdir' type='astring' value='/var/run' />
			<!-- other options to use -->
			<propval name='options' type='astring' value='' />
		</property_group>
	</instance>

	<stability value='Unstable' />

	<template>
		<common_name>
			<loctext xml:lang='C'>
				SASL authentication server
			</loctext>
		</common_name>
		<documentation>
			<manpage title='saslauthd' section='1M'
			    manpath='@CLIENT_BASEDIR@/share/man' />
			<doc_link name='Project Cyrus'
				uri='http://cyrusimap.web.cmu.edu/' />
		</documentation>
	</template>

</service>

</service_bundle>
