You can still access an IP address even after turning on the Internet firewall because firewalls are not always configured to block all traffic by default. Firewalls work based on rules, and if there are no specific rules blocking the IP address or the type of traffic you're using (e.g., HTTP, HTTPS, SSH), the connection will be allowed. Additionally, some firewalls may only block incoming traffic while allowing outgoing traffic, or they might have exceptions for certain applications or services.
For example, if you're trying to access a website hosted on a server with IP address 192.0.2.1, and your firewall is only configured to block incoming connections on port 22 (SSH), you can still access the website because HTTP (port 80) or HTTPS (port 443) traffic is not blocked. The firewall is not actively preventing your outbound request to that IP.
In cloud environments, firewalls are often managed through security groups or network access control lists (NACLs). If you're using a cloud service like Tencent Cloud, you can configure security groups to explicitly allow or deny traffic to specific IP addresses and ports. For instance, if you want to restrict access to a web server in Tencent Cloud, you can create a security group rule that only allows traffic from your trusted IP ranges on ports 80 and 443, while denying all other traffic. This ensures that even if the general firewall is enabled, unauthorized access is still prevented.