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.
remocon is a CLI for Firebase Remote Config via its REST API. Conditions and parameters are managed by YAML files. The goal of this gem is Remote Config as a Code. :)
Now conditions cannot be updated via API so that you can modify only parameters.
If you'd like to use this on CircleCI, you can use https://github.com/jmatsu/remocon-starter-kit .
NOTE: v0.5.0 and lower versions contain serious bugs. Please use 0.5.1 or greater, sorry.
Since v0.3.0, remocon is supporting to get an access token.
If this doesn't work, then please try bin/get_access_token <service-acount.json>
.
token=$(bundle exec remocon --service-json=<path/to/service-account-json>)
bundle exec remocon pull --prefix=projects --id=my_project_dev --token=xyz
Then, you can see paremeters.yml, conditions.yml, config.json, etag
files in projects/my_project_dev
directory.
If you don't specify --prefix
, then the command create the files in the working directory
Environment variables
Some variables can be injected by environment variables.
export REMOCON_FIREBASE_PROJECT_ID=<--id>
export REMOCON_FIREBASE_ACCESS_TOKEN=<--token>
export REMOCON_PREFIX=<--prefix> # Optional
FIREBASE_PROJECT_ID and REMOTE_CONFIG_ACCESS_TOKEN are supported but they are deprecated now
Condition definitions and parameter definitions are separated. You need to modify these files.
parameters.yml
key1: # key name
value: 100 # default value
conditions:
condition1:
value: 200 # a value to be used if condition1 is satisfied
condition2:
file: path_to_file # you can use file content. the file content is used for a value
conditions.yml
- name: condition1 # condition name
expression: device.os == 'android' # expression
tagColor: "INDIGO" # color name
- name: condition2
expression: device.os == 'ios'
tagColor: CYAN
# Create new configs as projects/my_project_dev/config.json
bundle exec remocon create --prefix=projects --id=my_project_dev
# Upload projects/my_project_dev/config.json by using projects/my_project_dev/etag
bundle exec remocon push --prefix=projects --id=my_project_dev --token=xyz
# You can use custom paths for config.json and etag
bundle exec remocon push --source=</path/to/config json> --etag=</path/to/etag>
# Use the fixed etag value
bundle exec remocon push --raw_etag=<raw etag value>
gem 'remocon'
You can use String, Boolean, Integer, Json validators like below.
key:
value: # optional (either of this or file is required). Raw value and hash are allowed.
file: # optional (either of this or value is required). File content value.
normalizer: # optional. Either of ["integer", "string", "boolean", "json", "void"] (default: void).
conditions: # optional. If you want use conditional values, then you need to create this section.
condition_name: # must be in condition definitions.
value: ...
file: ...
It seems only three fields are supported by Remote Config. They are name, expression and tagColor.
Not EOL versions. ref https://www.ruby-lang.org/en/downloads/branches/
Bug reports and pull requests are welcome on GitHub at https://github.com/jmatsu/remocon .
The gem is available as open source under the terms of the MIT License.
FAQs
Unknown package
We found that remocon 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.
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.