In response to the order the US-based social networking site revealed IP addresses a string of numbers identifying the computer being used connected to two accounts that were uploading personal information and private pictures, lawyer Yohei Shimizu said.
"The posts included photos that could be considered to be revenge porn," Shimizu told AFP.
"Even though my client could guess who was behind it, she had no proof."
Shimizu said the court order was made in the middle of August over two accounts that were being, falsely, managed in his client's name, and that Facebook had complied with the judge's ruling 10 days later.
Identifying a person who is masquerading as someone else online is not an easy task, Shimizu said. But when armed with the fake account's IP address, his client had been able to approach the Internet provider.
He said it was the first such case in Japan involving the world's largest social network, but added Tokyo District Court had issued a similar order in a separate case involving defamation in August.
Earlier this month a Japanese court ordered Google to delete search results linking the claimant to a crime he did not commit, the latest in a series of rulings around the world on what search engines should tell users.
Britain's government has proposed creating a new criminal offence of posting "revenge porn", punishable by a maximum jail term of two years.
Get your daily dose of tech news, reviews, and insights, in under 80 characters on Gadgets 360 Turbo. Connect with fellow tech lovers on our Forum. Follow us on X, Facebook, WhatsApp, Threads and Google News for instant updates. Catch all the action on our YouTube channel.
Apple Watch Series 12
Starts from ₹56,900
Samsung Galaxy Watch Ultra 2
Starts from ₹59,909
Samsung Galaxy Watch 9 (44mm, LTE)
Starts from ₹41,999
Samsung Galaxy Watch 9 (40mm, LTE)
Starts from ₹38,999
Samsung Galaxy Watch 9 (40mm)
Starts from ₹37,999
Samsung Galaxy Watch 9 (44mm)
Starts from ₹40,999
God of War Laufey Pre-Orders Begin September 29; Digital Deluxe Edition, New Combat Details Revealed
Ai+ Pulse 2 FE Launched in India Alongside Ai+ NovaTab, Nova LapTab 5G Tablets: Price, Specifications