<commit_before>class AesEncryptDecrypt
  # SSO_KEY = ENV["SSO_KEY"]
  CIPHER_METHOD = 'AES-256-CBC'

  def self.ssoencrypt(str)
    # binding.pry
    cipher = OpenSSL::Cipher.new(CIPHER_METHOD)
    cipher.encrypt
    cipher.key = ENV[:sso_key]
    data = cipher.update(str) + cipher.final
    return Base64.urlsafe_encode64(data)
  end
  def self.ssodecrypt(str)
    data = Base64.urlsafe_decode64(str)
    cipher = OpenSSL::Cipher.new(CIPHER_METHOD)
    cipher.decrypt
    cipher.key = ENV[:sso_key]
    return cipher.update(data) + cipher.final
  end
end<commit_msg>add SSO_KEY<commit_after>class AesEncryptDecrypt
  # SSO_KEY = ENV["SSO_KEY"]
  CIPHER_METHOD = 'AES-256-CBC'

  def self.ssoencrypt(str)
    # binding.pry
    cipher = OpenSSL::Cipher.new(CIPHER_METHOD)
    cipher.encrypt
    cipher.key = ENV["SSO_KEY"]
    data = cipher.update(str) + cipher.final
    return Base64.urlsafe_encode64(data)
  end
  def self.ssodecrypt(str)
    data = Base64.urlsafe_decode64(str)
    cipher = OpenSSL::Cipher.new(CIPHER_METHOD)
    cipher.decrypt
    cipher.key = ENV["SSO_KEY"]
    return cipher.update(data) + cipher.final
  end
end
{'fraction_non_alphanumeric': 0.11443661971830986, 'fraction_numerical': 0.01936619718309859, 'mean_word_length': 3.7375, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2115564', 'n_tokens_mistral': 477, 'n_tokens_neox': 440, 'n_words': 68}