
Security News
/Research
Popular node-ipc npm Package Infected with Credential Stealer
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.
libhwp
Advanced tools
rust로 작성된 python hwp 리더 라이브러리
본 제품은 한글과컴퓨터의 한/글 문서 파일(.hwp) 공개 문서를 참고하여 개발하였습니다.
find_all('tag', recursive=Boolean)이며 recursive는 기본적으로 True입니다.
from libhwp import HWPReader
hwp = HWPReader('<파일 경로>')
# 모든 문단 출력 (표, 캡션 포함)
for paragraph in hwp.find_all('paragraph'):
print(paragraph)
# 표 내용 출력 (표 안의 표 포함)
for table in hwp.find_all('table'):
for cell in table.cells:
for paragraph in cell.paragraphs:
print(paragraph)
# 표 내용 출력 (표 안의 표 무시)
for table in hwp.find_all('table', recursive=False):
for cell in table.cells:
for paragraph in cell.paragraphs:
print(paragraph)
# 표 안의 표 내용 출력 방법 2
for table in hwp.find_all('table'):
for cell in table.cells:
for paragraph in cell.paragraphs:
print(paragraph)
# paragraph에서도 recursive 하게 찾을 수 있다
for p in paragraph.find_all('paragraph'):
print(p)
# 수식 내용 출력
for equation in hwp.find_all('equation'):
print(equation.script) # eg. f(x)= logx+sinx
# 문서에 사용된 파일 저장
for file in hwp.bin_data:
with open(file.name, 'wb') as f:
f.write(file.data)
FAQs
Unknown package
We found that libhwp demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
/Research
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.

Security News
TeamPCP and BreachForums are promoting a Shai-Hulud supply chain attack contest with a $1,000 prize for the biggest package compromise.

Security News
Packagist urges PHP projects to update Composer after a GitHub token format change exposed some GitHub Actions tokens in CI logs.