Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Provides tools to ease working with the DSX DML command syntax, an archaic and obnoxious format used by DSX Access systems' SFTP APIs for making changes to records in their access control system's database(s).
Add this line to your application's Gemfile:
gem 'dsx-dml'
And then execute:
$ bundle
Or install it yourself as:
$ gem install dsx-dml
require 'dsx/dml'
# Declare what Location Number (zone) to make changes in and set the UDF field for UID string.
# Optionally include sftp credentials.
zone = Dsx::Dml::Zone.new(1111, 2, {address: '127.0.0.1', user: 'dsx_user', password: 'dsx_password'})
# Use a unique identifier to create a changeset for that unique identifier
changeset_0 = zone.use('123456789100')
# Chain together changes for tables related to that unique identifier
changeset_0.table('Names').write({
FName: 'Harry',
LName: 'Bird',
Company: 'Harry Bird Co',
Visitor: '',
Trace: '',
Notes: 'Often wears bowties'
}).table('UDF').write({
UdfNum: 2,
UdfText: '123456789100'
}).table('Cards').write({
Code: '123456789100',
PIN: 1234,
StartDate: '01/01/2001',
StopDate: '11/11/2111',
NumUses: 9999
})
# create another changeset for a different unique identifier
changeset_1 = zone.use('123456789101')
changeset_1.table('Cards').add_acl('Parking Garage').write()
# Push changesets to SFTP receiver (using the credentials passed to Zone.new)
changeset_0.net_sftp() # Uses ruby Net::SFTP library
changeset_1.curl() # requires system curl with SFTP support
Dsx::Dml::Operation
is a wraper intended to make it easier to set up and use certain DML operations.
require 'dsx/operation'
op = Dsx::Dml::Operation.new({ location_num: 1111,
udf_num: 2,
first_name: 'Harry',
last_name: 'Bird',
company: 'Harry Bird Co',
identifier: '123456789100' },
{ address: '127.0.0.1',
user: 'dsx_user',
password: 'dsx_password' })
op.access_levels += ['Top Secret Lab 1', 'Top Secret Lab 2']
op.access_levels -= ['Super Secret Lab 0']
op.linking_level = 3
op.net_sftp()
Dsx::Dml::Writer
is used to push commands to DSX SFTP endpoints. Supports Net::SFTP
and curl
.
While writer credentials can be passed through to Dsx::Dml::Operation
and Dsx::Dml::Zone
, writers
can also be instantiated separately and passed at write time.
require 'dsx/operation'
require 'dsx/writer'
writer = Dsx::Dml::Writer.new({ address: '127.0.0.1',
user: 'dsx_user',
password: 'dsx_password' })
op = Dsx::Dml::Operation.new({ location_num: 1111,
udf_num: 2,
first_name: 'Harry',
last_name: 'Bird',
company: 'Harry Bird Co',
identifier: '123456789100' })
op.access_levels += ['Top Secret Lab 3']
op.net_sftp(writer)
git checkout -b my-new-feature
)git commit -am 'Add some feature'
)git push origin my-new-feature
)FAQs
Unknown package
We found that dsx-dml demonstrated a not healthy version release cadence and project activity because the last version was released 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
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.