Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- 10.0.0.3 - - [08/Jul/2019:10:26:41 +0000] "GET /hello.html HTTP/1.1" 404 444 "-" "curl/7.52.1"
- 10.0.0.3 - - [08/Jul/2019:10:26:41 +0000] "GET /hello.html HTTP/1.1" 404 444 "-" "curl/7.52.1"
- 10.0.0.3 - - [08/Jul/2019:10:26:41 +0000] "GET /secret.html HTTP/1.1" 200 282 "-" "curl/7.52.1"
- File.open("access.log").each do |line|
- m = /(d{1,3}.d{1,3}.d{1,3}.d{1,3})(.+/)([a-zA-Z0-9]+.html)/.match(line)
- puts m
- end
- 10.0.0.3 - - [08/Jul/2019:10:26:41 +0000] "GET /hello.html
- 1.rb:25:in block in <main>': undefined method []' for nil:NilClass (NoMethodError)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement