Page MenuHomeFreeBSD

periodic.conf: remove long deprecated security_daily_compat_var()
ClosedPublic

Authored by michaelo on Apr 15 2024, 11:07 AM.
Tags
None
Referenced Files
F167744372: D44796.id.diff
Mon, Aug 24, 5:33 AM
F167742198: D44796.diff
Mon, Aug 24, 5:16 AM
Unknown Object (File)
Sun, Aug 23, 6:54 AM
Unknown Object (File)
Sat, Aug 22, 8:15 PM
Unknown Object (File)
Fri, Aug 21, 6:04 PM
Unknown Object (File)
Thu, Aug 20, 2:14 AM
Unknown Object (File)
Wed, Aug 12, 2:45 PM
Unknown Object (File)
Tue, Aug 11, 3:54 PM
Subscribers

Details

Summary

This function is documented to be gone in after 11. Time to remove this
compat shim.

PR: 275296
Approved by: jrm (mentor), otis (mentor)
MFC after: 1 month

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 57106
Build 53994: arc lint + arc unit

Event Timeline

Adding cy@ as he might also want have a look (as it's src component).

The message in periodic.conf is clear.

	# Compatibility with old daily variable names.
	# They can be removed in stable/11.
	security_daily_compat_var() {
		local var=$1 dailyvar value

		dailyvar=daily_status_security${var#security_status}
		periodvar=${var%enable}period
		eval value=\"\$$dailyvar\"
		[ -z "$value" ] && return
		echo "Warning: Variable \$$dailyvar is deprecated," \
		    "use \$$var instead." >&2
		case "$value" in
		[Yy][Ee][Ss])
			eval $var=YES
			eval $periodvar=daily
			;;
		*)
			eval $var=\"$value\"
			;;
		esac
	}
This revision is now accepted and ready to land.Apr 29 2024, 5:17 PM