Fix RDAP quirks uncovered during documentation

There's no reason not to allow a one-character search string when there are no wildcards. And the ROID validity pattern did not allow underscores, which was causing problems with our ROIDs.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=136256605
This commit is contained in:
mountford 2016-10-15 13:33:11 -07:00 committed by Ben McIlwain
parent 861fd60d2c
commit f1ad34b12f
5 changed files with 24 additions and 14 deletions

View file

@ -49,7 +49,7 @@ public class RdapEntityAction extends RdapActionBase {
public static final String PATH = "/rdap/entity/";
private static final Pattern ROID_PATTERN = Pattern.compile("[-.a-zA-Z0-9]+");
private static final Pattern ROID_PATTERN = Pattern.compile("[-_.a-zA-Z0-9]+");
@Inject Clock clock;
@Inject RdapEntityAction() {}