Daily Archives: July 10, 2018

Chinese Espionage Group TEMP.Periscope Targets Cambodia Ahead of July 2018 Elections and Reveals Broad Operations Globally

Introduction

FireEye has examined a range of TEMP.Periscope activity revealing extensive interest in Cambodia's politics, with active compromises of multiple Cambodian entities related to the country’s electoral system. This includes compromises of Cambodian government entities charged with overseeing the elections, as well as the targeting of opposition figures. This campaign occurs in the run up to the country’s July 29, 2018, general elections. TEMP.Periscope used the same infrastructure for a range of activity against other more traditional targets, including the defense industrial base in the United States and a chemical company based in Europe. Our previous blog post focused on the group’s targeting of engineering and maritime entities in the United States.

Overall, this activity indicates that the group maintains an extensive intrusion architecture and wide array of malicious tools, and targets a large victim set, which is in line with typical Chinese-based APT efforts. We expect this activity to provide the Chinese government with widespread visibility into Cambodian elections and government operations. Additionally, this group is clearly able to run several large-scale intrusions concurrently across a wide range of victim types.

Our analysis also strengthened our overall attribution of this group. We observed the toolsets we previously attributed to this group, their observed targets are in line with past group efforts and also highly similar to known Chinese APT efforts, and we identified an IP address originating in Hainan, China that was used to remotely access and administer a command and control (C2) server.

TEMP.Periscope Background

Active since at least 2013, TEMP.Periscope has primarily focused on maritime-related targets across multiple verticals, including engineering firms, shipping and transportation, manufacturing, defense, government offices, and research universities (targeting is summarized in Figure 1). The group has also targeted professional/consulting services, high-tech industry, healthcare, and media/publishing. TEMP.Periscope overlaps in targeting, as well as tactics, techniques, and procedures (TTPs), with TEMP.Jumper, a group that also overlaps significantly with public reporting by Proofpoint and F-Secure on "NanHaiShu."


Figure 1: Summary of TEMP.Periscope activity

Incident Background

FireEye analyzed files on three open indexes believed to be controlled by TEMP.Periscope, which yielded insight into the group's objectives, operational tactics, and a significant amount of technical attribution/validation. These files were "open indexed" and thus accessible to anyone on the public internet. This TEMP.Periscope activity on these servers extends from at least April 2017 to the present, with the most current operations focusing on Cambodia's government and elections.

  • Two servers, chemscalere[.]com and scsnewstoday[.]com, operate as typical C2 servers and hosting sites, while the third, mlcdailynews[.]com, functions as an active SCANBOX server. The C2 servers contained both logs and malware.
  • Analysis of logs from the three servers revealed:
    • Potential actor logins from an IP address located in Hainan, China that was used to remotely access and administer the servers, and interact with malware deployed at victim organizations.
    • Malware command and control check-ins from victim organizations in the education, aviation, chemical, defense, government, maritime, and technology sectors across multiple regions. FireEye has notified all of the victims that we were able to identify.
  • The malware present on the servers included both new families (DADBOD, EVILTECH) and previously identified malware families (AIRBREAK, EVILTECH, HOMEFRY, MURKYTOP, HTRAN, and SCANBOX) .

Compromises of Cambodian Election Entities

Analysis of command and control logs on the servers revealed compromises of multiple Cambodian entities, primarily those relating to the upcoming July 2018 elections. In addition, a separate spear phishing email analyzed by FireEye indicates concurrent targeting of opposition figures within Cambodia by TEMP.Periscope.

Analysis indicated that the following Cambodian government organizations and individuals were compromised by TEMP.Periscope:

  • National Election Commission, Ministry of the Interior, Ministry of Foreign Affairs and International Cooperation, Cambodian Senate, Ministry of Economics and Finance
  • Member of Parliament representing Cambodia National Rescue Party
  • Multiple Cambodians advocating human rights and democracy who have written critically of the current ruling party
  • Two Cambodian diplomats serving overseas
  • Multiple Cambodian media entities

TEMP.Periscope sent a spear phish with AIRBREAK malware to Monovithya Kem, Deputy Director-General, Public Affairs, Cambodia National Rescue Party (CNRP), and the daughter of (imprisoned) Cambodian opposition party leader Kem Sokha (Figure 2). The decoy document purports to come from LICADHO (a non-governmental organization [NGO] in Cambodia established in 1992 to promote human rights). This sample leveraged scsnewstoday[.]com for C2.


Figure 2: Human right protection survey lure

The decoy document "Interview Questions.docx" (MD5: ba1e5b539c3ae21c756c48a8b5281b7e) is tied to AIRBREAK downloaders of the same name. The questions reference the opposition Cambodian National Rescue Party, human rights, and the election (Figure 3).


Figure 3: Interview questions decoy

Infrastructure Also Used for Operations Against Private Companies

The aforementioned malicious infrastructure was also used against private companies in Asia, Europe and North America. These companies are in a wide range of industries, including academics, aviation, chemical, maritime, and technology. A MURKYTOP sample from 2017 and data contained in a file linked to chemscalere[.]com suggest that a corporation involved in the U.S. defense industrial base (DIB) industry, possibly related to maritime research, was compromised. Many of these compromises are in line with TEMP.Periscope’s previous activity targeting maritime and defense industries. However, we also uncovered the compromise of a European chemical company with a presence in Asia, demonstrating that this group is a threat to business worldwide, particularly those with ties to Asia.

AIRBREAK Downloaders and Droppers Reveal Lure Indicators

Filenames for AIRBREAK downloaders found on the open indexed sites also suggest the ongoing targeting of interests associated with Asian geopolitics. In addition, analysis of AIRBREAK downloader sites revealed a related server that underscores TEMP.Periscope's interest in Cambodian politics.

The AIRBREAK downloaders in Table 1 redirect intended victims to the indicated sites to display a legitimate decoy document while downloading an AIRBREAK payload from one of the identified C2s. Of note, the hosting site for the legitimate documents was not compromised. An additional C2 domain, partyforumseasia[.]com, was identified as the callback for an AIRBREAK downloader referencing the Cambodian National Rescue Party.

Redirect Site (Not Malicious)

AIRBREAK Downloader

AIRBREAK C2

en.freshnewsasia.com/index.php/en/8623-2018-04-26-10-12-46.html

TOP_NEWS_Japan_to_Support_the_Election.js

(3c51c89078139337c2c92e084bb0904c) [Figure 4]

chemscalere[.]com

iric.gov.kh/LICADHO/Interview-Questions.pdf

[pdf]Interview-Questions.pdf.js

(e413b45a04bf5f812912772f4a14650f)

iric.gov.kh/LICADHO/Interview-Questions.pdf

[docx]Interview-Questions.docx.js

(cf027a4829c9364d40dcab3f14c1f6b7)

unknown

Interview_Questions.docx.js

(c8fdd2b2ddec970fa69272fdf5ee86cc)

scsnewstoday[.]com

atimes.com/article/philippines-draws-three-hard-new-lines-on-china/

Philippines-draws-three-hard-new-lines-on-china .js

(5d6ad552f1d1b5cfe99ddb0e2bb51fd7)

mlcdailynews[.]com

facebook.com/CNR.Movement/videos/190313618267633/

CNR.Movement.mp4.js

(217d40ccd91160c152e5fce0143b16ef)

Partyforumseasia[.]com

 

Table 1: AIRBREAK downloaders


Figure 4: Decoy document associated with AIRBREAK downloader file TOP_NEWS_Japan_to_Support_the_Election.js

SCANBOX Activity Gives Hints to Future Operations

The active SCANBOX server, mlcdailynews[.]com, is hosting articles related to the current Cambodian campaign and broader operations. Articles found on the server indicate targeting of those with interests in U.S.-East Asia geopolitics, Russia and NATO affairs. Victims are likely either brought to the SCANBOX server via strategic website compromise or malicious links in targeted emails with the article presented as decoy material. The articles come from open-source reporting readily available online. Figure 5 is a SCANBOX welcome page and Table 2 is a list of the articles found on the server.


Figure 5: SCANBOX welcome page

Copied Article Topic

Article Source (Not Compromised)

Leaders confident yet nervous

Khmer Times

Mahathir_ 'We want to be friendly with China

PM urges voters to support CPP for peace

CPP determined to maintain Kingdom's peace and development

Bun Chhay's wife dies at 60

Crackdown planned on boycott callers

Further floods coming to Kingdom

Kem Sokha again denied bail

PM vows to stay on as premier to quash traitors

Iran_ Don't trust Trump

Fresh News

Kim-Trump summit_ Singapore's role

Trump's North Korea summit may bring peace declaration - but at a cost

Reuters

U.S. pushes NATO to ready more forces to deter Russian threat

us-nato-russia_us-pushes-nato-to-ready-more-forces-to-deter-russian-threat

Interior Minister Sar Kheng warns of dirty tricks

Phnom Penh Post

Another player to enter market for cashless pay

Donald Trump says he has 'absolute right' to pardon himself but he's done nothing wrong - Donald Trump's America

ABC News

China-funded national road inaugurated in Cambodia

The Cambodia Daily

Kim and Trump in first summit session in Singapore

Asia Times

U.S. to suspend military exercises with South Korea, Trump says

U.S. News

Rainsy defamed the King_ Hun Sen

BREAKING NEWS

cambodia-opposition-leader-denied-bail-again-in-treason-case

Associated Press

Table 2: SCANBOX articles copied to server

TEMP.Periscope Malware Suite

Analysis of the malware inventory contained on the three servers found a classic suite of TEMP.Periscope payloads, including the signature AIRBREAK, MURKYTOP, and HOMEFRY. In addition, FireEye’s analysis identified new tools, EVILTECH and DADBOD (Table 3).

Malware

Function

Details

EVILTECH

Backdoor

  • EVILTECH is a JavaScript sample that implements a simple RAT with support for uploading, downloading, and running arbitrary JavaScript.
  • During the infection process, EVILTECH is run on the system, which then causes a redirect and possibly the download of additional malware or connection to another attacker-controlled system.

DADBOD

Credential Theft

  • DADBOD is a tool used to steal user cookies.
  • Analysis of this malware is still ongoing.

Table 3: New additions to the TEMP.Periscope malware suite

Data from Logs Strengthens Attribution to China

Our analysis of the servers and surrounding data in this latest campaign bolsters our previous assessment that TEMP.Periscope is likely Chinese in origin. Data from a control panel access log indicates that operators are based in China and are operating on computers with Chinese language settings.

A log on the server revealed IP addresses that had been used to log in to the software used to communicate with malware on victim machines. One of the IP addresses, 112.66.188.28, is located in Hainan, China. Other addresses belong to virtual private servers, but artifacts indicate that the computers used to log in all cases are configured with Chinese language settings.

Outlook and Implications

The activity uncovered here offers new insight into TEMP.Periscope’s activity. We were previously aware of this actor’s interest in maritime affairs, but this compromise gives additional indications that it will target the political system of strategically important countries. Notably, Cambodia has served as a reliable supporter of China’s South China Sea position in international forums such as ASEAN and is an important partner. While Cambodia is rated as Authoritarian by the Economist’s Democracy Index, the recent surprise upset of the ruling party in Malaysia may motivate China to closely monitor Cambodia’s July 29 elections.

The targeting of the election commission is particularly significant, given the critical role it plays in facilitating voting. There is not yet enough information to determine why the organization was compromised – simply gathering intelligence or as part of a more complex operation. Regardless, this incident is the most recent example of aggressive nation-state intelligence collection on election processes worldwide.

We expect TEMP.Periscope to continue targeting a wide range of government and military agencies, international organizations, and private industry. However focused this group may be on maritime issues, several incidents underscore their broad reach, which has included European firms doing business in Southeast Asia and the internal affairs of littoral nations. FireEye expects TEMP.Periscope will remain a virulent threat for those operating in the area for the foreseeable future.

The Paradox – Business Security Weekly #91

This week, Michael and Paul talk how to get the upper hand in any offer, experts needing to get better at telling stories, why companies need to build a skills inventory, and more! In our feature interview, CSO of Cisco Edna Conway makes her return on Business Security Weekly to sit down with Paul to discuss Intellectual Property! All that and more on this episode of Business Security Weekly!

Full Show Notes: https://wiki.securityweekly.com/BSWEpisode91

 

Visit https://www.securityweekly.com/bsw for all the latest episodes!

 

Visit https://www.activecountermeasures/bsw to sign up for a demo or buy our AI Hunter!!

 

→Visit our website: https://www.securityweekly.com

→Follow us on Twitter: https://www.twitter.com/securityweekly

→Like us on Facebook: https://www.facebook.com/secweekly

IDG Contributor Network: Legalizing online sports betting means a new need for security

On May 14, 2018, the Supreme Court of the United States (SCOTUS) ruled in favor of New Jersey’s case to repeal the Professional and Amateur Sports Protection Act (PASPA), thereby paving the way towards legalizing online sports betting in the U.S. PASPA prohibited all states other than those with existing legislation—Nevada, Oregon, Delaware, and Montana—from legalizing online sports betting.

The big business of online sports betting

It comes as no surprise that sports gambling is big business. In 2017, Nevada’s Gaming Control board reported a $4.8 billion bet at its sportsbooks. This was a new record high, but legal betting is just the beginning of the story. No one has a definitive number for how much money is bet illicitly. For example, the research firm, Eilers & Krejcik Gaming, projects that this number could fall between $50 billion and $60 billion.

To read this article in full, please click here

Reality and the Espionage Act

Reality Winner 50%


Reality Winner, the first whistleblower prosecuted by the Trump administration for leaking information to the press, will spend five years in prison as punishment for making officials and the public aware of vulnerabilities in election infrastructure. This unusually long sentence breaks with precedent, and is representative of the government’s increasing willingness to use the Espionage Act to punish and imprison whistleblowers and chill journalism.

On June 3, 2017, FBI agents raided Winner's home in Georgia. Federal prosecutors suspected that Winner, an intelligence contractor who worked with the NSA, had shared classified information with journalists, and obtained a search warrant to search her house and seize her electronic devices. After the FBI agents finished searching her home, they began chatting with her, casually at first, in what eventually turned into a interrogation that ended with her arrest. Winner later said that the FBI agents never told her that she had the right to remain silent or speak with an attorney.

Two days later, The Intercept published a partially-redacted version of a classified NSA document, which concluded that hackers they believe were working with Russian military intelligence had tried to penetrate states’ election systems during the 2016 election. On June 8, Winner was formally arraigned on one charge of violating 18 U.S.C. § 793(e), a provision of the Espionage Act.

Passed in 1917, the Espionage Act was originally intended to be used against foreign spies and saboteurs during World War I. But almost immediately after the Espionage Act was enacted, it was used to prosecute anti-war activists, including socialist presidential candidate Eugene Debs. The Supreme Court shamefully upheld the convictions of anti-war protesters in a series of unanimous decisions in 1919.

In 1971, Daniel Ellsberg leaked the Pentagon Papers — a classified history of the Vietnam War, which revealed that the government had repeatedly lied to the American people — to reporters at The New York Times and Washington Post. While the Supreme Court ruled that the government could not stop the papers from publishing articles about the documents, the Nixon administration retaliated against Ellsberg by charging him under the Espionage Act. Ultimately his case was thrown out for government misconduct. He was the first person to be prosecuted under the law for giving information to journalists, but he would not be the last.

During the Obama administration, the Department of Justice prosecuted at least eight people for sharing classified information with journalists. Most of the Espionage Act cases brought by Obama’s Justice Department never made it to trial, and instead, defendants were forced to take a plea deal. That’s partly because it’s next to impossible to mount an effective defense against an Espionage Act charge.

The Espionage Act simply prohibits the unauthorized disclosure of information related to the national defense — a broad category that includes information about controversial government programs, as well as true military secrets like the nuclear codes.

Defendants charged with violating the law cannot present an argument that the leak was justified or in the public interest. To convict you under the Espionage Act, federal prosecutors don't need to prove that your leak actually put anyone in danger. All they need to prove is that defendants knew the information was "related to national defense” when they gave it to journalists.

The federal government’s classification system is governed through executive orders, which give executive branch agencies the ability to designate certain information as “confidential,” “secret,” and “top-secret” if they determine that the disclosure of the information could potentially harm national security. Since the executive branch is (at least in theory) only allowed to classify information that it believes could harm national security, all classified information is assumed to be potentially dangerous to national security — even though we know this system is regularly and systematic abused to hide controversial, embarrassing, corrupt, or illegal activity.

This is circular logic — classified information must be dangerous, because if it weren’t dangerous, it wouldn’t be classified — means that the government can argue that leaking any classified information is functionally equivalent to leaking information that you know can harm the United States.

Winner wanted to challenge this assumption that all classified information is potentially dangerous. Court filings show that her attorneys planned to argue that the NSA report on Russian hacking attempts that Winner allegedly leaked had been over-classified, and the government’s claims that the release of the document would cause “exceptionally grave damage” were without merit.

Her attorneys tried to subpoenaed a wide array of intelligence agencies, hoping to show that the information Winner allegedly leaked about Russian hacking attempts was less of a state secret and more of an open secret within the government.

They also planned to enlist an expert witness — Bill Leonard, the former head of the Information Security Oversight Office, responsible for overseeing the federal government’s entire classification system — to testify about the government’s over-classification problem.

But Winner’s case once again proved it’s hard, if not impossible, to fight an Espionage Act prosecution. A judge denied all of Winner’s attempts to subpoena government agencies and imposed draconian security precautions on her attorneys, which prohibited them from discussing Winner’s case on unsecured phone lines and conducting Google searches for information about the document Winner allegedly leaked.

Meanwhile, Winner was held in a small county jail without bail for more than a year, after prosecutors convinced a judge that Winner was a flight risk because she had criticized the United States and could speak multiple foreign languages.

Winner’s treatment was harsh even by the standard of other Espionage Act prosecutions. Others charged with leaking classified information —like Jeffrey Sterling, Stephen Kim, and John Kiriakou—were released on bond.

Finally, on June 26, 2018, after over a year of fighting the case, Winner pleaded guilty to one count of violating the Espionage Act. According to the terms of her plea deal, Winner will serve 63 months in prison, followed by three years of supervised release.

“The use of the Espionage charge prevents a person from defending themselves or explaining their actions to a jury, thus making it difficult for them to receive a fair trial and treatment in the court system," Winner’s mother, Billie Winner-Davis, said in a statement. "I do believe that whatever [Reality] did or did not do she acted with good intentions. ... We need to work toward reforming laws so that the Espionage Act is not leveraged against our citizens."

Winner’s sentence is hardly lenient. She was a first-time offender, only accused of leaking one document. She was charged with a single count of violating 18 U.S.C. § 793(e), a section of the Espionage Act that carries a maximum sentence of 10 years. Winner’s sentence is the longest sentence that a leaker has ever received in federal court. (Chelsea Manning, who was originally sentenced to 35 years in prison and later had her sentence commuted by President Obama after 7 years, was convicted at a military court-martial.)

Winner’s only crime, literally, was to share information with journalists and the American people about a foreign government’s attempt to hack U.S. voting systems. State election boards reportedly appreciated Winner’s leak, which gave them the information needed to investigate Russian hacking attempts and better secure their electronic voting infrastructure.

But the federal government treated Winner as though she were a spy. Federal prosecutors charged her with violating an anti-espionage statute that is more than a century old, while arguing that she had to remain detained without bail until trial because she had no loyalty to the United States.

The Department of Justice’s increasing use of the Espionage Act against people who share information with journalists is shameful. A country that claims to value the freedom of the press should not imprison people for speaking to journalists.

Update: On July 13, 2018, the Department of Justice announced the indictment of 12 Russian intelligence officers on charges of hacking. The grand jury indictment, which is unclassified and available to the public, includes information about Russian attempts to hack state election systems — the same information that Winner allegedly leaked to The Intercept.

Blackhat, BSidesLV and DEF CON Parties 2018

Parties

For real, we’re back once again for the Blackhat, BSidesLV and DEF CON Parties 2018. Here is the list. Please note that this is a work in progress and I’ll be sure to add more as I become aware of them.

Please note that this sched should work fine in most smart phone browsers.

RSVP

Be sure to RSVP for parties listed that note that as the vast majority will not be allowing folks to register at the door. Please note that events which are not searchable, or have not directly requested I post them, will not be included here.

Got a Party?

Most importantly, if I’m missing a 2018 party here, please let me know through our contact us form and I’ll be sure to add them.

Copyright: pressmaster / 123RF Stock Photo

DateParty HostLocationTimeLink
August 7, 2018Risky Biz PartyAlexxa’s Bar7:00 PM – 10:00 PMRSVP
August 7, 2018HackerOneEyecandy Sound Lounge8:00 PM - 11:00 PMRSVP
August 7, 2018A10Libertine Social in Mandalay Bay6:00 PM - 8:00 PMRSVP
August 7, 2018Distil NetworksLight Nightclub at the Mandalay Bay9:00 PM – 12:00 AMRSVP
August 7, 2018Black Hat Social HourAureole5:30 PM - 8:00 PMRSVP
August 8, 2018Duo Security PartyFleur in Mandalay Bay7:00 PM – 9:00 PMRSVP
August 8, 2018Flashpoint PartyLibertine Social in Mandalay Bay7:00 PM – 10:00 PMRSVP
August 8, 2018LevelUPSkyfall Lounge in the Delano8:00 PM - 12:00 AMRSVP
August 8, 2018IOActive IOAsisHouse of Blues10:00 AM – 6:00 PMRSVP
August 8, 2018Cylance Blackhat Partyminus5° Ice Experience9:00 PM – 1:00 AMRSVP
August 8, 2018Rapid7 PartyOMNIA Nightclub, Caesars10:00 PM - 1:00 AMRSVP
August 8, 2018Cisco PartyTopgolf Las Vegas8:00 PM - 11:00 PMRSVP
August 8, 2018Carbon BlackBordergrill in Mandalay Bay7:00 PM – 9:00 PMRSVP
August 8, 2018JASK & DigitalshadowsEyecandy Sound Lounge8:00 PM - 10:00 PMRSVP
August 8, 2018BSidesLV Pool PartyTuscany Suites Pool10:00 PM - 4:00 AMBSidesLV badge required
August 9, 2018Bugcrowd House PartyRockhouse Bar8:00 PM – 12:00 AMRSVP
August 10, 2018IOActive Women, Wisdom, & WineCaesars Palace Suites3:00 PM - 5:00 PMRSVP
August 10, 2018QueerCon Pool PartyPalm’s Palace Pool8:00PM – 3:00AMOpen

The post Blackhat, BSidesLV and DEF CON Parties 2018 appeared first on Liquidmatrix Security Digest.

Chinese arrest 20 in major Crypto Currency Mining scam

According to Chinese-language publication Legal Daily police in two districts of China have arrested 20 people for their roles in a major crypto currency mining operation that earned the criminals more than 15 million yuan (currently about $2M USD).

The hackers installed mining software developed by Dalian Yuping Network Technology Company ( 大连昇平网络科技有限 ) that was designed to steal three types of coins.  Digibyte Coins (DGB, currently valued at USD$0.03 each),  Siacoin (SC, currently valued at $0.01 each) and DeCred coins (DCR coins, currently valued at $59.59 each).

It is believed that these currencies were chosen for the dual reason that they are easier to mine, due to less competition, and that they are less likely to be the target of sophisticated blockchain analysis tools.

The Game Cheat Hacker

The investigation began when Tencent detected the presence of a hidden Trojan horse with silent mining capabilities built into a cheat for a popular first person shooter video game. The plug-in provided a variety of cheats for the game, including "automatic aiming", "bullet acceleration", "bullet tracking" and "item display."  
Tencent referred the case to the Wei'an Municipal Public Security Bureau, who handled the case extremely well.  As they learned more about the trojans, they identified first the social media groups and forums where the trojan was being spread, and traced the identity of the person uploading the trojaned game cheat to a criminal named Yang Mobao. Mobao participated as a forum moderator on a site called the "Tianxia Internet Bar Forum" and members who received the cheat from him there widely shared it in other forums and social media sites, including many file shares on Baidu.
Mobao was popularizing the cheat program by encouraging others to make suggestions for new functionality.  The users who were using the tool did not suspect that they were actually mining crypto-currency while using the cheat.  More than 30,000 victims were using his cheat software and secretly mining crypto-currency for him.
Yang Mobao had a strong relationship with gamers from his business of selling gaming video cards to Internet cafes.  He installed at least 5,774 cards in at least 2,465 Internet cafes across the country, preloading the firmware on the cards to perform mining.  It turns out that these cards ALSO were trojaned!  As a major customer of Dalian Yuping, Moubao was offered a split of the mining proceeds from the cards he installed, earning him more than 268,000 yuan.
Yang is described as a self-taught computer programmer who had previously worked management Internet cafes.  After experiencing some profit from the scheme above, he modified the malware embedded in some of the video cards and installed his own miner, mining the HSR coin and transferring the proceeds to a wallet he controlled.

The Video Card Maker

After Yang Mobao confessed to his crimes, the cybercrime task force sent 50 agents to Dalian, in Liaoning Province.  The Task Force learned that Dalian Yuping Network Technology had been approached by advertisers, who paid them embed advertising software on their video cards, which were then installed in 3.89 million computers, mostly high-end gaming systems installed in video cafes.  The company's owner, He Mou, and the company's Financial Controller, his wife Chen Mou, had instructed the company's head of R&D, Zhang Ning, to investigate mining software and to experiment with various mining trojans.  In addition to the illegal advertising software embedded in those 3.89 million video cards, their crypto currency mining software was embedded into 1 million additional video cards which were sold and deployed in Internet cafes across the country.
Each time one of those machines successfully mined a coin, the coin was transferred to a wallet owned by He Mou.  Chen Mou could then cash them out at any time in the future.
 16 suspects at the company were interrogated and 12 criminally detained for the crime of illegally controlling computer information systems.  Zhao was sentenced to four years himself.
(I learned of this story from CoinDesk's Wolfie Zhao, and followed up on it from the Legal Daily story he links to as well as a report in Xinhuanet, by Reporter Xy Peng and correspondent Liu Guizeng Wang Yen.) (记者 徐鹏 通讯员 刘贵增 王艳)

Malicious PowerShell Detection via Machine Learning

Introduction

Cyber security vendors and researchers have reported for years how PowerShell is being used by cyber threat actors to install backdoors, execute malicious code, and otherwise achieve their objectives within enterprises. Security is a cat-and-mouse game between adversaries, researchers, and blue teams. The flexibility and capability of PowerShell has made conventional detection both challenging and critical. This blog post will illustrate how FireEye is leveraging artificial intelligence and machine learning to raise the bar for adversaries that use PowerShell.

In this post you will learn:

  • Why malicious PowerShell can be challenging to detect with a traditional “signature-based” or “rule-based” detection engine.
  • How Natural Language Processing (NLP) can be applied to tackle this challenge.
  • How our NLP model detects malicious PowerShell commands, even if obfuscated.
  • The economics of increasing the cost for the adversaries to bypass security solutions, while potentially reducing the release time of security content for detection engines.

Background

PowerShell is one of the most popular tools used to carry out attacks. Data gathered from FireEye Dynamic Threat Intelligence (DTI) Cloud shows malicious PowerShell attacks rising throughout 2017 (Figure 1).


Figure 1: PowerShell attack statistics observed by FireEye DTI Cloud in 2017 – blue bars for the number of attacks detected, with the red curve for exponentially smoothed time series

FireEye has been tracking the malicious use of PowerShell for years. In 2014, Mandiant incident response investigators published a Black Hat paper that covers the tactics, techniques and procedures (TTPs) used in PowerShell attacks, as well as forensic artifacts on disk, in logs, and in memory produced from malicious use of PowerShell. In 2016, we published a blog post on how to improve PowerShell logging, which gives greater visibility into potential attacker activity. More recently, our in-depth report on APT32 highlighted this threat actor's use of PowerShell for reconnaissance and lateral movement procedures, as illustrated in Figure 2.


Figure 2: APT32 attack lifecycle, showing PowerShell attacks found in the kill chain

Let’s take a deep dive into an example of a malicious PowerShell command (Figure 3).


Figure 3: Example of a malicious PowerShell command

The following is a quick explanation of the arguments:

  • -NoProfile – indicates that the current user’s profile setup script should not be executed when the PowerShell engine starts.
  • -NonI – shorthand for -NonInteractive, meaning an interactive prompt to the user will not be presented.
  • -W Hidden – shorthand for “-WindowStyle Hidden”, which indicates that the PowerShell session window should be started in a hidden manner.
  • -Exec Bypass – shorthand for “-ExecutionPolicy Bypass”, which disables the execution policy for the current PowerShell session (default disallows execution). It should be noted that the Execution Policy isn’t meant to be a security boundary.
  • -encodedcommand – indicates the following chunk of text is a base64 encoded command.

What is hidden inside the Base64 decoded portion? Figure 4 shows the decoded command.


Figure 4: The decoded command for the aforementioned example

Interestingly, the decoded command unveils a stealthy fileless network access and remote content execution!

  • IEX is an alias for the Invoke-Expression cmdlet that will execute the command provided on the local machine.
  • The new-object cmdlet creates an instance of a .NET Framework or COM object, here a net.webclient object.
  • The downloadstring will download the contents from <url> into a memory buffer (which in turn IEX will execute).

It’s worth mentioning that a similar malicious PowerShell tactic was used in a recent cryptojacking attack exploiting CVE-2017-10271 to deliver a cryptocurrency miner. This attack involved the exploit being leveraged to deliver a PowerShell script, instead of downloading the executable directly. This PowerShell command is particularly stealthy because it leaves practically zero file artifacts on the host, making it hard for traditional antivirus to detect.

There are several reasons why adversaries prefer PowerShell:

  1. PowerShell has been widely adopted in Microsoft Windows as a powerful system administration scripting tool.
  2. Most attacker logic can be written in PowerShell without the need to install malicious binaries. This enables a minimal footprint on the endpoint.
  3. The flexible PowerShell syntax imposes combinatorial complexity challenges to signature-based detection rules.

Additionally, from an economics perspective:

  • Offensively, the cost for adversaries to modify PowerShell to bypass a signature-based rule is quite low, especially with open source obfuscation tools.
  • Defensively, updating handcrafted signature-based rules for new threats is time-consuming and limited to experts.

Next, we would like to share how we at FireEye are combining our PowerShell threat research with data science to combat this threat, thus raising the bar for adversaries.

Natural Language Processing for Detecting Malicious PowerShell

Can we use machine learning to predict if a PowerShell command is malicious?

One advantage FireEye has is our repository of high quality PowerShell examples that we harvest from our global deployments of FireEye solutions and services. Working closely with our in-house PowerShell experts, we curated a large training set that was comprised of malicious commands, as well as benign commands found in enterprise networks.

After we reviewed the PowerShell corpus, we quickly realized this fit nicely into the NLP problem space. We have built an NLP model that interprets PowerShell command text, similar to how Amazon Alexa interprets your voice commands.

One of the technical challenges we tackled was synonym, a problem studied in linguistics. For instance, “NOL”, “NOLO”, and “NOLOGO” have identical semantics in PowerShell syntax. In NLP, a stemming algorithm will reduce the word to its original form, such as “Innovating” being stemmed to “Innovate”.

We created a prefix-tree based stemmer for the PowerShell command syntax using an efficient data structure known as trie, as shown in Figure 5. Even in a complex scripting language such as PowerShell, a trie can stem command tokens in nanoseconds.


Figure 5: Synonyms in the PowerShell syntax (left) and the trie stemmer capturing these equivalences (right)

The overall NLP pipeline we developed is captured in the following table:

NLP Key Modules

Functionality

Decoder

Detect and decode any encoded text

Named Entity Recognition (NER)

Detect and recognize any entities such as IP, URL, Email, Registry key, etc.

Tokenizer

Tokenize the PowerShell command into a list of tokens

Stemmer

Stem tokens into semantically identical token, uses trie

Vocabulary Vectorizer

Vectorize the list of tokens into machine learning friendly format

Supervised classifier

Binary classification algorithms:

  • Kernel Support Vector Machine
  • Gradient Boosted Trees
  • Deep Neural Networks

Reasoning

The explanation of why the prediction was made. Enables analysts to validate predications.

The following are the key steps when streaming the aforementioned example through the NLP pipeline:

  • Detect and decode the Base64 commands, if any
  • Recognize entities using Named Entity Recognition (NER), such as the <URL>
  • Tokenize the entire text, including both clear text and obfuscated commands
  • Stem each token, and vectorize them based on the vocabulary
  • Predict the malicious probability using the supervised learning model


Figure 6: NLP pipeline that predicts the malicious probability of a PowerShell command

More importantly, we established a production end-to-end machine learning pipeline (Figure 7) so that we can constantly evolve with adversaries through re-labeling and re-training, and the release of the machine learning model into our products.


Figure 7: End-to-end machine learning production pipeline for PowerShell machine learning

Value Validated in the Field

We successfully implemented and optimized this machine learning model to a minimal footprint that fits into our research endpoint agent, which is able to make predictions in milliseconds on the host. Throughout 2018, we have deployed this PowerShell machine learning detection engine on incident response engagements. Early field validation has confirmed detections of malicious PowerShell attacks, including:

  • Commodity malware such as Kovter.
  • Red team penetration test activities.
  • New variants that bypassed legacy signatures, while detected by our machine learning with high probabilistic confidence.

The unique values brought by the PowerShell machine learning detection engine include:  

  • The machine learning model automatically learns the malicious patterns from the curated corpus. In contrast to traditional detection signature rule engines, which are Boolean expression and regex based, the NLP model has lower operation cost and significantly cuts down the release time of security content.
  • The model performs probabilistic inference on unknown PowerShell commands by the implicitly learned non-linear combinations of certain patterns, which increases the cost for the adversaries to bypass.

The ultimate value of this innovation is to evolve with the broader threat landscape, and to create a competitive edge over adversaries.

Acknowledgements

We would like to acknowledge:

  • Daniel Bohannon, Christopher Glyer and Nick Carr for the support on threat research.
  • Alex Rivlin, HeeJong Lee, and Benjamin Chang from FireEye Labs for providing the DTI statistics.
  • Research endpoint support from Caleb Madrigal.
  • The FireEye ICE-DS Team.

If An Infosec Policy Falls In The Forest

When you are building an Information Security practice you need a solid governance structure in place. For those of you who might not be familiar we can look at it a more accessible way. If you are building a house you need a solid foundation otherwise the thing will collapse.
Much in the same vein, if you do not have a solid set of policies, you are destined to fail.

All is not lost as there are all sorts of resources that are available to help you online. The key point to remember is that with anything you find should never be used verbatim. If you cut and paste a policy you find online and swap the letterhead you should just hang up your tin star now. Do not pass go. Do not collect $200.

Why? Well, let’s cut to the chase. No company is the same as the next. You would be doing yourself and your organization a disservice if you are to maintain this perspective. OK, so if you are maintaining the idea that because you work at Bank A and Bob has a job in governance at Bank B that you will not be able to take their policy and simply use it at your own. Realistically you will need to tailor any policy to your own environment.

If you don’t have a proper governance structure in place it can cause you some angst. As an example, how can you remove an employee who is surfing porn on the Internet if you have no framework in place to deal with such an action? That is the simplest example that comes to mind.

To spin it differently, there was a shop that I worked for at which I was told that I could not use a certain piece of software. It was a fairly benign software application so, I couldn’t help but to ask why. Now, bearing in mind I had no argument with being told no. I was just interested in knowing what the rationale was for that decision. The answer I received was, “because $group said no.”

What?

I asked the unforgivable question. I said, “OK, can I see the documentation regarding that decision? I just want to better understand why.” I was greeted with a Jedi hand wave. This isn’t OK. If you don’t have things documented then they do not exist. Pure and simple.
So, when you are tackling the policies for your organization be sure to go beyond the flaming sword of justice approach to governance. It is simply a dead method for dealing with the foundation for your security program. You want to facilitate the business in a safe and secure way to ensure that security is not the “road block” of old while saving the organization from itself.

When you create your policy documents make sure that they receive reviews from senior leadership, legal and human resources departments. Failing to do so will limit the veracity and adoption of a policy.

If you do not communicate your policies within your organization, how can you expect people to abide by them? Communication is a mainstay of any governance program. Go forth and bring the positive word of security to the masses.

If an information security policy falls in the corporate forest…does anyone read it?

Originally posted on CSO Online by me.

The post If An Infosec Policy Falls In The Forest appeared first on Liquidmatrix Security Digest.

IDG Contributor Network: Strength in knowledge: How connected identity and access management transforms secure access

If you’re a fan of TV crime dramas, you’ve no doubt seen one of those episodes where the bad guy gets away with something because the local police department doesn’t have a key piece of information about him that the FBI does (or vice-versa). Meanwhile, there’s usually a subplot going on at the same time, in which a perfectly innocent person is detained by the cops even though he didn’t do anything wrong. Not only is he detained for no good reason, but by the time they figure it out and let him go on his way, the real criminal has done even more damage. If only they’d had access to the data that would have placed the innocent party in another place at the time of the crime, they could have stopped wasting their (and his) time and focused instead on catching the actual bad guys.

To read this article in full, please click here