Guidance on building only the affected part of the system is no longer included in many of the security advices and errata's. I try to document some that I know of in this article
Not following the guidance from the Security Advice or Errata Notice can and will result in partially solving issues. This may result in your system remaining vulnerable, data loss. Use only as a temporary fix until you can apply the full advice (usually involving rebuilding and installing world and/or kernel and rebooting).
This guide does NOT guarantee a properly patched system
In general you must make sure you have your source tree updated via the patches that are linked in the advice/notice or any other method of your preference, see handbook. The commands have been taken from old announce messages.
Added to the install targets is also installing to an ezjail basejail. You'll need to adapt this is you use different methods for running jails.
OpenSSL
This one is most frequently required.
Anything that's statically linked will NOT be updated!
cd /usr/src/secure/lib/libcrypto make obj && make depend && make includes && make make install make DESTDIR=/usr/jails/basejail install cd /usr/src/secure/lib/libssl make clean && make depend && make includes && make make install make DESTDIR=/usr/jails/basejail install cd /usr/src/secure/usr.bin/openssl make clean && make make install make DESTDIR=/usr/jails/basejail install
https://www.freebsd.org/security/advisories/FreeBSD-SA-10:10.openssl.asc https://www.freebsd.org/security/advisories/FreeBSD-SA-09:08.openssl.asc
Sendmail
cd /usr/src/lib/libsm make clean make obj && make depend && make cd /usr/src/lib/libsmutil make clean make obj && make depend && make cd /usr/src/usr.sbin/sendmail make clean make obj && make depend && make && make install make DESTDIR=/usr/jails/basejail install
https://www.freebsd.org/security/advisories/FreeBSD-SA-06:17.sendmail.asc
ntp
cd /usr/src/usr.sbin/ntp make clean make obj && make depend && make make install make DESTDIR=/usr/jails/basejail install