K6h` zdZddlZddlmZmZddlmZmZddlm Z ej e Z GddeZ dS)u  This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program.  If not, see . Copyright © 2019 Cloud Linux Software Inc. This software is also available under ImunifyAV commercial license, see N) RootEndpointsbind)IndependentAgentIDAPIIAIDTokenError)ScopecleZdZejZeddZeddZdS) AuthCloudz auth-cloudc@Ktjd{V}d|iS)Nitems)r get_token)selftokens O/opt/imunify360/venv/lib/python3.11/site-packages/imav/simple_rpc/auth_cloud.pyget_iaid_tokenzAuthCloud.get_iaid_token&s1+577777777zauth-cloud-refresh-tokencKtd tjd{VtddddS#t$r>}td|dd d t |dcYd}~Sd}~wt$r>}td |dd d t |dcYd}~Sd}~wwxYw) Nz*Received RPC request to refresh IAID tokenz1IAID token refresh initiated successfully via RPCsuccesszIAID token refresh initiated)statusmessagez&Failed to refresh IAID token via RPC: T)exc_infoerrorzFailed to refresh token: z4Unexpected error during IAID token refresh via RPC: zUnexpected error: )loggerinforloginrrstr Exception)r es rrefresh_iaid_tokenzAuthCloud.refresh_iaid_token+sm @AAA '-// / / / / / / / KKK L L L#9     LL<<r+s*@@@@@@@@('''''  8 $ $%%%%% %%%%%r