Contents
-
Born 1946, New York
-
Listened to his Grandma's childhood -- Eastern Europe
-
Folk Tale (Changes slightly as passed down)
-
The Oxcart is a Cautionary Folktale
Story takes place in Japan with strict rules for different levels of social status.
- Assurred
- Certain
- Unforseen
- Unknown and sudden
- Stricken
- Suddenly affected
- Outskirts
- Away from something
- Direct Characterization
- Narrator states character quality
- Indirect Characterization
- Narrator doesn't states the character quality
- Shrine
- Box for important things
- Samuria
- Japanese elite soldiers
- Lady-in-waiting
- A noblewoman who was a servant to another powerful woman (queen).
- Escort
- Travelling to give protection
- Plague
- Infectious deadly disease
-
Three Samurai want to go to an event.
-
They decided to ride on an Oxcart
-
The Oxcart was not comfortable and they threw up before they reached the event.
-
None of them touched the Oxcart again.
-
Walking to the City, Riding a Horse, and Going the Oxcart.
-
The towns were small and local, almost everyone in the town knew each other.
-
I think that it's very funny. A samurai is supposed to be tough, and unbreakable. These Samurai fought countless of soliders, sometimes with bare hands, yet they succumb to an Oxcart.
-
All of them were willing to cut corners to do something.
-
If they had been discovered, they would've been stripped of their samurai status and faced servere punishment. However, this time the samurai received sickness from the road bumps as their punishment.
-
It taught them that they shouldn't try to cut corners and break rules.


Quinn Dong-Kilkenny
Contact
Portfolio
About
(current)
Contact
First Name
Last Name
Email
Question or Comment
Subscribe?
Submit


--- layout: page title: About header-img: "img/about-bg.png" ---
A software engineer. Based in Houston. Looking forward to hearing from you!


frontend-boilerplate header, found in src/templates/partials/header.nunjucks
Hello World
index page can be found in app/pages/index.nunjucks


Release Notes Knopflerfish 2.0.4
The Release Notes are included in the KF distributions.
Release Notes Knopflerfish 2.0.4
--------------------------------
Maintenance release of Knopflerfish
Here follows a breakdown of the most important changes.
=== Framework (Core) ===
Added system property
org.knopflerfish.framework.system.export.all
If set to true the system bundle will export all standard packages
provided by the JRE. The files packages.txt specifying the set
of packages to export for JRE . have been moved inside
framework.jar to simplify embedding. A file named packages.txt
in the current working directory will override the embedded file
with the same name.
Added system property
org.knopflerfish.framework.system.export.all_16
and a packages1.6.txt file. If this property is set to true the
system bundle will export all standard packages provided by a
Java SE 6 JRE.
Added system property
org.knopflerfish.framework.debug.service_reference
If set when security is enabled, print information about service
reference lookups that are rejected due to missing permissions for
calling bundle.
Added system property
org.knopflerfish.framework.debug.bundle_resource
If set when security is enabled, the framework will print
information about resource lookups that are rejected due to missing
permissions for the calling bundle.
Fixed a bug related to bundle class paths pointing to a directory
inside the bundle jar file.
The manifest of the system bundle now contains the
Bundle-SymbolicName header. SourceForge issue tracker id [1866116].
Fix of issue [1516267] in SourceForge issue tracker.
Bundle URLConnection.getPermission() now returns AdminPermission.
Added system property for debugging
org.knopflerfish.framework.debug.bundle_resource
if set to true all resource loading operations that fails due to
missing permissions will be logged to System.out.
The security policy used by the framework now delegates to the
default policy for non-bundle security domains. I.e., permissions
for non-bundle domains may be defined using a policy file.
=== Services (Compendium) ===
=== Misc (KF specific, start scritps, build system etc ===
Start of the Framework
The command line option "--xargs " was added. Loads the
named file like "-xargs " if the file can be found, but does
not abort startup of the framework if the file cannot be read.
ExecutableBundleActivator
A new knopflerfish framework utility that makes wraps a native
application as a bundle. I.e. a native application can be included in
the bundle's jar file and commands on how to start, stop are
specified in the manifest through a set of manifest
headers. E.g. Bundle-Extract-Files, Bundle-Start-Executable,
Bundle-Stop-Executable. See the javadoc for the
org.knopflerfish.util.framework.ExecutableBundleActivator class for
a more detailed description
Consoletelnet
The telnet console implementation now handles a missing console
service by returning a message to the client saying that there is no
console service available. If the console service is stopped while
a telnet console session is active that session will be terminated
with a message saying that the console service have been terminated.
Build System
Building a distribution from the top level directory places all
output in the directory htdocs/releases/.
New items that that are placed here:
index.html file with links to all products, release note, test
results, etc.
Subdirectory with javadoc.
Test results form the KF internal test suite.
ChangeLog generated from subversion commits.
Nightly builds now uses a version number that complies to the OSGi
spec. Issue [1885598].


Glk uses a simple text-window model, which is easily implemented using the text display toolkits of most operating systems. It assumes that a text window is a single block of styled text. A story window is line-wrapped (with line breaks delimiting paragraphs); a status window is a given number of lines.
This model works well for the Z-machine -- until you run into the Z-machine quote-box trick.
Quote boxes were first used in Trinity. The technique was then imitated in Inform 5 (later 6) as the box
statement. The trick roughly looks like this:
In Infocom's (V4) interpreter, the effect was to print the reverse-video text overlaid on the top of the story window, below the (single-line) status bar. The text would then scroll away as part of the story window's natural scrolling, over the next few command inputs.
In a naive Glk implementation -- or any simple implementation using text windows -- this trick fails. The interpreter will display the quote text for a tiny fraction of a second, or (if the display system has built-in buffering) not at all.
To work around this, our Z-machine interpreter must use a counter-trick. The strategy is to not decrease the window size when the Z-machine requests it. Instead, we leave the window open (ten lines, in the example) while accepting line input. At the following input event, we assume that the player has read the text, and collapse the window back to its "correct" size.
To do this, we must maintain some extra state variables. Here is the appropriate algorithm, in pseudocode:
var curheight = 0 # What the VM thinks the height is var maxheight = 0 # Height including possible quote box var seenheight = 0 # Last height the user saw # Set the window height. Called by the @split_window opcode. # Also called on @erase_window -1 (with an argument of zero). # May also be called by @set_cursor; see notes below. # function split_window(num_of_lines): var oldheight = curheight curheight = num_of_lines # We do not decrease the height at this time -- it can only # increase. if (curheight > maxheight) maxheight = curheight # However, if the VM thinks it's increasing the height, we must be # careful to clear the "newly created" space. if (curheight > oldheight) blank out all lines from oldheight to the bottom of the window set the true window height to maxheight # (If this adds new lines, they should start out blank) # If the status height is too large because of last turn's quote box, # shrink it down now. # This must be called immediately before any input event. (That is, # the beginning of the @read and @read_char opcodes.) # function resolve_status_height(): # If the player has seen the entire window, we can shrink it. if (seenheight == maxheight) maxheight = curheight set the true window height to maxheight seenheight = maxheight maxheight = curheight
It is wise to test one's interpreter with the following games. In all cases, the quote should disappear after one player input. (Whether this is a typed command or a "hit a key to continue" keystroke.)
Curses: Title screens / I / LOOK / HELP / Q
(The game begins with a quote; the first "inventory" command displays another. The "help" command brings up a traditional Inform menu, which allows you check that you haven't broken that feature.)
Anchorhead: Title screens / HELP / Q
(The game begins with two Lovecraft quotes.)
Trinity: NE / EXAMINE SUNDIAL / UNSCREW GNOMON / SW
(Examining the sundial displays a quote.)
The above code is taken from the Glk interface layer in the Fizmo interpreter. See glk_screen_if.c.
I have roughly equivalent code in my fork of Parchment ("zarfsite" branch; see textgrid.js). It differs in one way: the resolve_status_height
functionality appears at the end of the TextGrid.stream
method, which is called by the interpreter before input only if the status window was updated.
This is an insignificant change for Inform games, which update the status window every turn. However, Trinity is tidy and only updates the status window when necessary -- typically when you change locations. Therefore, when running Trinity in my Parchment interpreter, the sundial quote box sticks around until you leave the Wabe.
Both Fizmo and Parchment are careful about writing beyond the current window size. (That is, invoking @set_cursor
to move the cursor below the status window height.) In this case, they increase the window size (call split_window
, passing the cursor's line coordinate). I suspect this hack is necessary to support existing Z-code games. However, I can't name specific games that require it.
Inform 6 supports the box
statement when compiling to Glulx, but it does not use anything like the Z-machine's trick. Instead, it opens a third text window and keeps it open until the following input. This is all done in VM code, and does not require any interpreter support.


Please select a game session to join
Make sure it is the same session as your friends!
{% for game in games %}
{{ game }}
{% endfor %}
Play!


Conce Conce Conce Conce Conce Conce Conce
Conce Conce Conce Conce Conce Conce Conce
Conce Conce Conce Conce Conce Conce Conce
Conce Conce Conce Conce Conce Conce Conce
Conce Conce Conce Conce Conce Conce Conce
Conce Conce Conce Conce Conce Conce Conce
Conce Conce Conce Conce Conce Conce Conce
- Sunfish
-
Fruits
- Orange
- Apple
- Banana
- Mango
- Pear
- Ozark bass
- White crappie


|
EmbeddedAi
|
#include <factor.h>
#include <Factories.h>
#include <json/json.h>
#include <fstream>
#include <gtest/gtest.h>
Functions | |
| int | Test1_1 () |
| int | Test_DeepCopy () |
| int | Test1_3 () |
| int | Test_JsonFactor () |
| int | TestRain () |
| int | TestRain2 () |
| int | TestCircuit1 () |
| int | TestCircuit2 () |
| int | TestJson () |
| Create FactorSet and run specified high level EmbeddedAI command. | |
| int | LargeTest1 () |
| int | LargeTest2 () |
| int | DecisionTest1 () |
| int | IspTest1 () |
| int | IspTest2 () |
| int | IspDecisionExample () |
| TEST (BASIC, TEST1_1) | |
| TEST (BASIC, Test_DeepCopy) | |
| TEST (BASIC, Test1_3) | |
| TEST (BASIC, Test_JsonFactor) | |
| TEST (BASIC, TestRain) | |
| TEST (BASIC, TestRain2) | |
| TEST (BASIC, TestCircuit1) | |
| TEST (BASIC, TestCircuit2) | |
| TEST (BASIC, TestJson) | |
| TEST (BASIC, DecisionTest1) | |
| TEST (BASIC, LargeTest1) | |
| TEST (BASIC, LargeTest2) | |
| TEST (EXAMPLE, IspTest1) | |
| TEST (EXAMPLE, IspTest2) | |
| TEST (EXAMPLE, IspDecisionExample) | |
| int | main (int argc, char **argv) |
| int DecisionTest1 | ( | ) |
Build decision matrix and calculate two consequtive decisions
Two different situations are analyzed:
| int IspDecisionExample | ( | ) |
Calculate decision Matrix for SendCrew decision based on visible variables. Calculate SendCrew value forsample
| int IspTest1 | ( | ) |
Inject sample with
Find a combination of all variables that most likely explains this sample
Repeat same test with
| int IspTest2 | ( | ) |
Inject sample with
| int LargeTest1 | ( | ) |
Evaluate information about packet drops on on certain segents of network infer most likely congested segments on the network
| int LargeTest2 | ( | ) |
Same test as LargeTest1() but performs algorithm optimization that dramatically reduces duration of calculations
| int Test_DeepCopy | ( | ) |
Validate deep copy of FactorSet
the copy of FactorSet is done when multiple queries Needs to be run against the same set of data
Note that
| int Test_JsonFactor | ( | ) |
Test construction of Factor tables from Json
| int TestCircuit1 | ( | ) |
Apply input J=1 to the circuit. Input I is unknown. Measured output O is 0. Find most likely combination of variables in the model
| int TestCircuit2 | ( | ) |
Inputs I and J are unknown. Measured output O is 1. Find most likely combination of Inputs I and J
| int TestRain | ( | ) |
This test observes
| int TestRain2 | ( | ) |
This test is same as in TestRain1() except PruneEdges optimization is invoked


NOTE: It is strongly advised to use HTTPS for requests between a security server and the associated external operational monitoring daemon.
For running a separate operational monitoring daemon, the xroad-opmonitor package must be installed. Please refer to [IG-SS] for general instructions on obtaining X-Road packages.
As a result of installation, the following services will be running:
xroad-confclient
xroad-signer
xroad-opmonitor
15.2.5 Configuring an External Operational Monitoring Daemon and the Corresponding Security Server
To make a security server communicate with an external operational monitoring daemon, it is necessary to configure both the daemon and the security server.
By default, the operational monitoring daemon listens on localhost. To make the daemon available to security servers on other hosts, the listening address must be set to the IP address that is relevant in the particular network, as described in the previous section.
As advised, the scheme parameter should be set to "https". For communication over HTTPS, the security server and the operational monitoring daemon must know each other's TLS certificates to enable the security server to authenticate to the monitoring daemon successfully.
NOTE: If an external operational monitoring daemon is used, the host, scheme (and optionally, port) parameters must be changed at both hosts.
The internal TLS certificate of the security server is used for authenticating the security server to the operational monitoring daemon. This certificate has been generated beforehand, during the installation process of the security server, and is available in PEM format in the file /etc/xroad/ssl/internal.crt
. Please refer to Section 10.3 for the instructions on exporting the internal TLS certificate from UI. The file must be copied to the host running the operational monitoring daemon. The system user xroad must have permissions to read this file.
In the configuration of the external daemon, the corresponding path must be set in /etc/xroad/conf.d/local.ini
:
[op-monitor]
client-tls-certificate = <path/to/security/server/internal/cert>
Next, a TLS key and the corresponding certificate must be generated on the host of the external monitoring daemon as well, using the command
generate-opmonitor-certificate
The script will prompt you for standard fields for input to TLS certificates and its output (key files and the certificate) will be generated to the directory /etc/xroad/ssl
.
The generated certificate, in the file opmonitor.crt
, must be copied to the corresponding security server. The system user xroad
must have permissions to read this file. Its path at the security server must be written to the configuration (note the name of the section, although it is the proxy service that will read the configuration):
[op-monitor]
tls-certificate = <path/to/external/daemon/tls/cert>
For the external operational daemon to be used, the proxy service at the security server must be restarted:
service xroad-proxy restart
In addition, on the host running the corresponding security server, the operational monitoring daemon must be stopped:
service xroad-opmonitor stop
For the service to stay stopped after reboot the following command should be run:
echo manual > /etc/init/xroad-opmonitor.override
The configuration anchor (renamed as configuration-anchor.xml
) file must be manually copied into the directory /etc/xroad
of the external monitoring daemon in order for configuration client to be able to download the global configuration (by default configuration download interval is 60 seconds). The system user xroad must have permissions to read this file.
15.2.6 Monitoring Health Data over JMXMP
The operational monitoring daemon makes health data available over the JMXMP protocol. The Zabbix monitoring software can be configured to gather that data periodically, using its built in JMX interface type.
By default, the operational monitoring daemon JMXMP is disabled. JMXMP must be enabled for external tools such as Zabbix to be able to access the data. Please refer to the documentation at [JMX] for instructions on configuring access to the JMX interface of the operational monitoring daemon.
For Zabbix to be able to gather data over JMX, the Zabbix Java gateway must be installed. See [ZABBIX-GATEWAY] for instructions.
The JMX interface must be configured to each host item in Zabbix, for which health data needs to be obtained. See [ZABBIX-JMX] for instructions.
Please refer to [PR-OPMONJMX] for a specification of the names and attributes of the JMX objects exposed by the operational monitoring daemon.
The xroad-opmonitor package comes with sample host data that can be imported to Zabbix, containing a JMX interface, applications related to sample services and health data items under these services. Also, a script is provided for importing health data related applications and items to several hosts using the Zabbix API. Please find the example files in the directory /usr/share/doc/xroad-opmonitor/examples/zabbix/
. Please refer to [ZABBIX-API] for information on the Zabbix API.
16 Environmental Monitoring
Environmental monitoring provides details of the security servers such as operating system, memory, disk space, CPU load, running processes and installed packages, etc.
16.1 Usage via SOAP API
Environmental monitoring provides SOAP API via X-Road message protocol extension. SOAP messages are described in [PR-ENVMONMES].
Monitoring extension schema is defined in [MONITORING_XSD].
16.2 Usage via JMX API
Environmental monitoring provides also a standard JMX endpoint which can be accessed with any JMX client (for example Java's jconsole application). See [ARC-ENVMON] for details.
JMX is disabled on default. JMX is enabled by adding standard JMX-related options to the executable java process as in example by [ZABBIX-JMX].
16.3 Limiting environmental monitoring remote data set
It is possibility to limit what allowed non-owners can request via environmental monotiring data request by changing monitor-env limit-remote-data-set parameter. By changing flag to be true non-owners who are allowed to query environmental monitoring data will get only certificate, operating system and xroad version information. This parameters is set by default false. Security server owner will always get full data set as requested.
17 Logs and System Services
To read logs, a user must have root user's rights or belong to the xroad
and/or adm
system group.
17.1 System Services
The most important system services of a security server are as follows.
| Service | Purpose | Log |
|---|---|---|
xroad-addon-messagelog |
Message log archiving and cleaning of the message logs | /var/log/xroad/messagelog-archiver.log |
xroad-confclient |
Client process for the global configuration distributor | /var/log/xroad/configuration_client.log |
xroad-proxy |
Message exchanger | /var/log/xroad/proxy.log |
xroad-signer |
Manager process for key settings | /var/log/xroad/signer.log |
xroad-proxy-ui-api |
Management UI and REST API |
/var/log/xroad/proxy_ui_api.log and /var/log/xroad/proxy_ui_api_access.log
|
xroad-monitor |
Environmental monitoring | /var/log/xroad/monitor.log |
xroad-opmonitor |
Operational monitoring | /var/log/xroad/op-monitor.log |
System services are managed through the systemd facility.
To start a service, issue the following command as a root
user:
service <service> start
To stop a service, enter:
service <service> stop
Services use the default unit start rate limits.
An exception to this is xroad-proxy-ui-api
, which uses a longer start rate limit (5 starts / 40 seconds)
to prevent infinite restart-loop in some specific error situations.
17.2 Logging configuration
For logging, the Logback system is used. Logback configuration files are stored in the directory /etc/xroad/conf.d/
.
Default settings for logging are the following:
-
logging level: INFO;
-
rolling policy: whenever the file size reaches 100 MB.
17.3 Fault Detail UUID
In case a security server encounters an error condition during the message exchange, the security server returns a SOAP Fault message [PR-MESS] containing a UUID (a universally unique identifier, e.g. 1328e974-4fe5-412c-a4c4-f1ac36f20b14
) as the fault detail to the service client's information system. The UUID can be used to find the details of the occurred error from the xroad-proxy
log.
18 Federation
Federation allows security servers of two different X-Road instances to exchange messages with each other. The instances are federated at the central server level. After this, security servers can be configured to opt-in to the federation. By default, federation is disabled and configuration data for other X-Road instances will not be downloaded.
The federation can be allowed for all X-Road instances that the central server offers, or a list of specific (comma-separated) instances. The default is to allow none. The values are case-insensitive.
To override the default value, edit the file /etc/xroad/conf.d/local.ini
and add or change the value of the system
parameter allowed-federations
for the server component configuration-client
. To restore the default, either remove
the system parameter entirely or set the value to none
. X-Road services xroad-confclient
and xroad-proxy
need to
be restarted (in that order) for any setting changes to take effect.
Below are some examples for /etc/xroad/conf.d/local.ini
.
To allow federation with all offered X-Road instances:
[configuration-client]
allowed-federations=all
To allow federation with specific instances xe-test
and ee-test
:
[configuration-client]
allowed-federations=xe-test,ee-test
To disable federation, just remove the allowed-federations
system parameter entirely or use:
[configuration-client]
allowed-federations=none
Please note that if the keyword all
is present in the comma-separated list, it will override the single allowed
instances. The keyword none
will override all other values. This means that the following setting will allow all
federations:
[configuration-client]
allowed-federations=xe-test, all, ee-test
And the following will allow none:
[configuration-client]
allowed-federations=xe-test, all, none, ee-test
19 Management REST API
Security server has a REST API that can be used to do all the same server configuration operations that can be done using the web UI.
Management REST API is protected with an API key based authentication. To execute REST calls, API keys need to be created.
REST API is protected by TLS. Since server uses self signed certificate, the caller needs to accept this (for example
with curl
you might use --insecure
or -k
option).
Requests sent to REST API have a limit for maximum size. If a too large request is sent to REST API, it will not be processed, and http status 413 Payload too large will be returned. There is a different limit for binary file uploads, and for other requests.
Limits are
- 10MB for file uploads
- 50KB for other requests
REST API is also rate limited. Rate limits apply per each calling IP. If the number of calls from one IP address exceeds the limit, endpoints return http status 429 Too Many Requests.
Limits are
- 600 requests per minute
- 20 requests per second
If the default limits are too restricting (or too loose), they can be overridden with command line arguments. Limits are set with application properties
request.sizelimit.regular
request.sizelimit.binary.upload
ratelimit.requests.per.second
ratelimit.requests.per.minute
Note: These properties have been deprecated since 7.3.0, please use request-sizelimit-*
& rate-limit-requests-per-*
proxy-ui-api parameters instead
Size limit parameters support formats from Formats from DataSize,
for example 5MB
.
New command line arguments can be added, not replaced, using the configuration file local.properties
.
Example of /etc/xroad/services/local.properties
with modifications:
XROAD_PROXY_UI_API_PARAMS=-Dratelimit.requests.per.second=100 -Drequest.sizelimit.binary.upload=1MB
19.1 API key management operations
Access rights: System Administrator
An API key is linked to a role or roles, and grants access to the operations that are allowed for that role/roles. Separate REST endpoints exist for API key management. API key management endpoints are authenticated to with HTTP basic authentication (username and password) or with session authentication (for admin web application). Basic authentication access is limited to localhost by default, but this can be changed using System Parameters [UG-SYSPAR].
19.1.1 Creating new API keys
A new API key is created with a POST
request to /api/v1/api-keys
. Message body must contain the roles to be
associated with the key. Server responds with data that contains the actual API key. After this point the key
cannot be retrieved, as it is not stored in plaintext.
curl -X POST -u <user>:<password> https://localhost:4000/api/v1/api-keys --data '["XROAD_SECURITYSERVER_OBSERVER","XROAD_REGISTRATION_OFFICER"]' --header "Content-Type: application/json" -k
{
"roles": [
"XROAD_REGISTRATION_OFFICER",
"XROAD_SECURITYSERVER_OBSERVER"
],
"id": 61,
"key": "23bc57cd-b1ba-4702-9657-8d53e335c843"
}
In this example the created key was 23bc57cd-b1ba-4702-9657-8d53e335c843
.
19.1.2 Listing API keys
Existing API keys can be listed with a GET
request to /api/v1/api-keys
. This lists all keys, regardless of who has created them.
curl -X GET -u <user>:<password> https://localhost:4000/api/v1/api-keys -k
[
{
"id": 59,
"roles": [
"XROAD_REGISTRATION_OFFICER",
"XROAD_SECURITYSERVER_OBSERVER",
"XROAD_SERVICE_ADMINISTRATOR"
]
},
{
"id": 60,
...
You can also retrieve a single API key with a GET
request to /api/v1/api-keys/{id}
.
curl -X GET -u <user>:<password> https://localhost:4000/api/v1/api-keys/59 -k
{
"id": 59,
"roles": [
"XROAD_REGISTRATION_OFFICER",
"XROAD_SECURITYSERVER_OBSERVER",
"XROAD_SERVICE_ADMINISTRATOR"
]
}
19.1.3 Updating API keys
An existing API key is updated with a PUT
request to /api/v1/api-keys/{id}
. Message body must contain the roles to be
associated with the key. Server responds with data that contains the key id and roles associated with the key.
curl -X PUT -u <user>:<password> https://localhost:4000/api/v1/api-keys/60 --data '["XROAD_SECURITYSERVER_OBSERVER","XROAD_REGISTRATION_OFFICER"]' --header "Content-Type: application/json" -k
{
"id": 60,
"roles": [
"XROAD_REGISTRATION_OFFICER",
"XROAD_SECURITYSERVER_OBSERVER"
]
}
19.1.4 Revoking API keys
An API key can be revoked with a DELETE
request to /api/v1/api-keys/{id}
. Server responds with HTTP 200
if
revocation was successful and HTTP 404
if key did not exist.
curl -X DELETE -u <user>:<password> https://localhost:4000/api/v1/api-keys/60 -k
19.1.5 API key caching
API keys are cached in memory, which is typically not a problem in standard Security Server configurations.
However, if you have multiple Security Servers configured to share the same serverconf
database
and use multiple nodes to access the REST API and execute API key management operations, the caches of different nodes can become out of sync.
For instance, revoking an API key from node 1
may not be recognized by node 2
, which can still grant access to REST API endpoints with the revoked API key. To address this issue, there are a few potential solutions:
- Option A: Consider decreasing time-to-live value for API key cache from the default of 60 seconds to a more lenient value. Doing so will reduce the risk of stale values being returned, thus improving security.
- Option B: Direct all REST API operations to the same Security Server node.
- Option C: Always restart REST API modules when API key operations are executed.
- Option D: Disable Api key cache. (See proxy-ui-api parameters for more details). This option will degrade API throughput and should only be used when other options do not work.
19.2 Executing REST calls
Access rights: Depends on the API.
Once a valid API key has been created, it is used by providing an Authorization: X-Road-ApiKey token=<api key>
HTTP
header in the REST calls. For example
curl --header "Authorization: X-Road-ApiKey token=ff6f55a8-cc63-4e83-aa4c-55f99dc77bbf" "https://localhost:4000/api/v1/clients" -k
[
{
"id": "XRD2:GOV:999:foobar",
"member_name": Foo Name,
"member_class": "GOV",
"member_code": "999",
"subsystem_code": "SUBS_1",
"status": "saved
...
The available APIs are documented in OpenAPI specification [REST_UI-API]. Access rights for different APIs follow the same rules as the corresponding UI operations. Access to regular APIs is allowed from all IP addresses by default, but this can be changed using System Parameters [UG-SYSPAR].
19.3 Correlation ID HTTP header
The REST API endpoints return an x-road-ui-correlation-id HTTP header. This header is also logged in proxy_ui_api.log
, so it
can be used to find the log messages related to a specific API call.
The correlation ID header is returned for all requests, both successful and failed ones.
For example, these log messages are related to an API call with correlation ID 3d5f193102435242
:
2019-08-26 13:16:23,611 [https-jsse-nio-4000-exec-10] correlation-id:[3d5f193102435242] DEBUG o.s.s.w.c.HttpSessionSecurityContextRepository - The HttpSession is currently null, and the HttpSessionSecurityContextRepository is prohibited from creating an HttpSession (because the allowSessionCreation property is false) - SecurityContext thus not stored for next request
2019-08-26 13:16:23,611 [https-jsse-nio-4000-exec-10] correlation-id:[3d5f193102435242] WARN o.s.w.s.m.m.a.ExceptionHandlerExceptionResolver - Resolved [org.niis.xroad.restapi.exceptions.ConflictException: local group with code koodi6 already added]
2019-08-26 13:16:23,611 [https-jsse-nio-4000-exec-10] correlation-id:[3d5f193102435242] DEBUG o.s.s.w.a.ExceptionTranslationFilter - Chain processed normally
19.4 Validation errors
An error response from the REST API can include validation errors if an unsupported parameter was provided with the request. When
Example request and response of adding a new subsystem with illegal characters:
POST https://ss1:4100/api/v1/clients
Request body:
{
"client": {
"member_class": "ORG",
"member_code": "0/1234",
"subsystem_code": "Subsystem%Code"
},
"ignore_warnings": false
}
Response body:
{
"error": {
"code": "validation_failure",
"validation_errors": {
"clientAdd.client.memberCode": [
"NoForwardslashes"
],
"clientAdd.client.subsystemCode": [
"NoPercents"
]
}
},
"status": 400
}
In addition to the validation messages declared in Java Validation API, the following validation errors are possible:
| Error | Explanation |
|---|---|
NoControlChars |
The provided string contains ISO control characters or zero-width spaces |
NoColons |
The provided string contains colons :
|
NoSemicolons |
The provided string contains semicolons ;
|
NoForwardslashes |
The provided string contains slashes /
|
NoBackslashes |
The provided string contains backslashes \
|
NoPercents |
The provided string contains percent symbol %
|
19.5 Warning responses
Error response from the Management API can include additional warnings that you can ignore if seen necessary. The warnings can be ignored by your decision, by executing the same operation with ignore_warnings
boolean parameter set to true
. Always consider the warning before making the decision to ignore it.
An example case:
- Client executes a REST request, without
ignore_warnings
parameter, to backend. - Backend notices warnings and responds with error message that contains the warnings. Nothing is updated at this point.
- Client determines if warnings can be ignored.
- If the warnings can be ignored, client resends the REST request, but with
ignore_warnings
parameter set totrue
. - Backend ignores the warnings and executes the operation.
Error response with warnings always contains the error code warnings_detected
.
Like errors, warnings contain an identifier (code) and possibly some metadata.
Warning example when trying to register a WSDL that produces non-fatal validation warnings:
{
"status": 400,
"error": {
"code": "warnings_detected"
},
"warnings": [
{
"code": "wsdl_validation_warnings",
"metadata": [
"WSDLValidator Error : Summary: Failures: 0, Warnings: 1 <<< WARNING! Operation 'someService' in PortType: {http://test.x-road.global/some-service}someService.servicePortType has no output message"
]
}
]
}
Note that when you are using the admin UI and you encounter warnings, you will always be provided with a popup window with a CONTINUE
button in it. When you click the CONTINUE
button in the popup, the request is sent again but this time warnings will be ignored.
20 Migrating to Remote Database Host
Since version 6.22.0
Security Server supports using remote databases. In case you have an already running Security Server with local database, it is possible to migrate it to use remote database host instead. The instructions for this process are listed below.
-
Shutdown X-Road processes.
systemctl stop "xroad*"
-
Dump the local databases to be migrated. You can find the passwords of users
serverconf_admin
,messagelog_admin
andopmonitor_admin
in/etc/xroad.properties
.Notice that the versions of the local PostgreSQL client and remote PostgreSQL server must match. Also take into account that on a busy system the messagelog database can be quite large and therefore dump and restore can take considerable amount of time and disk space. Notice that the versions of the local PostgreSQL client and remote PostgreSQL server must match.  Again, the database and role names can be customized to suit your environment.
psql -h <remote-db-url> -p <remote-db-port> -U postgres CREATE DATABASE "op-monitor" ENCODING 'UTF8'; REVOKE ALL ON DATABASE "op-monitor" FROM PUBLIC; CREATE ROLE opmonitor_admin LOGIN PASSWORD '<opmonitor_admin password>'; GRANT opmonitor_admin to <superuser>; GRANT CREATE,TEMPORARY,CONNECT ON DATABASE "op-monitor" TO opmonitor_admin; \c "op-monitor" CREATE SCHEMA opmonitor AUTHORIZATION opmonitor_admin; REVOKE ALL ON SCHEMA public FROM PUBLIC; GRANT USAGE ON SCHEMA public to opmonitor_admin; CREATE ROLE opmonitor LOGIN PASSWORD '<opmonitor password>'; GRANT opmonitor to <superuser>; GRANT TEMPORARY,CONNECT ON DATABASE "op-monitor" TO opmonitor; GRANT USAGE ON SCHEMA public to opmonitor; GRANT USAGE ON SCHEMA opmonitor TO opmonitor; GRANT SELECT,UPDATE,INSERT,DELETE ON ALL TABLES IN SCHEMA opmonitor TO opmonitor; GRANT SELECT,UPDATE ON ALL SEQUENCES IN SCHEMA opmonitor TO opmonitor; GRANT EXECUTE ON ALL FUNCTIONS IN SCHEMA opmonitor to opmonitor;
-
Restore the database dumps on the remote database host.
pg_restore -h <remote-db-url> -p <remote-db-port> -U serverconf_admin -O -n serverconf -1 -d serverconf serverconf.dat pg_restore -h <remote-db-url> -p <remote-db-port> -U messagelog_admin -O -n messagelog -1 -d messagelog messagelog.dat pg_restore -h <remote-db-url> -p <remote-db-port> -U opmonitor_admin -O -n opmonitor -1 -d op-monitor op-monitor.dat
-
Create properties file
/etc/xroad.properties
containing the superuser password.sudo touch /etc/xroad.properties sudo chown root:root /etc/xroad.properties sudo chmod 600 /etc/xroad.properties
-
Edit
/etc/xroad.properties
.serverconf.database.admin_user = serverconf_admin serverconf.database.admin_password = <serverconf_admin password> messagelog.database.admin_user = messagelog_admin messagelog.database.admin_password = messagelog_admin password> op-monitor.database.admin_user = opmonitor_admin op-monitor.database.admin_password = <opmonitor_admin password>
-
Update
/etc/xroad/db.properties
contents with correct database host URLs and passwords.serverconf.hibernate.connection.url = jdbc:postgresql://<database host>:<port>/serverconf serverconf.hibernate.connection.username = serverconf serverconf.hibernate.connection.password = <serverconf password> serverconf.hibernate.hikari.dataSource.currentSchema = serverconf,public messagelog.hibernate.connection.url = jdbc:postgresql://<database host>:<port>/messagelog messagelog.hibernate.connection.username = messagelog messagelog.hibernate.connection.password = <messagelog password> messagelog.hibernate.hikari.dataSource.currentSchema = messagelog,public op-monitor.hibernate.connection.url = jdbc:postgresql://<database host>:<port>/op-monitor op-monitor.hibernate.connection.username = opmonitor op-monitor.hibernate.connection.password = <opmonitor password> op-monitor.hibernate.hikari.dataSource.currentSchema = opmonitor,public
-
Start again the X-Road services.
systemctl start "xroad*"
21 Adding command line arguments
If you need to add command line arguments for the Security Server, for example if you wish to increase Java's maximum heap size, you can do it with the properties file /etc/xroad/services/local.properties
. The file is also included in the backup archive file when taking a backup of the Security Server's configuration.
Example of /etc/xroad/services/local.properties
with modifications that override the default Java memory parameters:
XROAD_PROXY_PARAMS=-Xms150m -Xmx1024m
All possible properties to adjust in this file are:
XROAD_SIGNER_PARAMS
XROAD_ADDON_PARAMS
XROAD_CONFCLIENT_PARAMS
XROAD_CONFPROXY_PARAMS
XROAD_JETTY_PARAMS
XROAD_MESSAGELOG_ARCHIVER_PARAMS
XROAD_MONITOR_PARAMS
XROAD_OPMON_PARAMS
XROAD_PROXY_PARAMS
XROAD_PROXY_UI_API_PARAMS
XROAD_SIGNER_CONSOLE_PARAMS
22 Additional Security Hardening
You may want to harden the security of your X-Road instance by configuring additional security policies in your Security Servers. The security measures that are introduced in this guide are common security policies that can be configured on operating system level.
X-Road uses the Linux Pluggable Authentication Modules (PAM) to authenticate users. This makes it easy to configure the account management to your liking. The example PAM configurations provided in this guide may or may not work on your system depending on your system and existing PAM configurations. Note that editing the PAM configurations will take effect immediately without the need to restart anything.
For configuring the following security policies for the X-Road Security Server Admin UI in production, please refer to The Linux-PAM System Administrator's Guide for the full documentation on how to configure PAM.
22.1 Configuring account lockout
Configuring an account lockout policy in your Security Server Admin UI authentication will provide an extra layer of defence against password guessing attacks, such as brute force attacks. After configuring the account lockout, when trying to log in to the Security Server Admin UI with a locked account, the login screen will display a generic login error without disclosing the reason or any other login information.
The PAM service to configure the account lockout to is xroad
.
22.1.1 Considerations and risks
After enabling the account lockout for the Security Server, you should be aware that a user can lock out any other user's account if they know the correct username.
22.1.2 Account lockout examples
The example configurations will lock the user's account, preventing login to the Security Server Admin UI for 15 minutes (I.e. 900 seconds) after they provide a wrong password in the Security Server Admin UI login three (3) consecutive times. This configuration also affects the root account.
Example on Ubuntu
Create a new configuration /etc/pam.d/xroad
with the following content:
auth required pam_tally2.so deny=3 even_deny_root unlock_time=900 file=/var/lib/xroad/tallylog
@include common-auth
account required pam_tally2.so
@include common-account
password required pam_deny.so
session required pam_deny.so
Example on RHEL
On RHEL systems, the /etc/pam.d/xroad
file ships with the Security Server installation package so you need to modify the existing file. Replace the /etc/pam.d/xroad
contents with the following:
#%PAM-1.0
auth required pam_tally2.so deny=3 even_deny_root unlock_time=900 file=/var/lib/xroad/tallylog
auth required pam_unix.so
account required pam_tally2.so
account required pam_unix.so
password required pam_deny.so
password required pam_warn.so
session required pam_deny.so
22.2 Configuring password policies
Configuring a password policy in your Security Server Admin UI authentication will provide an additional layer of defence against password guessing attacks, such as password spraying.
User account passwords cannot be changed directly from the Security Server Admin UI, therefore the password policy must be configured on operating system user account level. The method of adding a new password policy varies significantly depending on your operating system, existing PAM configuration and authentication protocol.
For instruction on how to add password policies, please refer to your operating system's official documentation or customer support.
22.2.1 Considerations and risks
In a strong password, it is advisable to have at least 16 characters at minimum. You can also add complexity requirements, such as numbers and special characters, but these requirements can make the passwords more difficult for users to remember. Further additional measures could be to add commonly known passwords into a blocklist.
22.3 Ensuring User Account Security
Users of the web application are created by creating operating-system-level users. This means that a user can access the web application and the underlying operating system with the same credentials. Therefore, if user accounts in the web application were compromised, the attacker could use those credentials to log into the server via SSH if credential-based logging in is not disabled.
To harden the user account security, make sure that users are not allowed to access the server via SSH by default. The users needing SSH access are granted those rights separately.
Create a user group in which users are allowed to connect to the server via SSH while all other users are denied. Add the following line to /etc/ssh/sshd_config
:
AllowGroups <group_to_allow>
Restart the SSH service:
sudo systemctl restart sshd
It is also recommended to disable SSH password login and allow key-based authentication only. Before this modification, add users' public keys to the server. Edit /etc/ssh/sshd_config
and add the following lines:
ChallengeResponseAuthentication no
PasswordAuthentication no
Restart the SSH service once again:
sudo systemctl restart sshd
In addition, the users should be prevented from logging in to the system. This can be achieved by issuing the following command on Ubuntu:
usermod -s /bin/false user
On RHEL, the corresponding command is:
usermod -s /sbin/nologin user
The system administrator should also implement a monitoring and alerting system regarding anomalous logins.


new XMPPVideoRoom(xmppUrl, srvurl)
Interface with Jitsi Video Room and WebRTC-streamer API
Parameters:
| Name | Type | Description |
|---|---|---|
xmppUrl |
string | url of XMPP server |
srvurl |
string | url of WebRTC-streamer |
- Source:
Methods
join(roomid, url, name)
Ask to publish a stream from WebRTC-streamer in a XMPP Video Room user
Parameters:
| Name | Type | Description |
|---|---|---|
roomid |
string | id of the XMPP Video Room to join |
url |
string | WebRTC stream to publish |
name |
string | name in Video Room |
- Source:
leave(roomid, name)
Ask to leave a XMPP Video Room user
Parameters:
| Name | Type | Description |
|---|---|---|
roomid |
string | id of the XMPP Video Room to leave |
name |
string | name in Video Room |
- Source:
leaveAll()
Ask to leave all XMPP Video Room
- Source:


Dwaine is in Wilma's Room
“I“Hi Wilma, new evidence hints at a crime of passion. Do you have any idea of a grudge anyone may have had against Alex.”
“I honestly don’t. I know that he and Jane had some history but again he and I did too. I think Harry may have been pressuring a bit on the cowboy boots business, but that is typical Harry and his hare-brained schemes, you know how he is. Harry is Alex’s best friend I can’t imagine he could ever do something like this.”
“Well, you never know what people are capable of when their backs are to the wall. The one thing we know is that someone was capable of it.”


Barnhouse V / Wenink Holtkamp Architecten
- Curated by María Francisca González
- 3 days
Houses · Boxtel, The Netherlands
- version="1.0" encoding="UTF-8"? Architects: Wenink Holtkamp Architecten
- AreaArea of this architecture projectArea: 160.0 m2
- version="1.0" encoding="UTF-8"?YearCompletion year of this architecture project Year: 2019
- version="1.0" encoding="UTF-8"?PhotographsPhotographs: Tim van de Velde
- version="1.0" encoding="UTF-8"?ManufacturersBrands with products used in this architecture project Manufacturers: Aluk, Cape Cod, Duco slide, Sab Profiel
- Other Participants TNEA Engineering & Advies; Archimedes Bouwadvies
More Specs Less Specs
Text description provided by the architects. The inspiration for the design of the barnhouse developed largely through analyses of the rural context of the site. The building plot is located approximately 30 meters from the main road. This results in the house being part of the backside area of the site, surrounded mainly by sheds and barns amidst a wide-open landscape, and not the traditional ribbon development adjacent to the road. The barn house relates directly to its surroundings in terms of color, shape, and materialization. The black wooden cladding is partly derived from the traditional wooden barns in the area, which are mostly clad in black wooden slats. The corrugated steel roof relates to the more recent barns, which are often fully clad with corrugated steel.
The combination of these two materials, executed completely in black, makes the house stand out as a clear entity in the midst of the green landscape. The relationship with the archetypical barn also becomes apparent in the design of the sun blinds, which are based on the story high sliding doors seen in most traditional farmers' barns. The result is a variety of textures gradually exposing themselves upon approaching the building. The vertical wooden slats, the horizontal louvers of the sun blinds and the waves of the anthracite steel corrugated sheets are designed within the same color palette, but due to the variation of texture and orientation, sunlight is absorbed or reflected in many different ways.
The experience of the site with its distinct dimensions (relatively narrow in combination with a much greater depth) is an important starting point in the design. The positioning of the house on the plot creates three different scenic experiences that are all visible from the interior of the house and were instrumental in the design of the building's layout. Namely, the open connection to the access road (the village) at the front; the more intimate and enclosed experience on the west side of the plot and the complete openness of the field and the orchard at the rear of the barnhouse.
The floorplans are set up on the basis of a long view line running parallel to the longitudinal axis of the site. In the interior, the entire depth of the plot can be experienced on this axis. The axis also functions as a connecting element of all the most important living spaces: the kitchen, living room and the master bedroom. The west side of the house has a more intimate character, due to the narrowness of the plot and its enclosure by a tall beech hedge. On this side of the house, a covered indoor terrace is situated that connects directly to the adjacent kitchen. By creating an indoor garage it was possible to maintain the barnhouse as archetypical as possible, without any outbuildings invalidating its typology.
The house is designed to be life-cycle resistant, with a complete living program on the ground floor. On the first floor, there are two bedrooms with an ensuit bathroom, storage space, and a workspace. The big voids above the staircase and the kitchen allow the morning light, that comes in through the skylights in the east elevation, to enter all the way into the heart of the house. The voids give the house a spatial experience, with views all the way up into the roof, which is characteristic of the archetypical barn experience.


Introduction to Version Control, Git, and GitHub
What are the benefits of version control? Well, version control is definitely helpful for keeping track of your own files, as well as when you are working on the same files with other people. So instead of sending a project back and forth to work on it remotely, we can all work on the same files at the same time without overwriting anything. It keeps track of your files and remembers any and all changes made to them, including who made them, and when. This is very helpful if you realize you've messed up your code and need to go back to a certain point and work from there. Version control is also great because it allows developers to share their projects with each other without affecting the original version.
How does git help you keep track of changes? Git is an open-source version control system that allows developers to track changes made on their code files throughout the lifetime of a project. Git lets you create a "branch" where you work on some of the files without it affecting the base code or "trunk" until you are sure it is ready to be merged with the rest of the "tree". Whenever you want to "save" what you've done so far, you bundle up all of your changes into something called a commit. These are the "save check-points" that allow you to track your changes and go back to earlier versions of the project. A great part about Git is that it encourages developers to be experimental since you get to make changes locally and don't have to push to a centralized repository until you are ready.
Why use GitHub to store your code? GitHub is a social coding website that allows developers to share their code, as well as keep track of changes to their work using Git. So by storing your code on GitHub, it is easily accessible to share with others, whether you want someone to review your work, contribute to projects, or you and 100 other people are working on a collaborative project. Or maybe another developer who is stuck somewhere in their coding might be able to learn or benefit from code that I've already written, or I might be the one who needs help! One of the best reasons to use GitHub to store your code is that since you're not "messing" with the master version of a file, you can be experimental and try different things before commiting a file. GitHub is so beneficial for developers to back-up, share, and track their work with other coders!
Next


Kaile Zanryana A. Maliones
<EMAIL_ADDRESS>Full Name: Kaile Zanryana A. Maliones
Current age: 19
Date of Birth: January 26, 1998
Place of Birth: Baguio city
Address: Km 4 La Trinidad Benguet
Languages: C#, JavaScript, Python, Ruby
Frameworks: .NET, Node.js, Django, Ruby on Rails
Elementary: Shekinah Educational Center
High School: H.O.P.E Christian Academy Inc.
College:


Open the details.
- by Refsnes Data. All Rights Reserved.
All content and graphics on this web site are the property of the company Refsnes Data.
Note: The details element and the ontoggle attribute is currently only supported in Chrome, Safari 6+, and Opera 15+.


new Food(opts)
Class for Food, i.e fruits, vegetables, berries and other.
Parameters:
| Name | Type | Description | ||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|
opts |
object | Options
Properties
|
Methods
dish()
Get a random dish for current locale.
drink()
Get a random alcoholic drink.
fruit()
Get a random name of fruit or berry .
spices()
Get a random spices or herbs.
vegetable()
Get a random vegetable.


Preparation time
less than 30 mins
Cooking time
10 to 30 mins
Serves
Serves 4
Yunnan province in southwest China borders on southeast Asia, and I discovered to my joy how similar some of the dishes were to Thai cuisine. This dish combines fruit with a savoury mixture. It’s easy to make and makes a delicious change.
Allow the cooked rice to cool thoroughly by spreading it out on a baking sheet. The rice must be cold before you use it in this recipe.
Heat a wok over high heat until it is hot. Add the oil, and when it is very hot and slightly smoking, add the pork and stir fry for two minutes. Add the soy sauce, salt, pepper, ginger and spring onions and continue to stir-fry for two minutes.
Add the rice, mix well and stir fry the mixture for another five minutes until the rice is heated through and well mixed.
Stir in the sesame oil, add the pineapple pieces and stir fry until the pineapple is heated through, but not cooked. Serve at once.


[§428-1009] Action by attorney general. The attorney general may maintain an action to restrain a foreign limited liability company from transacting business in this State in violation of this part. [L 1996, c 92, pt of §1]


src/app/ui/wizard/scheduler.service.ts
Methods |
constructor(wizard: WizardService, map: MapService, location: LocationService, network: NetworkService, weather: WeatherService, demand: DemandService, simulation: SimulationService, clock: ClockService)
|
|||||||||||||||||||||||||||
|
Defined in src/app/ui/wizard/scheduler.service.ts:13
|
|||||||||||||||||||||||||||
|
Parameters :
|
| Public reset |
reset()
|
|
Defined in src/app/ui/wizard/scheduler.service.ts:29
|
|
Resets the whole application.
Returns :
void
|
| scheduleDemand |
scheduleDemand(data: any, index: number, nextIndex: number)
|
|
Defined in src/app/ui/wizard/scheduler.service.ts:125
|
|
Performs in sequence the following operations:
Returns :
void
|
| scheduleNetwork |
scheduleNetwork(data: any, index: number, nextIndex: number)
|
|
Defined in src/app/ui/wizard/scheduler.service.ts:53
|
|
Performs in sequence the following operations:
Returns :
void
|
| scheduleSimulation |
scheduleSimulation(data: any, index: number, nextIndex: number)
|
|
Defined in src/app/ui/wizard/scheduler.service.ts:181
|
|
Performs in sequence the following operations:
Returns :
void
|
import { Injectable } from "@angular/core";
import { switchMap } from "rxjs/operators";
import { WizardService } from "./wizard.service";
import { MapService } from "../map/map.service";
import { LocationService } from "../../location/location.service";
import { NetworkService } from "../../network/network.service";
import { WeatherService } from "../../network/weather/weather.service";
import { DemandService } from "../../demand/demand.service";
import { SimulationService } from "../../simulation/simulation.service";
import { ClockService } from "../../simulation/clock.service";
@Injectable() export class SchedulerService {
constructor(
private wizard: WizardService,
private map: MapService,
private location: LocationService,
private network: NetworkService,
private weather: WeatherService,
private demand: DemandService,
private simulation: SimulationService,
private clock: ClockService
) { }
/**
* Resets the whole application.
*/
public reset(): void {
setTimeout(() => {
// Wizard.
this.wizard.reset();
// Services.
this.map.reset();
this.location.reset();
this.network.reset();
this.weather.reset();
this.demand.reset();
this.simulation.reset();
this.clock.reset();
});
}
/**
* Performs in sequence the following operations:
* - Gets network
* - Creates the graph
* - Gets network data
* - Associates data to the graph
* - Corrects graph data
* - Gets and updates weather data
*/
scheduleNetwork(data: any, index: number, nextIndex: number): void {
this.wizard.putOnHold('Getting the network');
const stream = this.network.getNetwork().pipe(
switchMap((response: any) => {
this.wizard.putOnHold('Creating the graph');
return this.network.createGraph(response);
}),
switchMap(() => {
this.wizard.putOnHold('Getting network data');
return this.network.getNetworkData();
}),
switchMap((response: any) => {
this.wizard.putOnHold('Updating the graph');
return this.network.updateGraph(response);
}),
switchMap(() => {
this.wizard.putOnHold('Checking the data');
return this.network.correctGraph();
}),
switchMap(() => {
this.wizard.putOnHold('Getting weather data');
return this.weather.getWeatherData(this.network.getTime());
}),
switchMap((response: any) => {
return this.weather.updateWeatherData(response, this.network.getTime());
})
);
stream.subscribe(
() => { },
(error: any) => {
let message: string;
switch (error) {
case 'getNetwork':
message = 'Network cannot be retrieved. Check your Internet connection and try again';
break;
case 'createGraph':
message = 'Graph cannnot be created. Please, try with another area';
break;
case 'getNetworkData':
message = 'Network data cannot be retrieved. Past the quota limits traffic data become paid.' +
'This is an open source project: install your own version of it';
break;
case 'correctGraph':
message = 'Graph data are not available. Please, try with another area';
break;
case 'getWeatherData':
message = 'Weather data cannot be retrieved. Please, try at another time';
break;
default:
message = 'Unexpected error';
}
this.wizard.putInError(message);
this.reset();
},
() => {
// Removes from waiting.
this.wizard.removeFromWaiting();
this.wizard.goOn(data, index, nextIndex);
}
);
}
/**
* Performs in sequence the following operations:
* - Calcs shortest paths
* - Calcs incidence matrix
* - Calcs assignment matrix
* - Gets traffic data
* - Calcs link flows
* - Calcs O/D matrix
*/
scheduleDemand(data: any, index: number, nextIndex: number): void {
const graph = this.network.getGraph();
const odPairs = this.network.getOdPairs();
this.wizard.putOnHold('Computing shortest paths');
const stream = graph.calcShortestPaths(odPairs).pipe(
switchMap(() => {
return graph.calcIncidenceMatrix();
}),
switchMap(() => {
return graph.calcAssignmentMatrix(odPairs);
}),
switchMap(() => {
this.wizard.putOnHold('Getting traffic data');
return this.network.getTrafficData();
}),
switchMap((response: any) => {
return this.network.calcLinkFlows(response);
}),
switchMap(() => {
this.wizard.putOnHold('Computing demand');
return this.demand.calcOdMatrix();
})
);
stream.subscribe(
() => { },
(error: any) => {
let message: string;
switch (error) {
case 'calcShortestPaths':
message = 'There are no routes. Please, try with another area';
break;
case 'getTrafficData':
message = 'Traffic data cannot be retrieved. Past the quota limits traffic data become paid.' +
'This is an open source project: install your own version of it';
break;
default:
message = 'Unexpected error';
}
this.wizard.putInError(message);
this.reset();
},
() => {
// Removes from waiting.
this.wizard.removeFromWaiting();
this.wizard.goOn(data, index, nextIndex);
}
);
}
/**
* Performs in sequence the following operations:
* - Calcs max flow for each edge.
* - Inits the simulation.
*/
scheduleSimulation(data: any, index: number, nextIndex: number): void {
const graph = this.network.getGraph();
const factors = this.weather.getFactors();
this.wizard.putOnHold('Computing max flows');
const stream = graph.calcMaxflows(factors[0]).pipe(
switchMap(() => {
this.wizard.putOnHold('Initializing simulation');
return this.simulation.init();
})
);
stream.subscribe(
() => { },
(error: any) => {
let message: string;
switch (error) {
default:
message = 'Unexpected error';
}
this.wizard.putInError(message);
this.reset();
},
() => {
// Removes from waiting.
this.wizard.removeFromWaiting();
this.wizard.goOn(data, index, nextIndex);
}
);
}
}


For change ordering mw-grid has class ".reverse"
(for compatibility, also the old class ".row-reverse"
) which you can add to row and change columns direction from left-to-right to right-to-left.
float: right
for block model, direction : ltr
for inline-block and
flex-direction: row-reverse
for flexdirection : rtl

First column

Second column

Third column


OUR STORY
Founded by two San Francisco natives, Prestige Social Club evolved from the idea that quality isnt something that can be negotiated. Their passion for the class, character and integrity of the city lead them to the realization that their contemporaries needed their own space. They set out to create a space that allowed the influencers of taste to engage with other members of the professional elite. With a long-standing history in the City, they have built relationships with some of the most influential figures in sports, entertainment and local politics. Nestled in between historic China Town and the Russian Hill neighborhood, the space is located int he epicenter of San Francisco culture. Motivated to bring a new wave of class and style to the Bay Area, Prestige is dedicated to member-driven growth, through a member-driven experiance. With our team of professionals and years of marketing and event production experiance, we have the ability to host your next private party or business related conference. Welcome to Prestige San Francisco, social club and event center!


Budapest
Amsterdam
Stockholm
The cities were suberp to visit and a new experience.
Loved exploring the cities with other Euro friends.
- Hungary: Budapest!
- Holland: Amsterdam!
- Sweden: Stockholm!
- Norway: Oslo!
- Iceland: Reykjavik!
Budapest
Amsterdam
Stockholm
The cities were suberp to visit and a new experience.
Loved exploring the cities with other Euro friends.
- Hungary: Budapest!
- Holland: Amsterdam!
- Sweden: Stockholm!
- Norway: Oslo!
- Iceland: Reykjavik!


Atlas is a web application to discover Tor relays. It provides useful information on how relays are configured along with graphics about their past.
You can search for Tor relays and bridges by using keywords. In particular, Atlas enables you to search for (partial) nicknames (e.g., “moria”), IP addresses (e.g., “128.31.”), and fingerprints (e.g., “9695DFC3”). It is also possible to combine searches, e.g., “moria 128.31.”. Finally, you can use qualifiers to search for relays in specific countries (e.g., “moria country:us”), with specific contact information (e.g., “contact:arma”), or with specific flags (e.g., “flag:Authority”).
You are able to get a detailed view of how the relay is configured. What its exit policy is and all the data that you would normally find in the descriptor.
The historical data of a relay's bandwidth usage is available in graph form.
This application is built in a way that all the logic is delegated to the client. This means that the amount of requests made to the server can be minimized and that this application can potentially run by being loaded locally. The server is only interrogated for JSON objects that do not manipulate the DOM of the page. The protocol used for retrieving relay data is called Onionoo you can learn more about Onionoo here and see the protocol details here.
Atlas uses Backbone.js as an MV* framework, with require.js for AMD loading of dependencies. jQuery and Underscore.js as JS utility libraries. Datatables for visualizing data in tabular form with custom filtering. D3.js for making pretty charts. Bootstrap as a CSS framework.
All the code for this website is Open Source and released under 2-Clause BSD. The source code can be found at https://gitweb.torproject.org/atlas.git.


The tramp sits on a matterss at the end of a track. He has a pack. He snacks on scraps and drinks at a tap.  He stamps on the ants. He picks at a tick on his skin. The tramp is sick. He is sad and dispirited.


Application
This is a simple API that uses data extracted from the Kenyan Parlianment website
The back-end is crafted by an amazing PHP framework Fat-Free
The front-end is built w3.css
Author
Charlton Asino
Newbie Coder, PHP and Python
Interests Web ,Data Mining and Data Analysis
Frequently Asked Questions
Why do I like using that picture as my avi?
Answer : Simple,because I can and you will not stop me


{% extends "layout_multi_sections.html" %} {% block page_title %} SIXTH FORMS IN LEEDS {% endblock %} {% block css_register %} {% endblock %} {% block header %} SIXTH FORMS IN LEEDS {% endblock %} {% block main_nav %} {% include "includes/leedspathways/main_nav.html" %} {% endblock %} {% block sectionOneTop %} {% endblock %} {% block sectionOneFull%} {% endblock %} {% block breadcrumb %} {% include "includes/breadcrumb_sp.html" %} {% endblock %} {% block sectionOneContent %} {% endblock %} {% block pageContent %} {% endblock %} {% block sectionOneFullBottom %}
The links below are to the UCAS Progress pages and websites of secondary schools and academies in Leeds that offer the opportunity to study in their sixth form. Visit them to learn more.


Managed Instances
UnManaged Instances
Tags
Sync
InstanceId
OS
IP Address
Region
Status
Actions
InstanceId
OS
IP Address
Region
Status
Actions
Tags Name
Description
Actions
×
Close
Import Instance
Organization
Business Groups
*
Project
*
Environment
*
Config Management
*
Username
*
Please enter Instance Username
Choose Authentication Type
Password
Pem File
Password
Required
Please enter Instance Password
Pem File
Browse
×
Close
Importing Instances


I am a Computer Science master student at the University of Heidelberg and interested in distributed systems design and machine learning. I am trying to build a system of open data exchange to build a basis for more cooperative applications. I am also working on machine learning techniques to make better use of data.
I am also working as a part-time consultant, if you have a project about distributed data management with Clojure or machine learning and data analysis, feel free to reach out to me! I have done descriptive statistics for analysis in R, deep learning and bayesian statistics in Python with tensorflow and theano and some experience with Matlab and Julia.
You can mail me at: christian@topiq.es.


FB Autopoker Options
Interval in Seconds
Randomization
Randomization will select a random delay within the range specified below of the interval value. For example, with an interval of 15 seconds and a range of 10, delays will vary randomly from 5 to 25 seconds.
Range
Note: You will have to reload your Facebook pokes page for any new option values to take effect.
Save


class ConnectionManagerImpl
| Modifiers | Name | Description |
|---|---|---|
private java.util.List<ConnectionContext> |
connections |
Registered connection contexts. |
private org.apache.log4j.Logger |
log |
Logger. |
| Type | Name and description |
|---|---|
ConnectionBuilder |
connectionBuilder Connection builder bean. |
org.codehaus.groovy.grails.commons.GrailsApplication |
grailsApplication Grails application bean. |
| Constructor and description |
|---|
ConnectionManagerImpl
() |
| Type | Name and description |
|---|---|
com.rabbitmq.client.Channel |
createChannel() Creates a new channel with the default connection. |
com.rabbitmq.client.Channel |
createChannel(java.lang.String connectionName) Creates a new channel with the connection identified by the given connection name. |
ConnectionContext |
createContext(ConnectionConfiguration configuration) Creates a new managed context. |
ConnectionContext |
createContext(java.util.Map configuration) Creates a new connection context based on a map of configuration values. |
com.rabbitmq.client.Connection |
getConnection() Returns the RabbitMQ connection associated with the default connection context. |
com.rabbitmq.client.Connection |
getConnection(java.lang.String connectionName) Returns the RabbitMQ connection associated with the connection context identified by the given connection name. |
ConnectionContext |
getContext() Returns the default connection context. |
ConnectionContext |
getContext(java.lang.String name) Returns the connection context with the requested name. |
java.util.List<ConnectionContext> |
getContexts() Returns a list of all registered contexts. |
RunningState |
getRunningState() Returns the state of the contexts the manager. |
void |
load() Loads any configured connections from the grails application configuration. |
void |
register(ConnectionContext context) Registers a new connection context. |
void |
reset() Removes all connection contexts. |
void |
start() Starts all connection contexts. |
void |
start(ConnectionContext context) Start a specific connection context. |
void |
start(java.lang.String name) Starts a specific connection context identified by the given connection name. |
void |
stop() Stops all connection contexts. |
void |
stop(ConnectionContext context) Stops a specific connection context. |
void |
stop(java.lang.String name) Stops a specific connection context identified by the given connection name. |
void |
unregister(ConnectionContext context) Un-registers a connection context. |
| Methods inherited from class | Name |
|---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Registered connection contexts.
Logger.
Connection builder bean.
Grails application bean.
Creates a new channel with the default connection.
Creates a new channel with the connection identified by the given connection name.
Creates a new managed context.
Creates a new connection context based on a map of configuration values.
Returns the RabbitMQ connection associated with the default connection context.
Returns the RabbitMQ connection associated with the connection context identified by the given connection name.
Returns the default connection context.
Returns the connection context with the requested name.
Returns a list of all registered contexts.
Returns the state of the contexts the manager.
Loads any configured connections from the grails application configuration.
Registers a new connection context. If a context already exists with the same name, the old context will be stopped and removed first.
Removes all connection contexts.
Starts all connection contexts.
Start a specific connection context.
Starts a specific connection context identified by the given connection name.
Stops all connection contexts.
Stops a specific connection context.
Stops a specific connection context identified by the given connection name.
Un-registers a connection context.
Groovy Documentation


In the most common case a java.lang.ThreadLocal instance
associates state with a thread. A non-static non-final
java.lang.ThreadLocal field associates state with
an instance-thread combination. This is seldom necessary and often a bug
which can cause memory leaks and possibly incorrect behavior.
This inspection has a quick fix to make the field static final
Powered by InspectionGadgets


- Top-left: Canon AE-1p 35mm Film Camera
- Top-Right: Canon EOS 60D DSLR Digital Camera
- Center-Left: Holga 135 120 Film Camera (Manuf. in China)
- Center-Right: Pinhole Camera made from a tea tin (adopts camera obscura idea)
- Bottom-Right: Kodak S100EF Reuseable Point and Shoot 35mm Film Camera


public abstract class TransformerFactory extends Object
A TransformerFactory instance can be used to create
Transformer
and
Templates
objects.
The system property that determines which Factory implementation
to create is named "javax.xml.transform.TransformerFactory"
.
This property names a concrete subclass of the
TransformerFactory
abstract class. If the property is not
defined, a platform default is be used.
| Modifier | Constructor and Description |
|---|---|
protected |
TransformerFactory()
Default constructor is protected on purpose.
|
| Modifier and Type | Method and Description |
|---|---|
abstract Source |
getAssociatedStylesheet(Source source,
String media,
String title,
String charset)
Get the stylesheet specification(s) associated with the
XML
Source document via the
xml-stylesheet processing instruction that match the given criteria. |
abstract Object |
getAttribute(String name)
Allows the user to retrieve specific attributes on the underlying
implementation.
|
abstract ErrorListener |
getErrorListener()
Get the error event handler for the TransformerFactory.
|
abstract boolean |
getFeature(String name)
Look up the value of a feature.
|
abstract URIResolver |
getURIResolver()
Get the object that is used by default during the transformation
to resolve URIs used in document(), xsl:import, or xsl:include.
|
static TransformerFactory |
newInstance()
Obtain a new instance of a
TransformerFactory . |
static TransformerFactory |
newInstance(String factoryClassName,
ClassLoader classLoader)
Obtain a new instance of a
TransformerFactory from factory class name. |
abstract Templates |
newTemplates(Source source)
Process the Source into a Templates object, which is a
a compiled representation of the source.
|
abstract Transformer |
newTransformer()
Create a new
Transformer that performs a copy
of the Source to the Result . |
abstract Transformer |
newTransformer(Source source)
Process the
Source into a Transformer
Object . |
abstract void |
setAttribute(String name,
Object value)
Allows the user to set specific attributes on the underlying
implementation.
|
abstract void |
setErrorListener(ErrorListener listener)
Set the error event listener for the TransformerFactory, which
is used for the processing of transformation instructions,
and not for the transformation itself.
|
abstract void |
setFeature(String name,
boolean value)
Set a feature for this
TransformerFactory and Transformer s
or Template s created by this factory. |
abstract void |
setURIResolver(URIResolver resolver)
Set an object that is used by default during the transformation
to resolve URIs used in document(), xsl:import, or xsl:include.
|
protected TransformerFactory()
public static TransformerFactory newInstance() throws TransformerFactoryConfigurationError
Obtain a new instance of a TransformerFactory
.
This static method creates a new factory instance
This method uses the following ordered lookup procedure to determine
the TransformerFactory
implementation class to
load:
javax.xml.transform.TransformerFactory
system
property.
java.util.Properties
format and contains the fully qualified name of the
implementation class with the key being the system property defined
above.
The jaxp.properties file is read only once by the JAXP implementation
and it's values are then cached for future use. If the file does not exist
when the first attempt is made to read from it, no further attempts are
made to check for its existence. It is not possible to change the value
of any property in jaxp.properties after it has been read for the first time.
META-INF/services/javax.xml.transform.TransformerFactory
in jars available to the runtime.
TransformerFactory
instance.
Once an application has obtained a reference to a
TransformerFactory
it can use the factory to configure
and obtain transformer instances.
TransformerFactoryConfigurationError
- Thrown if the implementation
is not available or cannot be instantiated.public static TransformerFactory newInstance(String factoryClassName, ClassLoader classLoader) throws TransformerFactoryConfigurationError
Obtain a new instance of a TransformerFactory
from factory class name.
This function is useful when there are multiple providers in the classpath.
It gives more control to the application as it can specify which provider
should be loaded.
Once an application has obtained a reference to a
TransformerFactory
it can use the factory to configure
and obtain transformer instances.
Setting the jaxp.debug
system property will cause
this method to print a lot of debug messages
to System.err
about what it is doing and where it is looking at.
If you have problems try:
java -Djaxp.debug=1 YourProgram ....
factoryClassName
- fully qualified factory class name that provides implementation of javax.xml.transform.TransformerFactory
.classLoader
- ClassLoader
used to load the factory class. If null
current Thread
's context classLoader is used to load the factory class.TransformerFactoryConfigurationError
- if factoryClassName
is null
, or
the factory class cannot be loaded, instantiated.newInstance()
public abstract Transformer newTransformer(Source source) throws TransformerConfigurationException
Process the Source
into a Transformer
Object
. The Source
is an XSLT document that
conforms to
XSL Transformations (XSLT) Version 1.0. Care must
be taken not to use this Transformer
in multiple
Thread
s running concurrently.
Different TransformerFactories
can be used concurrently by
different Thread
s.
source
- Source
of XSLT document used to create
Transformer
.
Examples of XML Source
s include
DOMSource
,
SAXSource
, and
StreamSource
.Transformer
object that may be used to perform
a transformation in a single Thread
, never
null
.TransformerConfigurationException
- Thrown if there are errors when
parsing the Source
or it is not possible to create a
Transformer
instance.public abstract Transformer newTransformer() throws TransformerConfigurationException
Create a new Transformer
that performs a copy
of the Source
to the Result
.
i.e. the "identity transform".
TransformerConfigurationException
- When it is not
possible to create a Transformer
instance.public abstract Templates newTemplates(Source source) throws TransformerConfigurationException
source
- An object that holds a URL, input stream, etc.null
.TransformerConfigurationException
- When parsing to
construct the Templates object fails.public abstract Source getAssociatedStylesheet(Source source, String media, String title, String charset) throws TransformerConfigurationException
Get the stylesheet specification(s) associated with the
XML Source
document via the
xml-stylesheet processing instruction that match the given criteria.
Note that it is possible to return several stylesheets, in which case
they are applied as if they were a list of imports or cascades in a
single stylesheet.
source
- The XML source document.media
- The media attribute to be matched. May be null, in which
case the prefered templates will be used (i.e. alternate = no).title
- The value of the title attribute to match. May be null.charset
- The value of the charset attribute to match. May be null.Source
Object
suitable for passing
to the TransformerFactory
.TransformerConfigurationException
- An Exception
is thrown if an error occurings during parsing of the
source
.public abstract void setURIResolver(URIResolver resolver)
resolver
- An object that implements the URIResolver interface,
or null.public abstract URIResolver getURIResolver()
public abstract void setFeature(String name, boolean value) throws TransformerConfigurationException
Set a feature for this TransformerFactory
and Transformer
s
or Template
s created by this factory.
Feature names are fully qualified URI
s.
Implementations may define their own features.
An TransformerConfigurationException
is thrown if this TransformerFactory
or the
Transformer
s or Template
s it creates cannot support the feature.
It is possible for an TransformerFactory
to expose a feature value but be unable to change its state.
All implementations are required to support the XMLConstants.FEATURE_SECURE_PROCESSING
feature.
When the feature is:
true
: the implementation will limit XML processing to conform to implementation limits
and behave in a secure fashion as defined by the implementation.
Examples include resolving user defined style sheets and functions.
If XML processing is limited for security reasons, it will be reported via a call to the registered
ErrorListener.fatalError(TransformerException exception)
.
See setErrorListener(ErrorListener listener)
.
false
: the implementation will processing XML according to the XML specifications without
regard to possible implementation limits.
name
- Feature name.value
- Is feature state true
or false
.TransformerConfigurationException
- if this TransformerFactory
or the Transformer
s or Template
s it creates cannot support this feature.NullPointerException
- If the name
parameter is null.public abstract boolean getFeature(String name)
Feature names are fully qualified URI
s.
Implementations may define their own features.
false
is returned if this TransformerFactory
or the
Transformer
s or Template
s it creates cannot support the feature.
It is possible for an TransformerFactory
to expose a feature value but be unable to change its state.
name
- Feature name.true
or false
.NullPointerException
- If the name
parameter is null.public abstract void setAttribute(String name, Object value)
IllegalArgumentException
is thrown if the underlying
implementation doesn't recognize the attribute.
All implementations that implement JAXP 1.5 or newer are required to
support the XMLConstants.ACCESS_EXTERNAL_DTD
and
XMLConstants.ACCESS_EXTERNAL_STYLESHEET
properties.
Access to external DTDs in the source file is restricted to the protocols
specified by the XMLConstants.ACCESS_EXTERNAL_DTD
property.
If access is denied during transformation due to the restriction of this property,
TransformerException
will be thrown by
Transformer.transform(Source, Result)
.
Access to external DTDs in the stylesheet is restricted to the protocols
specified by the XMLConstants.ACCESS_EXTERNAL_DTD
property.
If access is denied during the creation of a new transformer due to the
restriction of this property,
TransformerConfigurationException
will be thrown
by the newTransformer(Source)
method.
Access to external reference set by the stylesheet processing instruction,
Import and Include element is restricted to the protocols specified by the
XMLConstants.ACCESS_EXTERNAL_STYLESHEET
property.
If access is denied during the creation of a new transformer due to the
restriction of this property,
TransformerConfigurationException
will be thrown
by the newTransformer(Source)
method.
Access to external document through XSLT document function is restricted
to the protocols specified by the property. If access is denied during
the transformation due to the restriction of this property,
TransformerException
will be thrown by the
Transformer.transform(Source, Result)
method.
name
- The name of the attribute.value
- The value of the attribute.IllegalArgumentException
- When implementation does not
recognize the attribute.public abstract Object getAttribute(String name)
IllegalArgumentException
is thrown if the underlying
implementation doesn't recognize the attribute.name
- The name of the attribute.IllegalArgumentException
- When implementation does not
recognize the attribute.public abstract void setErrorListener(ErrorListener listener)
IllegalArgumentException
is thrown if the
ErrorListener
listener is null
.listener
- The new error listener.IllegalArgumentException
- When listener
is
null
public abstract ErrorListener getErrorListener()
Submit a bug or feature
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
Copyright © 1993, 2015, Oracle and/or its affiliates. All rights reserved.


NASA
Partnership Agreement Maker
Welcome,
Username
libDest
Home
Routing Packages
Routing Templates
My Reviews
Routing Packages
Create New Routing Package
Draft (
00
)
In Routing (
00
)
Completed (
00
)
Filter
Routing Group
Group 1
Group 2
Group 3
Title
Routing #
PAM #
Partner Name
Agreement No.
Created Between
To
Routed Between
To
Completed Between
To
Show Only Packages Adminstered by me
Created By
Reviewed By
Completion Status
Draft
In routing
Completed
Reset
Filter
Routing Package Name
Group
Administered by
Created On
Current Reviewers


How
the British Empire Mapped the Himalayan region in the 1860's
(This article first appeared in Measurement News Issue No. 82 March 1997)
According to Peter Hopkirk in The Great Game (OUP, Oxford, 1991) "The idea of using native explorers to carry
out clandestine surveys of lawless regions beyond India's frontiers had arisen as a result of the Viceroy's strict
ban on British officers venturing there. Because of this the Survey of India, which had the task of providing the
government with maps of the entire sub-continent and the surrounding regions, found itself greatly hampered when
it came to mapping northern Afghanistan, Turkestan and Tibet. Then a young officer working for the Survey, Captain
Thomas Montgomerie of the Royal Engineers, hit upon the solution. Why not, he asked his superiors, send native
explorers trained in secret surveying techniques into these forbidden regions? They were far less likely to be
detected than a European, however good the latter's disguise. If they were unfortunate enough to be discovered
moreover, it would be less politically embarrassing to the authorities than if a British officer was caught red-handed
making maps in these sensitive and dangerous parts.
"Surprisingly perhaps, in view of the British and Indian governments' determination not to become entangled
in Central Asia, Montgomerie's bold plan was approved, and over the next few years a number of Indian explorers,
including Nain Singh and Kishen Singh, were dispatched in great secrecy across the frontier. All of them were hillmen,
carefully chosen for their exceptional intelligence and resourcefulness. The word "pundit", which suggests
a man of certain learning, became the generic name by which they were referred to. Because discovery, or even suspicion,
would have spelt instant death, their existence and activities had to be kept as secret as possible. Even within
the Survey of India they were known merely by a number or cryptonym. They were trained personally by Montgomerie
at Dehra Dun, the Survey's headquarters in the Himalayan foothills.
"Montgomerie trained his men through exhaustive practice to take a pace of known length - 33 inches in the
case of Nain Singh - which would remain constant whether they walked up hill, downhill or on the level. Next he
taught them ways of keeping a precise but discreet count of the number of such paces taken during a day's march.
This enabled them to measure immense distances with remarkable accuracy and without rousing suspicion. Often they
travelled as Buddhist pilgrims, many of whom regularly crossed the passes to visit the holy sites of the ancient
Silk Road. Every Buddhist carried a rosary of 108 beads on which to count his prayers, and also a small wood and
metal prayer-wheel which he spun as he walked. Both of these Montgomerie turned to his advantage. From the rosary
he removed eight beads, not enough to be noticed, but leaving a mathematically convenient 100. At every hundredth
pace the Pundit would automatically slip one bead. Each completed circuit of the rosary therefore represented 10,000
paces - five miles in the case of Nain Singh.
"The totals of the day's march, together with any other discreet observations, had to be logged somewhere
safe from prying eyes. It was here that the prayer-wheel, with its copper cylinder, proved invaluable. For concealed
in this, in place of the usual handwritten scroll of prayers, was a roll of blank paper. This served as a log-book,
which could easily be got at by releasing a secret catch and removing the top of the cylinder. Some of these prayer-wheels
are still preserved in the Indian State Archives. Then there was the problem of the compass, for the Pundit was
required to take regular bearings as he journeyed. Montgomerie concealed this in the lid of the prayer -wheel.
Thermometers, which were needed for calculating altitudes, were hidden in the tops of the pilgrims' staves. Mercury,
essential for setting an artificial horizon when taking sextant readings, was hidden in sealed cowrie shells and
poured into a pilgrim's begging bowl when required. Concealed pockets were added to the Pundit's clothing and false
bottoms, in which the sextants could be hidden, were built into the chests which most native travellers carried.
All this work was done in the Survey of India's workshops at Dehran Dun under Montgomerie's supervision.
"The Pundits were also thoroughly trained in the art of disguise and in the use of cover stories. In the lawless
lands beyond the frontier their safety would depend on just how convincingly they could play the part of holy man,
pilgrim or Himalayan trader. Their disguise and cover had to stand the test of months of travelling, often in the
closest intimacy with genuine pilgrims and traders. Some were away for years. One became the first Asiatic to be
awarded the Royal Geographical Society's gold medal, having contributed `a greater amount of positive knowledge
to the map of Asia than any other individual of our time.' At least two never returned, whilst a third was sold
into slavery, although he eventually escaped. In all, their clandestine journeys were to provide a wealth of geographical
intelligence over twenty years which Montgomerie and his fellow cartographers at Dehra Dun used to fill in many
of the no-go areas on the British maps of Central Asia."
In Trespassers on the Roof of the World, Hopkirk described some such journeys, the following of Nain Singh. He
started in the company of his cousin, Mani, but they then went separate ways to reduce the chances of discovery.
"They calibrated their instruments in the small town of Bareilly, whose location was known exactly to the
Survey authorities and crossed successfully into Nepal. Nain Singh managed to attach himself to a Ladakhi caravan
approaching from the west and bound for Lhasa. At one stage, however, the Ladakhi traders transferred their goods
to coracles and shipped these and themselves some 85 miles down the River Tsangpo [Brahmaputra] to Shigatse, Tibet's
second town. But Nain Singh, of course, had to continue the journey on foot (on what pretext is not known) so that
there would be no gap in the secret route survey he had been conducting ever since leaving Bareilly - without any
of his fellow travellers suspecting for a moment what he was really up to with his rosary, muttered prayers and
spinning prayer-wheel.
"[In January 1866] Exactly one year after leaving Dehra Dun, Nain Singh reached Lhasa having counted every
single pace of the way as well as taking innumerable clandestine compass bearings and other observations. He spent
three months in the Holy City and took 20 separate observations, both solar and stellar, enabling him to establish
its exact latitude (the pundits were not trained in the far more difficult skills required fro calculating longitude.)
Nain Singh's observations showed Lhasa at 29.39' degrees. Today's atlases put it at 29.41'. Altitude calculations
showed the Tibetan capital at 11,700 feet. Today it is generally given as 12,000 feet, the discrepancy possibly
due to the readings being taken as different spots.
"In April 1866 Nain Singh learned that the Ladakhi caravan he had accompanied to Lhasa was ready to return
home. The 500-mile march took over two months and followed the ancient Jong-lam trade route that stretched across
Tibet from east to west, the most elevated highway in the world at 15,000 feet. Once again, Nain Singh paced every
step of the way and took the necessary secret observations for his route survey, finally descending into British
India after an absence of one and a half years.
"Montgomerie assimilated all his mileages, bearings and altitudes and latitudes into a map. `The Pundit I
think deserves all praise, his work has stood every test capitally. …` Lhasa's longitude was calculated from the
route survey, to within a quarter of a degree. Nain Singh's route survey, in which he had walked 1200 miles and
counted 2,500,000 individual paces had disproved the notion that existing maps of Tibet might be correct in some
respects."
"Montgomerie's full official report of the clandestine trip was sent to the Royal Geographical Society, and
the Pundits' secrets were revealed to all and sundry in their Journal, including bogus prayer-wheels, doctored
rosaries and concealed sextants. This elementary but massive breach of security is hard to understand, as it put
both the Pundits' lives and future operations [at risk] The Journal, was only distributed to fellows of the Society
, although these did include Russian explorers. But as long as it continued to publish such accounts and maps,
St Petersburg remained happy. The Chinese would have had every reason to intervene, but their London Legation did
not know of the Journal. It would only have needed one busybody to alert them, and simple checks at Tibetan border
posts would have imperilled the entire enterprise.
"Just what drove men like Nain Singh and Kishen Singh [who undertook a five-million pace journey to Chinese
Turkestan lasting four and a half years] to face such hardships and extreme dangers for their imperial masters
has never been satisfactorily explained. Perhaps it was the inspirational leadership of Montgomerie, who took such
a pride in their individual achievements, and who looked upon them as his sons. Or possibly it was the knowledge
that they belonged to an elite, for each was aware that he had been handpicked for this great task. Or maybe Montgomerie
had managed to imbue them with his own patriotic determination to fill in the blanks on the Great Game map before
the Russians did. Sadly, little is known of these men as individuals, for none of them left memoirs of any kind.
However, it is in Kipling's masterpiece Kim, whose characters so clearly come from the shadowy world of Captain
Montgomerie, that they have their just memorial."
Other journeys and other pundits' stories are recounted by Hopkirk in the book, but what I've selectively transcribed
above indicates some interesting points in common with our own less heroic methods of measurement. Calibration,
counters (the rosary `rotates' with roughly the same frequency as a Jones counter), a chain of continuous measurements,
temperature effects on measurement, a course map and Montgomerie sahib, the big white chief, as certifier."


Post #4: Enumerable#cycle
How does it work?
June 13, 2015
Cycle is another aptly named method in Ruby. When #cycle
is called on an array, the method cycles through each element infinitely unless a break is called or an argument is used.
For example,
array = ["mama", "papa", "baby"] array.cycle #=> mama, papa, baby, mama, papa, baby, mama, papa, baby, mama, papa, baby, mama, papa, baby, mama...Whereas,
array.cycle(2) #=> mama, papa, baby, mama, papa, baby
If you wish to print the cycle to the console, then you can use the block:
array.cycle(3) {|x| puts x}
The cycle could also be stopped at a specific point such as,
array.cycle do |x| break if x == "papa"
The #cycle
method does not automatically store the values, so you could choose to make a new array and push the cycled values to the array.
Hopefully you are starting to think of some situations where #cycle
might be useful. This might incude when are you looking to assign roles or positions to a group of people. You could combine the #zip
and the #cycle
methods to create a distribution of responsiblities. Unfortunately #cycle
will only run a complete course. It is not possible to stop at a certain number of elements except at the end of a full cycle. I think this is probably the biggest limitation of the method, similar to n.times do
.
RESOURCES for
Enumerable#cycle
- Global Nerdy Tech Blog on
Enumerable#cycle
- SitePoint on Enumerables (see
#cycle
section) - And of course, Ruby Docs


Agriculture Development
Women Empowerment
Rural Development
Handicrafts
Disaster Management
Healthcare
Child Rights
Economic Development
Donating for Social Cause and
Saving on Tax under Section 80G
As per the Income Tax Act, 1961, not all donations are subject to tax deductions. If you have donated to an NGO that is not certified under Section 80G of the Income Tax Act, you may not be entitled to tax benefits. To save on tax, ensure that the NGO you have chosen for donating meets this criterion.
What is Section 80G?
The Income Tax Act, 1961 encourages charitable deeds. This government body offers donation tax benefits to donors under Section 80G. NGOs and Trusts having a 12A certificate are entitled to 80G certification. A 12A registration is a one-time exemption obtained by a Trust/NGO. The IT Department intensely scrutinizes every detail before granting such a certification.


| Year | # of Vulnerabilities | DoS | Code Execution | Overflow | Memory Corruption | Sql Injection | XSS | Directory Traversal | Http Response Splitting | Bypass something | Gain Information | Gain Privileges | CSRF | File Inclusion | # of exploits |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2019 | 3 | 1 | 1 | 1 | |||||||||||
| 2020 | 6 | 1 | 1 | ||||||||||||
| 2021 | 2 | 1 | 1 | ||||||||||||
| Total | 11 | 1 | 2 | 2 | 2 | ||||||||||
| % Of All | 9.1 | 18.2 | 0.0 | 0.0 | 0.0 | 0.0 | 18.2 | 0.0 | 0.0 | 18.2 | 0.0 | 0.0 | 0.0 |
| 3 |
6 |
2 |
2019 3 2020 6 2021 2 |
| 1 |
2 |
2 |
2 |
Denial of Service 1 Execute Code 2 Directory Traversal 2 Gain Information 2 |