
Research
Two Malicious Rust Crates Impersonate Popular Logger to Steal Wallet Keys
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
twitter-text-editted
Advanced tools
== twitter-text {}[http://travis-ci.org/twitter/twitter-text-rb] {
}[https://codeclimate.com/github/twitter/twitter-text-rb]
A gem that provides text processing routines for Twitter Tweets. The major reason for this is to unify the various auto-linking and extraction of usernames, lists, hashtags and URLs.
== Extraction Examples
class MyClass include Twitter::Extractor usernames = extract_mentioned_screen_names("Mentioning @twitter and @jack") # usernames = ["twitter", "jack"] end
class MyClass include Twitter::Extractor extract_reply_screen_name("@twitter are you hiring?").do |username| # username = "twitter" end end
== Auto-linking Examples
class MyClass include Twitter::Autolink
html = auto_link("link @user, please #request")
end
module ApplicationHelper include Twitter::Autolink end
<%= auto_link("link @user, please #request") %>
=== Usernames
Username extraction and linking matches all valid Twitter usernames but does not verify that the username is a valid Twitter account.
=== Lists
Auto-link and extract list names when they are written in @user/list-name format.
=== Hashtags
Auto-link and extract hashtags, where a hashtag can contain most letters or numbers but cannot be solely numbers and cannot contain punctuation.
=== URLs
Asian languages like Chinese, Japanese or Korean may not use a delimiter such as a space to separate normal text from URLs making it difficult to identify where the URL ends and the text starts.
For this reason twitter-text currently does not support extracting or auto-linking of URLs immediately followed by non-Latin characters.
Example: "http://twitter.com/は素晴らしい" . The normal text is "は素晴らしい" and is not part of the URL even though it isn't space separated.
=== International
Special care has been taken to be sure that auto-linking and extraction work in Tweets of all languages. This means that languages without spaces between words should work equally well.
=== Hit Highlighting
Use to provide emphasis around the "hits" returned from the Search API, built to work against text that has been auto-linked already.
=== Conformance
To run the Conformance suite, you'll need to add that project as a git submodule. From the root twitter-text-rb directory, run:
git submodule add git@github.com:twitter/twitter-text-conformance.git test/twitter-text-conformance/ git submodule init git submodule update
=== Thanks
Thanks to everybody who has filed issues, provided feedback or contributed patches. Patches courtesy of:
At Twitter …
Patches from the community …
Anyone who has filed an issue. It helps. Really.
=== Copyright and License
Copyright 2011 Twitter, Inc.
Licensed under the Apache License, Version 2.0: http://www.apache.org/licenses/LICENSE-2.0
FAQs
Unknown package
We found that twitter-text-editted demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 10 open source maintainers 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
Socket uncovers malicious Rust crates impersonating fast_log to steal Solana and Ethereum wallet keys from source code.
Research
A malicious package uses a QR code as steganography in an innovative technique.
Research
/Security News
Socket identified 80 fake candidates targeting engineering roles, including suspected North Korean operators, exposing the new reality of hiring as a security function.