![Maven Central Adds Sigstore Signature Validation](https://cdn.sanity.io/images/cgdhsj6q/production/7da3bc8a946cfb5df15d7fcf49767faedc72b483-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Maven Central Adds Sigstore Signature Validation
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
A library to fetch and parse OpenGraph properties from an URL or a given string.
Ruby 3.1 and later are supported. Compatibility with earlier versions might exist but is not verified.
Add this line to your application's Gemfile:
gem "open_graph_reader"
And then execute:
$ bundle
Or install it yourself as:
$ gem install open_graph_reader
Install the following gems the same way for a higher success rate at fetching websites:
require "open_graph_reader"
# Returns nil if anything on the object is invalid
object = OpenGraphReader.fetch("http://examples.opengraphprotocol.us/article.html")
# Raises if anything on the object is invalid
object = OpenGraphReader.fetch!("http://examples.opengraphprotocol.us/article.html")
# Read from string
object = OpenGraphReader.parse(html)
object = OpenGraphReader.parse!(html)
# Access by full property name
object.og.title #=> "5 Held in Plot to Bug Office"
# Optional properties can return nil
object.og.description #=> nil
# Supports properties that are objects themselves
object.og.image.to_s #=> "http://examples.opengraphprotocol.us/media/images/50.png"
object.og.image.content #=> "http://examples.opengraphprotocol.us/media/images/50.png"
object.og.image.url #=> "https://examples.opengraphprotocol.us/media/images/50.png"
object.og.image.width #=> 50
# Supports arrays
object.og.images.first == object.og.image #=> true
object.article.tags #=> ["Watergate"]
# Custom namespace
class MyNamespace
include OpenGraphReader::Object
namespace :my, :namespace # my:namespace
string :name, required: true # my:namespace:name
url :url, default: "http://example.org/my_namespace"
integer :pages, collection: true
# See the shipped definitions for more examples
end
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)FAQs
Unknown package
We found that open_graph_reader 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
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.
Security News
CISOs are racing to adopt AI for cybersecurity, but hurdles in budgets and governance may leave some falling behind in the fight against cyber threats.
Research
Security News
Socket researchers uncovered a backdoored typosquat of BoltDB in the Go ecosystem, exploiting Go Module Proxy caching to persist undetected for years.