Colin Walters
e466e482b1
Disallow refs starting with a non-letter or digit
...
Change the regexp for validating refs to require at least one letter or digit
before allowing the other special chars in the set `[.-_]`. Names that start
with `.` are traditionally Unix hidden files; let's ignore them under the
assumption they're metadata for some other tool, and we don't want to
potentially conflict with the special `.` and `..` Unix directory entries.
Further, names starting with `-` are problematic for Unix cmdline option
processing; there's no good reason to support that. Finally, disallow `_` just
on general principle - it's simpler to say that ref identifiers must start with
a letter or digit.
We also ignore any existing files (that might be previously created refs) that
start with `.` in the `refs/` directory - there's a Red Hat tool for content
management that injects `.rsync` files, which is why this patch was first
written.
V1: Update to ban all refs starting with a non-letter/digit, and
also add another call to `ostree_validate_rev` in the pull
code.
Closes: https://github.com/ostreedev/ostree/issues/1285
Closes : #1286
Approved by: jlebon
2017-10-18 20:55:43 +00:00
..
2017-03-30 19:19:54 +00:00
2015-03-19 12:43:04 -04:00
2016-03-03 08:50:19 -05:00
2017-09-30 00:05:07 +00:00
2017-09-27 14:44:00 +00:00
2017-09-11 10:53:20 +00:00
2017-03-24 22:16:43 +00:00
2017-10-16 18:22:09 +00:00
2016-04-04 14:19:35 +00:00
2017-03-30 19:19:54 +00:00
2017-09-15 18:51:43 +00:00
2016-07-28 10:10:17 +00:00
2015-05-28 14:21:30 -04:00
2017-10-16 13:08:06 +00:00
2017-09-30 00:05:07 +00:00
2017-09-19 15:16:09 +00:00
2017-09-30 00:05:07 +00:00
2016-04-04 14:19:35 +00:00
2016-06-09 21:10:35 +00:00
2016-02-26 08:19:01 -05:00
2016-02-26 08:19:01 -05:00
2017-10-17 15:20:08 +00:00
2017-09-21 21:38:34 +00:00
2017-09-27 14:44:00 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-08 00:58:08 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2016-06-27 20:20:21 +00:00
2017-09-30 00:05:07 +00:00
2017-04-25 13:52:35 +00:00
2017-09-27 13:13:14 +00:00
2017-09-19 20:41:36 +00:00
2017-09-27 13:13:14 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-09-27 19:04:11 +00:00
2017-07-21 15:45:27 +00:00
2017-05-09 14:05:46 +00:00
2017-09-27 14:44:00 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-08-24 19:57:33 +00:00
2017-06-26 15:56:07 +00:00
2017-09-01 20:54:12 +00:00
2017-09-21 21:38:34 +00:00
2017-09-15 19:28:25 +00:00
2017-06-26 15:56:07 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-08-30 14:30:30 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-09-01 20:54:12 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-09-01 20:54:12 +00:00
2017-06-26 15:56:07 +00:00
2017-09-18 17:20:38 +00:00
2017-07-10 14:18:18 +00:00
2017-08-29 19:08:59 +00:00
2017-10-17 15:20:08 +00:00
2017-09-21 21:38:34 +00:00
2017-07-06 19:08:14 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-10-17 05:06:07 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-08-14 12:04:42 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-03-24 22:16:43 +00:00
2017-09-07 18:49:55 +00:00
2017-10-18 20:55:43 +00:00
2017-06-26 15:56:07 +00:00
2016-03-03 08:50:19 -05:00
2017-09-01 20:54:12 +00:00
2017-09-01 20:54:12 +00:00
2017-05-18 01:14:15 +00:00
2017-09-13 16:03:25 +00:00
2017-09-21 21:38:34 +00:00
2017-10-12 12:53:01 +00:00
2017-09-28 14:08:40 +00:00
2017-10-11 19:26:10 +00:00
2017-09-28 14:08:40 +00:00
2017-09-01 20:54:12 +00:00
2017-09-21 16:51:15 +00:00
2017-09-21 21:38:34 +00:00
2017-09-21 21:38:34 +00:00
2017-07-21 15:45:27 +00:00
2017-08-24 19:57:33 +00:00
2017-10-02 13:39:41 +00:00
2017-09-01 20:54:12 +00:00
2017-06-27 21:45:34 +00:00
2017-10-02 14:44:34 +00:00
2017-09-21 21:38:34 +00:00
2017-09-15 18:51:43 +00:00
2017-09-21 21:38:34 +00:00
2017-09-01 20:54:12 +00:00