Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Please see https://pypi.org/project/pyclip/
Cross-platform clipboard utilities supporting both binary and text data.
Some key features include:
Requires python 3.7+
pip install pyperclip3
pyperclip3 can be used in Python code
import pyperclip3
pyperclip3.copy("hello clipboard") # copy data to the clipboard
cb_data = pyperclip3.paste() # retrieve clipboard contents
print(cb_data)
pyperclip3.clear() # clears the clipboard contents
assert not pyperclip3.paste()
Or a CLI
# paste clipboard contents to stdout
python -m pyclip paste
# load contents to the clipboard from stdin
python -m pyperclip3 copy < myfile.text
# same as above, but pipe from another command
some-program | python -m pyperclip3 copy
Installing via pip also provides console script pyclip
:
pyclip copy < my_file.txt
This library implements functionality for several platforms and clipboard utilities.
xclip
)If there is a platform or utility not currently listed, please request it by creating an issue.
pywin32
package is installed as a requirement.MacOS has support for multiple backends. By default, the pasteboard
package is used.
pbcopy
/pbpaste
can also be used as a backend, but does not support arbitrary binary data, which may lead to
data being lost on copy/paste. This backend may be removed in a future release.
Linux requires xclip
to work (which means you must also use X). Install with your package manager, e.g. sudo apt install xclip
FAQs
Cross-platform clipboard utilities supporting both binary and text data.
We found that pyperclip3 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.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.