rabid 0.0.3 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (56) hide show
  1. checksums.yaml +4 -4
  2. data/LICENSE.txt +2 -1
  3. data/bin/rabid +6 -14
  4. data/lib/bigipcookie/version.rb +1 -1
  5. data/lib/bigipcookie.rb +33 -30
  6. metadata +21 -181
  7. data/.gitignore +0 -8
  8. data/.rubocop.yml +0 -22
  9. data/.yardopts +0 -4
  10. data/.yardopts-dev +0 -6
  11. data/Gemfile +0 -6
  12. data/Gemfile.lock +0 -56
  13. data/README.md +0 -31
  14. data/Rakefile +0 -10
  15. data/bin/rabid_setup +0 -6
  16. data/docs/.nojekyll +0 -0
  17. data/docs/About.md +0 -13
  18. data/docs/CHANGELOG.md +0 -13
  19. data/docs/README.md +0 -23
  20. data/docs/_coverpage.md +0 -14
  21. data/docs/_media/logo.png +0 -0
  22. data/docs/_navbar.md +0 -2
  23. data/docs/_sidebar.md +0 -15
  24. data/docs/index.html +0 -31
  25. data/docs/pages/demo.md +0 -3
  26. data/docs/pages/documentation.md +0 -34
  27. data/docs/pages/install.md +0 -90
  28. data/docs/pages/publishing.md +0 -39
  29. data/docs/pages/quick-start.md +0 -30
  30. data/docs/pages/usage.md +0 -54
  31. data/docs/vendor/docsify.js +0 -1
  32. data/docs/vendor/plugins/emoji.min.js +0 -1
  33. data/docs/vendor/plugins/search.min.js +0 -1
  34. data/docs/vendor/prismjs/components/prism-ruby.min.js +0 -1
  35. data/docs/vendor/themes/vue.css +0 -1
  36. data/docs/why.md +0 -47
  37. data/docs/yard/BigIPCookie/Decode.html +0 -782
  38. data/docs/yard/BigIPCookie.html +0 -159
  39. data/docs/yard/Version.html +0 -126
  40. data/docs/yard/_index.html +0 -138
  41. data/docs/yard/class_list.html +0 -51
  42. data/docs/yard/css/common.css +0 -1
  43. data/docs/yard/css/full_list.css +0 -58
  44. data/docs/yard/css/style.css +0 -496
  45. data/docs/yard/file.LICENSE.html +0 -70
  46. data/docs/yard/file.README.html +0 -105
  47. data/docs/yard/file_list.html +0 -61
  48. data/docs/yard/frames.html +0 -17
  49. data/docs/yard/index.html +0 -105
  50. data/docs/yard/js/app.js +0 -303
  51. data/docs/yard/js/full_list.js +0 -216
  52. data/docs/yard/js/jquery.js +0 -4
  53. data/docs/yard/method_list.html +0 -99
  54. data/docs/yard/top-level-namespace.html +0 -112
  55. data/package-lock.json +0 -154
  56. data/test/test_bigipcookie.rb +0 -65
@@ -1,65 +0,0 @@
1
- # frozen_string_literal: true
2
-
3
- require 'minitest/autorun'
4
- require 'bigipcookie'
5
-
6
- class BigIPCookieTest < Minitest::Test
7
- # IPv4 pool members, with pool name
8
- def test_bigipcookie_decode_ipv4_pm
9
- bip = BigIPCookie::Decode.new('BIGipServer<pool_name>=1677787402.36895.0000')
10
- bip.auto_decode
11
- # Decoded cookie
12
- assert_equal('10.1.1.100:8080', bip.decoded_cookie)
13
- # Pool name
14
- assert_equal('<pool_name>', bip.pool_name)
15
- # Cookie type
16
- assert_equal('IPv4 pool members', bip.cookie_type)
17
- end
18
-
19
- # IPv4 pool members in non-default route domains, only cookie value
20
- def test_bigipcookie_decode_ipv4_pm_ndrd
21
- bip = BigIPCookie::Decode.new('rd5o00000000000000000000ffffc0000201o80')
22
- bip.auto_decode
23
- # Decoded cookie
24
- assert_equal('192.0.2.1%5:80', bip.decoded_cookie)
25
- # Pool name
26
- assert_equal('unknown', bip.pool_name)
27
- # Cookie type
28
- assert_equal('IPv4 pool members in non-default route domains', bip.cookie_type)
29
- end
30
-
31
- # IPv6 pool members, custom cookie name, long ipv6 format
32
- def test_bigipcookie_decode_ipv6_pm
33
- bip = BigIPCookie::Decode.new('CustomeCookieName=vi20010112000000000000000000000030.20480')
34
- bip.auto_decode(ipv6compression: 0)
35
- # Decoded cookie
36
- assert_equal('[2001:0112:0000:0000:0000:0000:0000:0030]:80', bip.decoded_cookie)
37
- # Pool name
38
- assert_equal('unknown', bip.pool_name)
39
- # Cookie type
40
- assert_equal('IPv6 pool members', bip.cookie_type)
41
- end
42
-
43
- # IPv6 pool members in non-default route domains
44
- def test_bigipcookie_decode_ipv6_pm_ndrd
45
- bip = BigIPCookie::Decode.new('BIGipServer~SuperPool=rd3o20010112000000000000000000000030o80')
46
- bip.auto_decode
47
- # Decoded cookie
48
- assert_equal('[2001:112::30%3]:80', bip.decoded_cookie)
49
- # Pool name
50
- assert_equal('~SuperPool', bip.pool_name)
51
- # Cookie type
52
- assert_equal('IPv6 pool members in non-default route domains', bip.cookie_type)
53
- end
54
-
55
- def test_encrypted
56
- bip = BigIPCookie::Decode.new('BIGipServerhttp-pool=!LHmYFDA0qZyj4NoylBEaDn0/k2wesiGt0ANZhWaAohjULoWFXRc1b/yfibypy1qfBzD51kqvmwzfcy4=')
57
- bip.auto_decode
58
- # Decoded cookie
59
- assert_equal('Unknown:Encrypted', bip.decoded_cookie)
60
- # Pool name
61
- assert_equal('http-pool', bip.pool_name)
62
- # Cookie type
63
- assert_equal('Encrypted', bip.cookie_type)
64
- end
65
- end