Just pointing out to the OP, to be careful with the "at-chat", since the escaping of "?" – which is pretty common in AT requires DIFFERENT handling on V6 vs V7. e.g. "AT+CGDCONT\?" vs "AT+CGDCONT?".
Also, since the OP is wring a "automatic SIM card PIN reset script", any script error could leave his PIN change in a bad state... I read signal data using script all the time & I'll see occasional "random AT stuff" (e.g. unsolicited responses) when parsing for signal data. In our case, we can easily ignore a "bad reading". But if the OP in the middling of changing the PIN code of the SIM card, boy that's whole different problem to handle in a script.
Actually it isn't a big deal. I just need to retrieve the iccid and send it to a server in order to get the final config, if the iccid isn't correct the server will simply send a 404 error.
Obviously the cpe will initially have an initial config with my autoprovision script that run every X minutes and internet access via ether1.
Is better read "AT+CLAC" and search what CCID is supported inside, like the found "AT*ICCID"
Probably yes, but for my needs it's a lot faster to just try the 3/4 commands that can work on my CPEs.