If it never should be possible, you can do many things do disable Telnet/SSH (and probably management through HTTP/HTTPS):
- Configure "transport input none" on the lines
- Delete all keys and trustpoints
- Disable the http and http secure server
- configure an access-class using a "deny any" ACL
- remove all vlan interfaces (if available) and shutdown the vlan1-interface, remove the IP-address
To disable Telnet/SSH, the first point only would be enough, the rest is "defense in depth".