-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathparser_cl.go
More file actions
32 lines (27 loc) · 981 Bytes
/
parser_cl.go
File metadata and controls
32 lines (27 loc) · 981 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
package whoisparser
import (
"regexp"
)
var clParser = &Parser{
errorRegex: &ParseErrorRegex{
NoSuchDomain: regexp.MustCompile(`no entries found`),
RateLimit: nil, //failed to call rate-limit for .cl
MalformedRequest: regexp.MustCompile(`Invalid domain name`),
},
registrarRegex: &RegistrarRegex{
DomainName: regexp.MustCompile(`Domain name: *(.+)`),
RegistrarName: regexp.MustCompile(`Registrar name: *(.+)`),
ReferralURL: regexp.MustCompile(`Registrar URL: *(.+)`),
CreatedDate: regexp.MustCompile(`Creation date: *(.+)`),
ExpirationDate: regexp.MustCompile(`Expiration date: *(.+)`),
NameServers: regexp.MustCompile(`Name server: *(.+)`),
WhoisServer: regexp.MustCompile(`Whois server \(*(.+)\)`),
},
registrantRegex: &RegistrantRegex{
Name: regexp.MustCompile(`Registrant name: *(.+)`),
Organization: regexp.MustCompile(`Registrant organisation: *(.+)`),
},
}
func init() {
RegisterParser(".cl", clParser)
}