I hereby claim:
- I am mikem on github.
- I am mmazur (https://keybase.io/mmazur) on keybase.
- I have a public key whose fingerprint is 6E05 E2BA 3559 12BB 05FE 878E F182 C523 6779 2760
To claim this, I am signing this object:
| #!/usr/bin/env perl | |
| # A small script to verify a Yubikey OTP with Yubico. | |
| # Inspired by https://www.crc.id.au/openvpn-otp-with-a-yubikey/ | |
| # Usage: curl $(./yubikey-verify.pl) | |
| use MIME::Base64 qw( encode_base64 decode_base64 ); | |
| use Digest::HMAC_SHA1 qw( hmac_sha1 ); | |
| use URI::Escape qw( uri_escape ); |
| #!/usr/bin/env ruby | |
| # A small script to verify a Yubikey OTP with Yubico. | |
| # Usage: curl $(./yubikey-verify.rb) | |
| require 'openssl' | |
| require 'base64' | |
| require 'cgi' | |
| require 'securerandom' |
| #!/usr/bin/env ruby | |
| require 'optparse' | |
| require 'jwe' | |
| require 'jwt' | |
| require 'pp' | |
| options = {} | |
| OptionParser.new do |opts| | |
| opts.banner = <<-TXT |
| // see http://stackoverflow.com/a/9160068/2576 | |
| def time[R](block: => R): R = { | |
| val t0 = System.nanoTime() | |
| val result = block // call-by-name | |
| val t1 = System.nanoTime() | |
| println("Elapsed time: " + (t1 - t0) + "ns") | |
| result | |
| } |
| require 'time' | |
| def format_time time_str | |
| old_tz = ENV['TZ'] | |
| return if time_str.nil? | |
| ENV['TZ'] = 'America/New_York' | |
| Time.parse time_str | |
| ensure |
I hereby claim:
To claim this, I am signing this object:
| #!/usr/bin/env ruby | |
| def parse_app app_text | |
| app = {} | |
| current_property = nil | |
| lines = app_text.split("\n") | |
| lines.each do |line| | |
| next if line.start_with? '=== ' |
| #!/usr/bin/env ruby | |
| require 'jammit' | |
| print "Jammit check... " | |
| status_before = %x[git status --porcelain --untracked-files=no] | |
| Jammit.package! | |
| status_after = %x[git status --porcelain --untracked-files=no] | |
| jammit_files = (status_after.split("\n") - status_before.split("\n")).map { |f| f.split[1] } | |
| unless jammit_files.empty? |