A team of UN technical experts and sanctions investigators issued a report in early 2017 agreeing with South Korean allegations that North Korea was not only obtaining key components and manufacturing equipment via China but also prohibited raw materials and cooperation from Chinese banks and companies to pay suppliers and hide these activities from outside scrutiny. The Chinese government still denies knowledge of these activities but the latest evidence was so detailed and well documented that China did admit it must be acted on.
What made this report possible was an unpublicized equipment failure in the February 2016 launch of a three stage Unha rocket. This was described as part of the North Korean space program to put satellites into orbit. The equipment failure had to do with the explosive charges in the first and second stages (which fall back to earth largely intact). Many of these explosives did not go off. South Korea knew that tests of three stage ballistic missiles (that can be used to reach North America or put a satellite into orbit) provide the most recoverable parts. For years South Korea has been recovering many components of the large rockets because the first two stages fall back to earth in the ocean way offshore in international waters. This incident left a lot more components largely intact and as South Korean investigators sought to identify how (or where) they were manufactured they discovered that many of the previously unidentifiable components (because of the self-destruct charges) were made using more advanced manufacturing technology than what North Korea was supposed to have access to. Further digging revealed that the manufacturing equipment was of European origins but was exported to China, via a contract that clearly stated none of it was to be exported to North Korea. The UN investigators not only confirmed the South Korean allegations but were able to uncover even more details. The Chinese government was forced to admit that certain Chinese firms were defying Chinese sanctions and smuggling the technology and some of the needed software and raw materials to North Korea.
Before 2016 South Korean engineers concluded that the construction of the missile components retrieved appeared to be sloppy and there were some foreign components in the rocket but there was not enough recoverable evidence of anything more. Thus until 2016 the South Koreans concluded that the North Korean components and construction techniques were crude but effective, if not as reliable and efficient as Western or Russian designs.
South Korean missile experts also concluded that physical evidence indicated North Korea had not developed any new ballistic missile technology, or even manufactured many new missile parts since at least 2012. It was in 2012 they South Korea began to recover components of North Korea multi-stage ballistic missiles and examine them. By 2012 South Korea had developed technology and techniques to retrieve a lot of these components and have South Korean and foreign experts closely examine them. Initially South Korean engineers and scientists concluded that most of the components appear to have been made in North Korea. The longest range rockets were based on much older (1960s and 70s) technology and the design of the rocket engine was almost identical to one built in Iran. Many of the imported components of the missile were items that are not covered by sanctions, as they have many other industrial uses. The Iranian connection was long known as was North Korean access to older Russian rocket technology.
North Korea had carried out an impressive deception scheme that was largely undone by the failure of the self-destruct system for missile stages known to fall back into international waters where they could be recovered, even from great depths, if someone devoted enough time, effort, technology and money to the effort. But all such deception plans have potential weaknesses and malfunctioning self-destruct systems and dogged efforts by South Korean and UN investigators was one of them.
Another vulnerability was China getting angry at North Korea for defying demands that they cease their nuclear weapons program (which was also getting illegal foreign tech) and freely exploiting the corruption inside China that tended to leave Chinese companies alone if their illegal dealings were discreet and the firm was bringing new revenue to China. That has changed, at least for Chinese firms that left enough clues behind for foreign investigators to collect and put in front of senior Chinese officials.