summaryrefslogtreecommitdiff
path: root/usr.sbin/sysmerge
AgeCommit message (Collapse)Author
2014-03-27restore_sum: remove newly created sum file(s).Antoine Jacoutot
2014-03-26login.conf(5) is not special anymore.Antoine Jacoutot
2014-03-24Rework the way we fetch and verify sets to simplify the process.Antoine Jacoutot
Don't fetch SHA256 twice when we are updating from the same repo. Better output. Simplify extract_set (becomes extract_sets and deal with all sets at once). Make sure we cannot pass -s xetcXX and/or -x etcXX. Bring consistency in condition evaluations. Drop some unused variables. with inputs from rpe@
2014-03-22Fix trap: do not remove the entire WRKDIR -- we may have our backed up filesAntoine Jacoutot
in there.
2014-03-22Also remove TEMPROOT in error_rm_wrkdir.Antoine Jacoutot
2014-03-22Make sure to add missing users/groups _before_ running theAntoine Jacoutot
distribution-etc-root-var target; otherwise mtree(8) can fail. issue reported and debugged by deraadt@ ok sthen@
2014-03-21Use ftp -D.Antoine Jacoutot
2014-03-21Fix small regression when not using a full path to sets.Antoine Jacoutot
2014-03-20Cope with recent signify(1) changes and simplify getting/checking the sets.Antoine Jacoutot
ok sthen@ rpe@
2014-03-18Drop the check for badly formed *etc sets when we check signatures; it savesAntoine Jacoutot
us time and if the sets are signed we can assume they are legit (yes, I am an assumer).
2014-03-06Always print the key signify(1) is using.Antoine Jacoutot
sure deraadt@
2014-03-01start using the new officially named keys. This is being done beforeTheo de Raadt
any snapshots come out which are signed with that key... but just give it a day or two. from ajacoutot
2014-02-08Only create DBDIR if it does not exist.Antoine Jacoutot
2014-02-07When using SM_PATH, fetch the SHA256 file only once since we will not beAntoine Jacoutot
using multiple repos. ok rpe@
2014-02-05Sync getopts with usage.Antoine Jacoutot
2014-02-03Really clean up after a run.Antoine Jacoutot
Factorize the sig file name. Do not through an error when a file got manually removed but is still present in the sum file.
2014-01-28Drop comma (sthen@).Antoine Jacoutot
2014-01-28Drop FETCH_CMD and always use ftp(1).Antoine Jacoutot
New fetch() function that wraps ftp(1) with our needed knobs (courtesy of halex@) input from halex@ rpe@ ok halex@
2014-01-27Only remove COMPFILE if it exists.Antoine Jacoutot
2014-01-27Move "EDIT" to the top.Antoine Jacoutot
2014-01-27Enhance errors output and display exactly what is going on.Antoine Jacoutot
req. by deraadt@ Don't redirect error messages unless in a couple of places where it actually makes sense.
2014-01-27Make it clear SM_PATH will fetch the sets corresponding to the currentlyAntoine Jacoutot
running release.
2014-01-23specifically NOT suppress signify error outputRobert Peichaer
suggested by espie@ OK deraadt@
2014-01-23More output enhancements, put errors and warnings where they belong.Antoine Jacoutot
2014-01-23Verify both the signature and the checksum in check_sig().Antoine Jacoutot
Fix a regression with '-s' and '-x' when not using full path to the sets. Be a little bit more verbose about what we do. ok rpe@
2014-01-22Do not bother comparing/merging empty files. Regression from previousAntoine Jacoutot
spotted by kettenis@
2014-01-22Don't remove the SHA256 file twice.Antoine Jacoutot
2014-01-22Cleanup and simplify:Antoine Jacoutot
- rename restore_bak to restore_sum since this is what it does - better clean up after ourselves so only user relevant files are left in the work directory after a run - better handling of symlinks and make sure they match - tweak output: no need to warn the user when we are finished, it is pretty obvious; output that we are veryfing sigs - simplify signature handling: drop get_sig and get signatures at the same time we get the sets -- this allows to get a specific SHA256.sig file for each set check signature in check_sig() right after getting the corresponding set ok rpe@
2014-01-21Document -S and the new signify(1) use by sysmerge(8).Antoine Jacoutot
input and ok jmc@
2014-01-21Protect variable names.Antoine Jacoutot
2014-01-21Add and enable signature checking per default.Robert Peichaer
Provide new option -S to skip that step. idea and initial work from jturner@ with feedback from deraadt@ ok aja@
2013-09-10Add support for the SM_PATH environment variable. This changes theAntoine Jacoutot
default behavior of sysmerge when no source is specified on the command line: * if SM_PATH is set, then sysmerge will search this path for etcXX.tgz and/or xetcXX.tgz * if SM_PATH is not set (the default), then the behaviour is the same as before and /usr/src is used idea from espie@ man page refactoring jmc@ (who else :-)) "good idea" krw@ ok rpe@ landry@ espie@
2013-07-16use .Mt for email addresses; from Jan Stary <hans at stare dot cz>; ok jmc@Ingo Schwarze
2013-03-22Do not register symlinks in the sum files. This makes no sense and makesAntoine Jacoutot
sysmerge(8) output a warning when the target of the link does not yes exist on the system. ok sthen@
2013-03-02Always compare aliases(5) at the end of the sysmerge(8) run after allAntoine Jacoutot
files have already been merged. This is needed in the case where the syntax of smtpd.conf changed to prevent newaliases(8) from failing. issue reported by todd@ ok sthen@
2013-01-25Rename some functions and bump copyright.Antoine Jacoutot
No functionnal change.
2013-01-04simplify chroot casesRobert Peichaer
ok ajacoutot@
2013-01-03Refactor code for extracting and checksumming of (x)etcXX.tgz setsRobert Peichaer
or preparing from /usr/src into extract_set() and prepare_src(). - extend error handling and quoting of user supplied input - move and rename get_sets() to get_set(), change parameter order and allow arbitrary filenames in url pattern (see r1.62 msg) ok halex@, 'go ahead' ajacoutot@
2012-12-26correction of the SRCDIR checkRobert Peichaer
2012-12-26Combine almost identical code for fetching and checking of theRobert Peichaer
etcXX.tgz/xetcXX.tgz sets into a more generic function get_sets(). Move the SRCDIR check into the getopts while-loop as well. ok ajacoutot@ halex@
2012-12-25replace one grep with awk patterns and simplify another using -qRobert Peichaer
ok ajacoutot@
2012-12-24simplify things by using shell patternsRobert Peichaer
ok ajacoutot@ halex@
2012-12-23simplify setting FETCH_CMD and move it upwards to where the otherRobert Peichaer
global variables are defined ok ajacoutot@
2012-12-19use (()) for arithmetic testsRobert Peichaer
ok @ajacoutot
2012-11-10consistently use [ -n "${var}" ] instead of [ "${var}" ]Robert Peichaer
no functional change discussed and ok ajacoutot
2012-11-10turn single-command if-then-fi blocks into "[ expr ] && command"Robert Peichaer
style lines. no change of functionality. discussed with and ok ajacoutot
2012-11-10enhance error_rm_wrkdir() to print an error message if one is passedRobert Peichaer
as argument to replace some error "message" error_rm_workdir lines by a single error_rm_workdir "message" line. ok ajacoutot
2012-11-08mark some more variables as localRobert Peichaer
ok ajacoutot
2012-08-28Always compare master.passwd(5) and group(5) regardless of their sums:Antoine Jacoutot
this is a sanity check to ensure no system user(s)/group(s) are missing. ok sthen@
2012-08-20Explicitely set local variables as such.Antoine Jacoutot
Remove unused DBFILE. from robert at peichaer dot org