According to prosecutors, Zhao Chenchen, 16, a student majoring in IT, joined an online chat room of hackers and started to learn hacking skills, the Shanghai Daily reported.
In April, the teacher asked Zhao to hack several foreign web sites with him. The duo attacked several Japanese shopping websites selling furniture, computers and construction materials, the court heard.
Zhao stole over 6,000 pieces of credit card information from two of those web sites. According to prosecutors, Zhao's master later sold the clients' data and gave 22,000 yuan ($3,500) to Zhao.
The teenager was apprehended after police caught a man who had a large number of fake credit cards with him last September.
The court, however, awarded a lighter sentence to Zhao after he pleaded guilty and his parents returned all the ill-gotten money and paid a fine of 20,000 yuan.
For the latest tech news and reviews, follow Gadgets 360 on X, Facebook, WhatsApp, Threads and Google News. For the latest videos on gadgets and tech, subscribe to our YouTube channel. If you want to know everything about top influencers, follow our in-house Who'sThat360 on Instagram and YouTube.