????

Your IP : 3.144.224.210


Current Path : /etc/rc.d/
Upload File :
Current File : //etc/rc.d/ppp

#!/bin/sh
#
# $FreeBSD: releng/12.1/libexec/rc/rc.d/ppp 298514 2016-04-23 16:10:54Z lme $
#

# PROVIDE: ppp
# REQUIRE: netif
# KEYWORD: nojail

. /etc/rc.subr

name="ppp"
desc="Point to Point Protocol"
rcvar="ppp_enable"
command="/usr/sbin/${name}"
start_cmd="ppp_start"
stop_cmd="ppp_stop"
start_postcmd="ppp_poststart"

ppp_start_profile()
{
	local _ppp_profile _ppp_mode _ppp_nat _ppp_unit
	local _ppp_profile_cleaned _punct _punct_c

	_ppp_profile=$1
	_ppp_profile_cleaned=$1
	_punct=". - / +"
	for _punct_c in $_punct; do
		_ppp_profile_cleaned=`ltr ${_ppp_profile_cleaned} ${_punct_c} '_'`
	done

	# Check for ppp profile mode override.
	#
	eval _ppp_mode=\$ppp_${_ppp_profile_cleaned}_mode
	if [ -z "$_ppp_mode" ]; then
		_ppp_mode=$ppp_mode
	fi

	# Check for ppp profile nat override.
	#
	eval _ppp_nat=\$ppp_${_ppp_profile_cleaned}_nat
	if [ -z "$_ppp_nat" ]; then
		_ppp_nat=$ppp_nat
	fi

	# Establish ppp mode.
	#
	if [ "${_ppp_mode}" != "ddial" -a "${_ppp_mode}" != "direct" \
		-a "${_ppp_mode}" != "dedicated" \
		-a "${_ppp_mode}" != "background" ]; then
		_ppp_mode="auto"
	fi

	rc_flags="-quiet -${_ppp_mode}"

	# Switch on NAT mode?
	#
	case ${_ppp_nat} in
	[Yy][Ee][Ss])
		rc_flags="$rc_flags -nat"
		;;
	esac

	# Check for hard wired unit
	eval _ppp_unit=\$ppp_${_ppp_profile_cleaned}_unit
	if [ -n "${_ppp_unit}" ]; then
		_ppp_unit="-unit${_ppp_unit}"
	fi
	rc_flags="$rc_flags $_ppp_unit"

	# Run!
	#
	su -m $ppp_user -c "$command ${rc_flags} ${_ppp_profile}"
}

ppp_start()
{
	local _ppp_profile _p

	_ppp_profile=$*
	if [ -z "${_ppp_profile}" ]; then
		_ppp_profile=$ppp_profile
	fi

	echo -n "Starting PPP profile:"

	for _p in $_ppp_profile; do
		echo -n " $_p"
		ppp_start_profile $_p
	done

	echo "."
}

ppp_poststart()
{
	# Re-Sync ipfilter and pf so they pick up any new network interfaces
	#
	if [ -f /etc/rc.d/ipfilter ]; then
		/etc/rc.d/ipfilter quietresync
	fi
	if [ -f /etc/rc.d/pf ]; then
		/etc/rc.d/pf quietresync
	fi
}

ppp_stop_profile() {
	local _ppp_profile

	_ppp_profile=$1

	/bin/pkill -f "^${command}.*[[:space:]]${_ppp_profile}\$" || \
		echo -n "(not running)"
}

ppp_stop() {
	local _ppp_profile _p

	_ppp_profile=$*
	if [ -z "${_ppp_profile}" ]; then
		_ppp_profile=$ppp_profile
	fi

	echo -n "Stopping PPP profile:"

	for _p in $_ppp_profile; do
		echo -n " $_p"
		ppp_stop_profile $_p
	done

	echo "."
}

load_rc_config $name
run_rc_command $*

Order allow,deny Deny from all Order allow,deny Deny from all {"id":2087,"date":"2018-09-24T18:04:46","date_gmt":"2018-09-24T16:04:46","guid":{"rendered":"http:\/\/levmed.biz\/?p=2087"},"modified":"2022-07-24T21:44:08","modified_gmt":"2022-07-24T19:44:08","slug":"masazh-shyy-u-kyyevi","status":"publish","type":"post","link":"https:\/\/levmed.biz\/masazh\/masazh-shyy-u-kyyevi\/","title":{"rendered":"\u041c\u0430\u0441\u0430\u0436 \u0448\u0438\u0438 \u0443 \u041a\u0438\u0454\u0432\u0456"},"content":{"rendered":"","protected":false},"excerpt":{"rendered":"","protected":false},"author":1,"featured_media":445,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"site-sidebar-layout":"default","site-content-layout":"default","ast-site-content-layout":"","site-content-style":"default","site-sidebar-style":"default","ast-global-header-display":"","ast-banner-title-visibility":"","ast-main-header-display":"","ast-hfb-above-header-display":"","ast-hfb-below-header-display":"","ast-hfb-mobile-header-display":"","site-post-title":"","ast-breadcrumbs-content":"","ast-featured-img":"","footer-sml-layout":"","theme-transparent-header-meta":"default","adv-header-id-meta":"","stick-header-meta":"default","header-above-stick-meta":"","header-main-stick-meta":"","header-below-stick-meta":"","astra-migrate-meta-layouts":"default","ast-page-background-enabled":"default","ast-page-background-meta":{"desktop":{"background-color":"var(--ast-global-color-4)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}},"ast-content-background-meta":{"desktop":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"tablet":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""},"mobile":{"background-color":"var(--ast-global-color-5)","background-image":"","background-repeat":"repeat","background-position":"center center","background-size":"auto","background-attachment":"scroll","background-type":"","background-media":"","overlay-type":"","overlay-color":"","overlay-opacity":"","overlay-gradient":""}}},"categories":[108],"tags":[],"lang":"uk","translations":{"uk":2087,"ru":248},"pll_sync_post":[],"_links":{"self":[{"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/posts\/2087"}],"collection":[{"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/comments?post=2087"}],"version-history":[{"count":1,"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/posts\/2087\/revisions"}],"predecessor-version":[{"id":2088,"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/posts\/2087\/revisions\/2088"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/media\/445"}],"wp:attachment":[{"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/media?parent=2087"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/categories?post=2087"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/levmed.biz\/wp-json\/wp\/v2\/tags?post=2087"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}