Why Tor exposes routing node information？Protecting the information of routing nodes seems to reduce the possibility of nodes being attacked.
Thats not true, you can see those ips at your computer if you have enough skills for that.
Could you clarify what do you mean by ‘expose routing node information’? And by Tor, do you mean the program? The browser, website Metrics, or other piece called “Tor”?
You are right, for the client, the information (such as IP address, port) of the routing node in the Tor network cannot be hidden.
I have seen that the National Firewall can easily block all routing nodes in the Tor network. If each routing node is hidden or its IP address is confused, the national firewall will not be able to easily obtain all routing node information (such as IP address) in the Tor network.
AFAIK, the National Firewall is detecting the Tor protocol, so just hiding the IP addresses is not enough. Check out this research from Philip Winter and his presentation (2012):
When a Tor user in China establishes a connection to a bridge or relay, deep packet inspection (DPI) boxes recognise the Tor protocol (1). Shortly after a Tor connection is detected, active scanning is initiated (2). The scanning is done by seemingly random Chinese IP addresses. The scanners connect to the respective bridge and try to establish a Tor connection (3). If it succeeds, the bridge is blocked.