json解析换成rails的

This commit is contained in:
guange 2016-05-04 17:25:24 +08:00
parent eaad006d17
commit df41f7328f
1 changed files with 1 additions and 1 deletions

View File

@ -34,7 +34,7 @@ class SsoController < ApplicationController
pkey = OpenSSL::PKey::RSA.new(File.new(File.join(Rails.root,"config/private.key")))
content = pkey.private_decrypt(crypted_str,OpenSSL::PKey::RSA::PKCS1_PADDING)
# content = pkey.private_decrypt(crypted_str)
JSON.parser(content)
ActiveSupport::JSON.decode(content)
end
def login(id)