From 8da8e19ca6e3609c4602619c961be3e934042560 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Thu, 24 Mar 2016 19:31:37 -0400
Subject: [PATCH 01/51] Begin writing introduction
---
api.md | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/api.md b/api.md
index 5feafcd..bf92874 100644
--- a/api.md
+++ b/api.md
@@ -1,3 +1,11 @@
# WiFi Pineapple Module API
-Work in progress
+## Introduction
+Unlike the old web interface, the back end of the new interface has been decoupled from the front end. All requests to perform system actions are sent as POSTs to `/api/`. The content of the POST is JSON and contains a minimal of two parameters.
+### The first parameter key must be either `system` or `module`
+`system` is used for core system functions such as logging users in and performing system setup as well as managing notifications. `module` is used when sending a request to any of the default modules or to any user modules. The value is set to the module with which you are trying to communicate. For example, `"system": "notifications"` or `"module": "RandomRoll"`.
+### The second parameter key `action`
+This is set to the action you wish to perform. For instance, this could be `"action": "listNotifications"` or `"action": "getRandomRollRolls"`.
+### Any other parameters are optional and are specific to the module and action you are requesting
+Many actions do not require additional parameters. For instance, `{"system": "notifications", "action": "listNotifications"}` will return a list of all of the current unread notifications (as JSON). However, there are some functions, such as `addNotification`, that require additional parameters (in this case `message`). To create a new notifications, one would use the following request:
+`{"system": "notifications", "action": "addNotification", "message": "Hello World!"}`
From 0dffbbf0e6614105e13a8b826b41df14d420bfb2 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Sun, 27 Mar 2016 09:04:26 -0400
Subject: [PATCH 02/51] Update api.md
---
api.md | 21 +++++++++++++++++++++
1 file changed, 21 insertions(+)
diff --git a/api.md b/api.md
index bf92874..7fa5bb3 100644
--- a/api.md
+++ b/api.md
@@ -9,3 +9,24 @@ This is set to the action you wish to perform. For instance, this could be `"act
### Any other parameters are optional and are specific to the module and action you are requesting
Many actions do not require additional parameters. For instance, `{"system": "notifications", "action": "listNotifications"}` will return a list of all of the current unread notifications (as JSON). However, there are some functions, such as `addNotification`, that require additional parameters (in this case `message`). To create a new notifications, one would use the following request:
`{"system": "notifications", "action": "addNotification", "message": "Hello World!"}`
+
+## Authentication
+There are a couple ways to authenticate with the pineapple. Requests sent via the web interface use a PHPSESSID cookie as well as an X-XSRF-TOKEN header. The pineapple will verify that the session is valid and logged in and that the XSRF token matches the one generated at the start of the session. If both of these conditions are met, the request is routed. An example of a request sent by chrom is as follows:
+```
+POST /api/ HTTP/1.1
+Host: 172.16.42.1:1471
+Connection: keep-alive
+Content-Length: 55
+Accept: application/json, text/plain, */*
+Origin: http://172.16.42.1:1471
+X-XSRF-TOKEN: b01c5046faa2f8ffbed6f2fdd90a5605e6c505e3
+User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.87 Safari/537.36
+Content-Type: application/json;charset=UTF-8
+Referer: http://172.16.42.1:1471/
+Accept-Encoding: gzip, deflate
+Accept-Language: en-US,en;q=0.8
+Cookie: PHPSESSID=cfd6b0bb983666362cae311c457d1d34; XSRF-TOKEN=b01c5046faa2f8ffbed6f2fdd90a5605e6c505e3
+
+{"system":"notifications","action":"listNotifications"}
+```
+This type of authentication is awkward and clumbsy to implement programmatically. Because of this, we have added a new way to authenticate with the WiFi Pineapple: API tokens.
From 4a06a76e5c0bb8660960bcdd2638868cf4f58638 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Sun, 27 Mar 2016 09:07:07 -0400
Subject: [PATCH 03/51] Update api.md
---
api.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/api.md b/api.md
index 7fa5bb3..46c079e 100644
--- a/api.md
+++ b/api.md
@@ -11,7 +11,7 @@ Many actions do not require additional parameters. For instance, `{"system": "no
`{"system": "notifications", "action": "addNotification", "message": "Hello World!"}`
## Authentication
-There are a couple ways to authenticate with the pineapple. Requests sent via the web interface use a PHPSESSID cookie as well as an X-XSRF-TOKEN header. The pineapple will verify that the session is valid and logged in and that the XSRF token matches the one generated at the start of the session. If both of these conditions are met, the request is routed. An example of a request sent by chrom is as follows:
+There are a couple ways to authenticate with the pineapple. Requests sent via the web interface use a PHPSESSID cookie as well as an X-XSRF-TOKEN header. The pineapple will verify that the session is valid and logged in and that the XSRF token matches the one generated at the start of the session. If both of these conditions are met, the request is routed. An example of a request sent by chrome is as follows:
```
POST /api/ HTTP/1.1
Host: 172.16.42.1:1471
@@ -29,4 +29,4 @@ Cookie: PHPSESSID=cfd6b0bb983666362cae311c457d1d34; XSRF-TOKEN=b01c5046faa2f8ffb
{"system":"notifications","action":"listNotifications"}
```
-This type of authentication is awkward and clumbsy to implement programmatically. Because of this, we have added a new way to authenticate with the WiFi Pineapple: API tokens.
+This type of authentication is awkward and clumbsy to implement programmatically. Because of this, we have added a new way to authenticate with the WiFi Pineapple: API tokens. Though API tokens are supported by default, the pineapple is shipped without any valid tokens. The process of generating API tokens is simplified by the [API Tokens module](https://github.com/735tesla/Pineapple-API-Tokens-Module).
From cbc36cfc7148a749ee7d316aa53dc43aa8dd189b Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Sun, 27 Mar 2016 09:16:56 -0400
Subject: [PATCH 04/51] Update api.md
---
api.md | 19 +++++++++++++++++--
1 file changed, 17 insertions(+), 2 deletions(-)
diff --git a/api.md b/api.md
index 46c079e..3bf1214 100644
--- a/api.md
+++ b/api.md
@@ -8,7 +8,13 @@ Unlike the old web interface, the back end of the new interface has been decoupl
This is set to the action you wish to perform. For instance, this could be `"action": "listNotifications"` or `"action": "getRandomRollRolls"`.
### Any other parameters are optional and are specific to the module and action you are requesting
Many actions do not require additional parameters. For instance, `{"system": "notifications", "action": "listNotifications"}` will return a list of all of the current unread notifications (as JSON). However, there are some functions, such as `addNotification`, that require additional parameters (in this case `message`). To create a new notifications, one would use the following request:
-`{"system": "notifications", "action": "addNotification", "message": "Hello World!"}`
+```
+{
+ "system": "notifications",
+ "action": "addNotification",
+ "message": "Hello World!"
+}
+```
## Authentication
There are a couple ways to authenticate with the pineapple. Requests sent via the web interface use a PHPSESSID cookie as well as an X-XSRF-TOKEN header. The pineapple will verify that the session is valid and logged in and that the XSRF token matches the one generated at the start of the session. If both of these conditions are met, the request is routed. An example of a request sent by chrome is as follows:
@@ -29,4 +35,13 @@ Cookie: PHPSESSID=cfd6b0bb983666362cae311c457d1d34; XSRF-TOKEN=b01c5046faa2f8ffb
{"system":"notifications","action":"listNotifications"}
```
-This type of authentication is awkward and clumbsy to implement programmatically. Because of this, we have added a new way to authenticate with the WiFi Pineapple: API tokens. Though API tokens are supported by default, the pineapple is shipped without any valid tokens. The process of generating API tokens is simplified by the [API Tokens module](https://github.com/735tesla/Pineapple-API-Tokens-Module).
+This type of authentication is awkward and clumbsy to implement programmatically. Because of this, we have added a new way to authenticate with the WiFi Pineapple: API tokens. Though API tokens are supported by default, the pineapple is shipped without any valid tokens. The process of generating API tokens is simplified by the [API Tokens module](https://github.com/735tesla/Pineapple-API-Tokens-Module). After a token has been generated, it can be sent as an additional parameter. To use an API token, simply add an additional `apiToken` key to the request body. For example, to add a notification, one could send the following JSON request:
+```
+{
+ "system": "notifications",
+ "action": "addNotification",
+ "message": "Hello World!",
+ "apiToken": "7365626b696e6e652063616e7420636f6465202724ef6b5d7ac0b800cc83d474e8e007"
+}
+```
+If the `apiToken` parameter is valid, the request will be route; otherwise an error will be returned.
From b4eaf4fb417cb6d634332e73c7f9daccca277740 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Sun, 27 Mar 2016 09:18:06 -0400
Subject: [PATCH 05/51] Update api.md
---
api.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/api.md b/api.md
index 3bf1214..1e5610f 100644
--- a/api.md
+++ b/api.md
@@ -2,11 +2,11 @@
## Introduction
Unlike the old web interface, the back end of the new interface has been decoupled from the front end. All requests to perform system actions are sent as POSTs to `/api/`. The content of the POST is JSON and contains a minimal of two parameters.
-### The first parameter key must be either `system` or `module`
+#### The first parameter key must be either `system` or `module`
`system` is used for core system functions such as logging users in and performing system setup as well as managing notifications. `module` is used when sending a request to any of the default modules or to any user modules. The value is set to the module with which you are trying to communicate. For example, `"system": "notifications"` or `"module": "RandomRoll"`.
-### The second parameter key `action`
+#### The second parameter key `action`
This is set to the action you wish to perform. For instance, this could be `"action": "listNotifications"` or `"action": "getRandomRollRolls"`.
-### Any other parameters are optional and are specific to the module and action you are requesting
+#### Any other parameters are optional and are specific to the module and action you are requesting
Many actions do not require additional parameters. For instance, `{"system": "notifications", "action": "listNotifications"}` will return a list of all of the current unread notifications (as JSON). However, there are some functions, such as `addNotification`, that require additional parameters (in this case `message`). To create a new notifications, one would use the following request:
```
{
From 2fbe092d4d40ce5b1fea60dbfc705bd9c7724c24 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Sun, 27 Mar 2016 09:23:12 -0400
Subject: [PATCH 06/51] Update api.md
---
api.md | 42 ++++++++++++++++++++++++++++++++++++++++++
1 file changed, 42 insertions(+)
diff --git a/api.md b/api.md
index 1e5610f..184223b 100644
--- a/api.md
+++ b/api.md
@@ -45,3 +45,45 @@ This type of authentication is awkward and clumbsy to implement programmatically
}
```
If the `apiToken` parameter is valid, the request will be route; otherwise an error will be returned.
+
+## Modules
+### Advanced
+#### Description
+#### Supported Actions
+### Clients
+#### Description
+#### Supported Actions
+### Configuration
+#### Description
+#### Supported Actions
+### Dashboard
+#### Description
+#### Supported Actions
+### Filters
+#### Description
+#### Supported Actions
+### Logging
+#### Description
+#### Supported Actions
+### ModuleManager
+#### Description
+#### Supported Actions
+### Networking
+#### Description
+#### Supported Actions
+### PineAP
+#### Description
+#### Supported Actions
+### Recon
+#### Description
+#### Supported Actions
+### Reporting
+#### Description
+#### Supported Actions
+### Tracking
+#### Description
+#### Supported Actions
+
+## Community Python API
+
+## Further Information
From ab493fa656d0dfaa811c65fb8812a20ceec84444 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Mon, 4 Apr 2016 13:03:43 -0400
Subject: [PATCH 07/51] Update api.md
---
api.md | 14 ++++++++++++++
1 file changed, 14 insertions(+)
diff --git a/api.md b/api.md
index 184223b..f4be1ff 100644
--- a/api.md
+++ b/api.md
@@ -50,6 +50,20 @@ If the `apiToken` parameter is valid, the request will be route; otherwise an er
### Advanced
#### Description
#### Supported Actions
+Action|Description|Parameters
+------|-----------|----------
+`getResources`|Returns a JSON array of disk and memory usage|_none_
+`dropCaches`|Clears system caches|_none_
+`getUSB`|Returns a list of USB devices connected ot the pineapple|_none
+`getFstab`|Returns the contents of `/etc/config/fstab`|_none_
+`getCSS`||
+`saveFstab`|Overwrites `/etc/config/fstab` with a string|
- `fstab`
- item2
- A string to be written to `/etc/config/fstab`
+`saveCSS`||
+`checkForUpgrade`||
+`downloadUpgrade`||
+`getDownloadStatus`||
+`performUpgrade`||
+`getCurrentVersion`||
### Clients
#### Description
#### Supported Actions
From cc5632146a097ed1905395b7d42891eaf039ae97 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Mon, 4 Apr 2016 13:04:39 -0400
Subject: [PATCH 08/51] Update api.md
---
api.md | 12 ------------
1 file changed, 12 deletions(-)
diff --git a/api.md b/api.md
index f4be1ff..db908c6 100644
--- a/api.md
+++ b/api.md
@@ -49,7 +49,6 @@ If the `apiToken` parameter is valid, the request will be route; otherwise an er
## Modules
### Advanced
#### Description
-#### Supported Actions
Action|Description|Parameters
------|-----------|----------
`getResources`|Returns a JSON array of disk and memory usage|_none_
@@ -66,37 +65,26 @@ Action|Description|Parameters
`getCurrentVersion`||
### Clients
#### Description
-#### Supported Actions
### Configuration
#### Description
-#### Supported Actions
### Dashboard
#### Description
-#### Supported Actions
### Filters
#### Description
-#### Supported Actions
### Logging
#### Description
-#### Supported Actions
### ModuleManager
#### Description
-#### Supported Actions
### Networking
#### Description
-#### Supported Actions
### PineAP
#### Description
-#### Supported Actions
### Recon
#### Description
-#### Supported Actions
### Reporting
#### Description
-#### Supported Actions
### Tracking
#### Description
-#### Supported Actions
## Community Python API
From cc5cbe84f8f7ed1c4e123e6636e0d0fb4bfcb2a8 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Mon, 4 Apr 2016 13:08:33 -0400
Subject: [PATCH 09/51] Update api.md
---
api.md | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/api.md b/api.md
index db908c6..ca65370 100644
--- a/api.md
+++ b/api.md
@@ -55,11 +55,11 @@ Action|Description|Parameters
`dropCaches`|Clears system caches|_none_
`getUSB`|Returns a list of USB devices connected ot the pineapple|_none
`getFstab`|Returns the contents of `/etc/config/fstab`|_none_
-`getCSS`||
+`getCSS`|Returns the contents of main.css|_none_
`saveFstab`|Overwrites `/etc/config/fstab` with a string|- `fstab`
- item2
- A string to be written to `/etc/config/fstab`
-`saveCSS`||
-`checkForUpgrade`||
-`downloadUpgrade`||
+`saveCSS`|Overwrites the contents of main.css with a string|- `css`
- item2
- A string to be written to `/pineapple/css/main.css`
+`checkForUpgrade`|Fetches the list of upgrades and the description of each|_none_
+`downloadUpgrade`|Upgrades the pineapple to a specified firmare version (see output of `checkForUpgrades`)|- `version`
- item2
- The version to which the pineapple should be upgraded
`getDownloadStatus`||
`performUpgrade`||
`getCurrentVersion`||
From 93887a573ec145b290cb90b030c1c34a1dc2d702 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Mon, 4 Apr 2016 13:10:48 -0400
Subject: [PATCH 10/51] Update api.md
---
api.md | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/api.md b/api.md
index ca65370..7b95c14 100644
--- a/api.md
+++ b/api.md
@@ -56,10 +56,10 @@ Action|Description|Parameters
`getUSB`|Returns a list of USB devices connected ot the pineapple|_none
`getFstab`|Returns the contents of `/etc/config/fstab`|_none_
`getCSS`|Returns the contents of main.css|_none_
-`saveFstab`|Overwrites `/etc/config/fstab` with a string|- `fstab`
- item2
- A string to be written to `/etc/config/fstab`
-`saveCSS`|Overwrites the contents of main.css with a string|- `css`
- item2
- A string to be written to `/pineapple/css/main.css`
+`saveFstab`|Overwrites `/etc/config/fstab` with a string|- `fstab`
- A string to be written to `/etc/config/fstab`
+`saveCSS`|Overwrites the contents of main.css with a string|- `css`
- A string to be written to `/pineapple/css/main.css`
`checkForUpgrade`|Fetches the list of upgrades and the description of each|_none_
-`downloadUpgrade`|Upgrades the pineapple to a specified firmare version (see output of `checkForUpgrades`)|- `version`
- item2
- The version to which the pineapple should be upgraded
+`downloadUpgrade`|Upgrades the pineapple to a specified firmare version (see output of `checkForUpgrades`)|- `version`
- The version to which the pineapple should be upgraded
`getDownloadStatus`||
`performUpgrade`||
`getCurrentVersion`||
From 444be5f4f21756c0765ba7c2d19f9e06ed51eecb Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Mon, 4 Apr 2016 13:14:16 -0400
Subject: [PATCH 11/51] Update api.md
---
api.md | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/api.md b/api.md
index 7b95c14..ba5d121 100644
--- a/api.md
+++ b/api.md
@@ -53,16 +53,16 @@ Action|Description|Parameters
------|-----------|----------
`getResources`|Returns a JSON array of disk and memory usage|_none_
`dropCaches`|Clears system caches|_none_
-`getUSB`|Returns a list of USB devices connected ot the pineapple|_none
+`getUSB`|Returns a list of USB devices connected ot the pineapple|_none_
`getFstab`|Returns the contents of `/etc/config/fstab`|_none_
`getCSS`|Returns the contents of main.css|_none_
`saveFstab`|Overwrites `/etc/config/fstab` with a string|- `fstab`
- A string to be written to `/etc/config/fstab`
`saveCSS`|Overwrites the contents of main.css with a string|- `css`
- A string to be written to `/pineapple/css/main.css`
`checkForUpgrade`|Fetches the list of upgrades and the description of each|_none_
-`downloadUpgrade`|Upgrades the pineapple to a specified firmare version (see output of `checkForUpgrades`)|- `version`
- The version to which the pineapple should be upgraded
-`getDownloadStatus`||
-`performUpgrade`||
-`getCurrentVersion`||
+`downloadUpgrade`|Upgrades the pineapple to a specified firmare version (see output of `checkForUpgrades` and `getCurrentVersion`)|- `version`
- The version to which the pineapple should be upgraded
+`getDownloadStatus`|Tells whether a firmware download is complete or in progress and how many bytes have been downloaded|_none
+`performUpgrade`|Upgrades using the image in /tmp/upgrade.bin|_none_
+`getCurrentVersion`|Returns the current firmware version on the pineapple|_none_
### Clients
#### Description
### Configuration
From b4c35b2ccdc96c694522294b89cdfdff28dcc45d Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Mon, 4 Apr 2016 13:21:56 -0400
Subject: [PATCH 12/51] Update api.md
---
api.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/api.md b/api.md
index ba5d121..b3f3129 100644
--- a/api.md
+++ b/api.md
@@ -60,7 +60,7 @@ Action|Description|Parameters
`saveCSS`|Overwrites the contents of main.css with a string|- `css`
- A string to be written to `/pineapple/css/main.css`
`checkForUpgrade`|Fetches the list of upgrades and the description of each|_none_
`downloadUpgrade`|Upgrades the pineapple to a specified firmare version (see output of `checkForUpgrades` and `getCurrentVersion`)|- `version`
- The version to which the pineapple should be upgraded
-`getDownloadStatus`|Tells whether a firmware download is complete or in progress and how many bytes have been downloaded|_none
+`getDownloadStatus`|Tells whether a firmware download is complete or in progress and how many bytes have been downloaded|_none_
`performUpgrade`|Upgrades using the image in /tmp/upgrade.bin|_none_
`getCurrentVersion`|Returns the current firmware version on the pineapple|_none_
### Clients
From 5dc895bb29ec3da05915a263ce274f071174007e Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Mon, 4 Apr 2016 18:54:50 +0100
Subject: [PATCH 13/51] Start Networking section
---
api.md | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/api.md b/api.md
index b3f3129..fcaafe3 100644
--- a/api.md
+++ b/api.md
@@ -77,6 +77,10 @@ Action|Description|Parameters
#### Description
### Networking
#### Description
+Action|Description|Parameters
+------|-----------|----------
+`getRoutingTable`|Returns the routing table of the Pineapple|_none_
+`restartDNS`|Restarts the DNS service on the Pineapple|_none_
### PineAP
#### Description
### Recon
From afad9b463592fdae8bff0125d869834491299592 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Mon, 4 Apr 2016 19:06:20 +0100
Subject: [PATCH 14/51] Add more to table for Networking
---
api.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/api.md b/api.md
index fcaafe3..96c389c 100644
--- a/api.md
+++ b/api.md
@@ -81,6 +81,7 @@ Action|Description|Parameters
------|-----------|----------
`getRoutingTable`|Returns the routing table of the Pineapple|_none_
`restartDNS`|Restarts the DNS service on the Pineapple|_none_
+`updateRoute`|Updates the routing table|- `routeInterface`
### PineAP
#### Description
### Recon
From 79a14566292132af1c0af4850861cef8296aae60 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Mon, 4 Apr 2016 19:11:19 +0100
Subject: [PATCH 15/51] Add getAdvancedData, setHostname to table for
Networking
---
api.md | 2 ++
1 file changed, 2 insertions(+)
diff --git a/api.md b/api.md
index 96c389c..4a733f1 100644
--- a/api.md
+++ b/api.md
@@ -82,6 +82,8 @@ Action|Description|Parameters
`getRoutingTable`|Returns the routing table of the Pineapple|_none_
`restartDNS`|Restarts the DNS service on the Pineapple|_none_
`updateRoute`|Updates the routing table|- `routeInterface`
+`getAdvancedData`|Returns the hostname and ifconfig|_none_
+`setHostname`|Sets the hostname for the Pineapple|
### PineAP
#### Description
### Recon
From 7b8f63ae28f4930e364c1518950944390118bfa8 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Mon, 4 Apr 2016 19:26:13 +0100
Subject: [PATCH 16/51] Add more networking API to the table
---
api.md | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/api.md b/api.md
index 4a733f1..b40a193 100644
--- a/api.md
+++ b/api.md
@@ -84,6 +84,14 @@ Action|Description|Parameters
`updateRoute`|Updates the routing table|- `routeInterface`
`getAdvancedData`|Returns the hostname and ifconfig|_none_
`setHostname`|Sets the hostname for the Pineapple|
+`resetWirelessConfig`|Resets the Wireless Configuration for the Pineapple|_none_
+`getInterfaceList`|Returns an array of available network interfaces|_none_
+`saveAPConfig`|Writes properties to the AP configuration|- `selectedChannel`
- Channel for the AP to operate on
- `openSSID`
- String for the SSID of the Open Access Point
- `hideOpenAP`
- Boolean to hide the Open Access Point or not
- `managementSSID`
- String for the SSID of the Management AP
- `managementKey`
- string for the WPA2 passphrase for the Management AP
- `disableManagementAP`
- Boolean to disable the Management AP or not
+`getAPConfig`|Returns an array of properties from the access point configuration.|_none_
+`getMacData`|Returns the MAC Addresses of each of the wireless interfaces|_none_
+`setMac`|Sets the MAC address for a specified interface|- `random`
- Boolean to set the MAC address as a random value.
- `interface`
- The interface you want to change the MAC address of
- `mac`
- The new MAC address of the interface
+`resetMac`|Reset the specified interface's MAC address to the factory default.|
+
### PineAP
#### Description
### Recon
From 8d5260348b4683a0485d54dbfa296ea6bde6eda8 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Mon, 4 Apr 2016 19:37:00 +0100
Subject: [PATCH 17/51] Add brief description to the Networking section
---
api.md | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/api.md b/api.md
index b40a193..8672f67 100644
--- a/api.md
+++ b/api.md
@@ -77,6 +77,15 @@ Action|Description|Parameters
#### Description
### Networking
#### Description
+The Networking module API allows you to interface with the networking side of the WiFi Pineapple without having to write your own functions to manage interfaces, the DNS, and the routing table. As described above, you can use these actions in your own module like so:
+```
+{
+ "module": "Networking",
+ "action": "setHostname",
+ "hostname": "Pineapple"
+}
+```
+
Action|Description|Parameters
------|-----------|----------
`getRoutingTable`|Returns the routing table of the Pineapple|_none_
From dae6f8ecb786cf25d8e29017661065e197aef0a0 Mon Sep 17 00:00:00 2001
From: Marc
Date: Mon, 4 Apr 2016 19:39:07 +0100
Subject: [PATCH 18/51] Changed minimal -> minimum
---
api.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/api.md b/api.md
index 8672f67..d70068e 100644
--- a/api.md
+++ b/api.md
@@ -1,7 +1,7 @@
# WiFi Pineapple Module API
## Introduction
-Unlike the old web interface, the back end of the new interface has been decoupled from the front end. All requests to perform system actions are sent as POSTs to `/api/`. The content of the POST is JSON and contains a minimal of two parameters.
+Unlike the old web interface, the back end of the new interface has been decoupled from the front end. All requests to perform system actions are sent as POSTs to `/api/`. The content of the POST is JSON and contains a minimum of two parameters.
#### The first parameter key must be either `system` or `module`
`system` is used for core system functions such as logging users in and performing system setup as well as managing notifications. `module` is used when sending a request to any of the default modules or to any user modules. The value is set to the module with which you are trying to communicate. For example, `"system": "notifications"` or `"module": "RandomRoll"`.
#### The second parameter key `action`
From 444064f2a75dd11c46e7f031cf96cf322c0639b7 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Tue, 5 Apr 2016 09:23:43 -0400
Subject: [PATCH 19/51] Update api.md
---
api.md | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/api.md b/api.md
index d70068e..54bd797 100644
--- a/api.md
+++ b/api.md
@@ -17,6 +17,8 @@ Many actions do not require additional parameters. For instance, `{"system": "no
```
## Authentication
+_(Please note that authentication not required when using the angular module api due to the fact that client side module components are loaded after the user authenticates their browser)_
+
There are a couple ways to authenticate with the pineapple. Requests sent via the web interface use a PHPSESSID cookie as well as an X-XSRF-TOKEN header. The pineapple will verify that the session is valid and logged in and that the XSRF token matches the one generated at the start of the session. If both of these conditions are met, the request is routed. An example of a request sent by chrome is as follows:
```
POST /api/ HTTP/1.1
@@ -49,6 +51,13 @@ If the `apiToken` parameter is valid, the request will be route; otherwise an er
## Modules
### Advanced
#### Description
+The advanced module simplifies some more advanced processes like performing system upgrades and clearing system caches. FOr example, the following will clear the pineapple's caches:
+```
+{
+ "module": "Advanced",
+ "action": "dropCaches"
+}
+```
Action|Description|Parameters
------|-----------|----------
`getResources`|Returns a JSON array of disk and memory usage|_none_
@@ -103,6 +112,7 @@ Action|Description|Parameters
### PineAP
#### Description
+
### Recon
#### Description
### Reporting
From 825618fe8f2286539d255efebf81129cde09e95f Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Tue, 5 Apr 2016 09:24:25 -0400
Subject: [PATCH 20/51] Update api.md
---
api.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/api.md b/api.md
index 54bd797..63744b0 100644
--- a/api.md
+++ b/api.md
@@ -17,7 +17,7 @@ Many actions do not require additional parameters. For instance, `{"system": "no
```
## Authentication
-_(Please note that authentication not required when using the angular module api due to the fact that client side module components are loaded after the user authenticates their browser)_
+_(Please note that extra authentication parameters are not required when using the angular module api due to the fact that client side module components are loaded after the user authenticates their browser)_
There are a couple ways to authenticate with the pineapple. Requests sent via the web interface use a PHPSESSID cookie as well as an X-XSRF-TOKEN header. The pineapple will verify that the session is valid and logged in and that the XSRF token matches the one generated at the start of the session. If both of these conditions are met, the request is routed. An example of a request sent by chrome is as follows:
```
From 9252782bcf5c862777c56ad25f714060552289d7 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Tue, 5 Apr 2016 10:20:57 -0400
Subject: [PATCH 21/51] Update api.md
---
api.md | 21 ++++++++++++++++++++-
1 file changed, 20 insertions(+), 1 deletion(-)
diff --git a/api.md b/api.md
index 63744b0..1e19341 100644
--- a/api.md
+++ b/api.md
@@ -112,7 +112,26 @@ Action|Description|Parameters
### PineAP
#### Description
-
+The PineAP module provides an easy way to interface with the [PineAP suite](/#!index.md#The_PineAP_Suite). For example, one might use the following to add an SSID to PineAP's pool:
+```
+{
+ "module": "PineAP",
+ "action": "addSSID",
+ "ssid": "ACME WiFi"
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`getPool`|Returns an array of the SSIDs in PineAP's pool|_none_
+`clearPool`|Clears the PineAP pool|_none_
+`addSSID`|Adds an SSID to the pool|- ssid
+`removeSSID`|Removes an SSID from the pool|- ssid
+`setPineAPSettings`|Update PineAP's settings| - settings
- A dictionary with setting key/value pairs
- allowAssociations
- Whether clients should be allowed to associate to the pineapple
- logProbes
- Whether to log probe requests
- logAssociations
- Whether to log associations
- beaconResponses
- Whether to send beacon responses
- captureSSIDs
- Whether to add sniffed SSIDs to the pool
- broadcastSSIDs
- Whether to broadcast the SSID pool
- beaconInterval
- The beacon interval- must be one of "low", "normal" or "aggressive"
- responseInterval
- The response interval- must be one of "low", "normal" or "aggressive"
- targetMAC
- The MAC to target with responses
- sourceMAC
- The MAC PineAP should spoof
+`getPineAPSettings`|Returns a dictionary with all the current PineAP settings|_none_
+`enable`|Enables PineAP|_none_
+`disable`|Disables PineAP|_none_
+`saveAsDefault`|Makes the current configuration persist after reboots|_none_
+`downloadPineAPPool`|Get a download link to the SSID pool (useful for client side modules)|_none_
### Recon
#### Description
### Reporting
From 6c36302073012eecf87e0d9a3dbe25732f3a778a Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Tue, 5 Apr 2016 10:22:32 -0400
Subject: [PATCH 22/51] Update api.md
---
api.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/api.md b/api.md
index 1e19341..b778be3 100644
--- a/api.md
+++ b/api.md
@@ -126,7 +126,7 @@ Action|Description|Parameters
`clearPool`|Clears the PineAP pool|_none_
`addSSID`|Adds an SSID to the pool|- ssid
`removeSSID`|Removes an SSID from the pool|- ssid
-`setPineAPSettings`|Update PineAP's settings| - settings
- A dictionary with setting key/value pairs
- allowAssociations
- Whether clients should be allowed to associate to the pineapple
- logProbes
- Whether to log probe requests
- logAssociations
- Whether to log associations
- beaconResponses
- Whether to send beacon responses
- captureSSIDs
- Whether to add sniffed SSIDs to the pool
- broadcastSSIDs
- Whether to broadcast the SSID pool
- beaconInterval
- The beacon interval- must be one of "low", "normal" or "aggressive"
- responseInterval
- The response interval- must be one of "low", "normal" or "aggressive"
- targetMAC
- The MAC to target with responses
- sourceMAC
- The MAC PineAP should spoof
+`setPineAPSettings`|Update PineAP's settings| - `settings`
- A dictionary with setting key/value pairs
- `allowAssociations`
- Whether clients should be allowed to associate to the pineapple
- `logProbes`
- Whether to log probe requests
- `logAssociations`
- Whether to log associations
- `beaconResponses`
- Whether to send beacon responses
- `captureSSIDs`
- Whether to add sniffed SSIDs to the pool
- `broadcastSSIDs`
- Whether to broadcast the SSID pool
- `beaconInterval`
- The beacon interval- must be one of "low", "normal" or "aggressive"
- `responseInterval`
- The response interval- must be one of "low", "normal" or "aggressive"
- `targetMAC`
- The MAC to target with responses
- `sourceMAC`
- The MAC PineAP should spoof
`getPineAPSettings`|Returns a dictionary with all the current PineAP settings|_none_
`enable`|Enables PineAP|_none_
`disable`|Disables PineAP|_none_
From 0e6a9bde476067478c001c2d71802b7a23135243 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Tue, 5 Apr 2016 10:25:25 -0400
Subject: [PATCH 23/51] Update api.md
---
api.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/api.md b/api.md
index b778be3..d8964f7 100644
--- a/api.md
+++ b/api.md
@@ -124,8 +124,8 @@ Action|Description|Parameters
------|-----------|----------
`getPool`|Returns an array of the SSIDs in PineAP's pool|_none_
`clearPool`|Clears the PineAP pool|_none_
-`addSSID`|Adds an SSID to the pool|- ssid
-`removeSSID`|Removes an SSID from the pool|- ssid
+`addSSID`|Adds an SSID to the pool|- `ssid`
+`removeSSID`|Removes an SSID from the pool|- `ssid`
- The SSID string to remove
`setPineAPSettings`|Update PineAP's settings| - `settings`
- A dictionary with setting key/value pairs
- `allowAssociations`
- Whether clients should be allowed to associate to the pineapple
- `logProbes`
- Whether to log probe requests
- `logAssociations`
- Whether to log associations
- `beaconResponses`
- Whether to send beacon responses
- `captureSSIDs`
- Whether to add sniffed SSIDs to the pool
- `broadcastSSIDs`
- Whether to broadcast the SSID pool
- `beaconInterval`
- The beacon interval- must be one of "low", "normal" or "aggressive"
- `responseInterval`
- The response interval- must be one of "low", "normal" or "aggressive"
- `targetMAC`
- The MAC to target with responses
- `sourceMAC`
- The MAC PineAP should spoof
`getPineAPSettings`|Returns a dictionary with all the current PineAP settings|_none_
`enable`|Enables PineAP|_none_
From 83ad5d96ffa9ac458a861ecafd62151307ac22c3 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Tue, 5 Apr 2016 11:28:00 -0400
Subject: [PATCH 24/51] Update api.md
---
api.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/api.md b/api.md
index d8964f7..6648257 100644
--- a/api.md
+++ b/api.md
@@ -128,6 +128,7 @@ Action|Description|Parameters
`removeSSID`|Removes an SSID from the pool|- `ssid`
- The SSID string to remove
`setPineAPSettings`|Update PineAP's settings| - `settings`
- A dictionary with setting key/value pairs
- `allowAssociations`
- Whether clients should be allowed to associate to the pineapple
- `logProbes`
- Whether to log probe requests
- `logAssociations`
- Whether to log associations
- `beaconResponses`
- Whether to send beacon responses
- `captureSSIDs`
- Whether to add sniffed SSIDs to the pool
- `broadcastSSIDs`
- Whether to broadcast the SSID pool
- `beaconInterval`
- The beacon interval- must be one of "low", "normal" or "aggressive"
- `responseInterval`
- The response interval- must be one of "low", "normal" or "aggressive"
- `targetMAC`
- The MAC to target with responses
- `sourceMAC`
- The MAC PineAP should spoof
`getPineAPSettings`|Returns a dictionary with all the current PineAP settings|_none_
+`deauth`|Deauth a list of clients from a station. **_Use this with caution. The misuse of this function may be illegal in some places._**|- `sta`
- The bssid of the station from which to disconnect the clients
- `clients`
- An array of client MACs to deauth
- `multiplier`
- The number of deauths (from 1 to 10) to send
- `channel`
- The channel to hop to before sending the frame(s)
`enable`|Enables PineAP|_none_
`disable`|Disables PineAP|_none_
`saveAsDefault`|Makes the current configuration persist after reboots|_none_
From 569330b4c1313164ff7f518a6a4d4a161338b619 Mon Sep 17 00:00:00 2001
From: Marc
Date: Tue, 5 Apr 2016 23:39:39 +0100
Subject: [PATCH 25/51] Create creating_modules.md
---
creating_modules.md | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/creating_modules.md b/creating_modules.md
index da9acf5..de0c864 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -1,3 +1,10 @@
# Creating WiFi Pineapple Modules
-Work in progress
+##Introduction
+With the new WiFi Pineapple Interface, It is easy to create modules that use the new [API](api.md).
+Modules use HTML, AngularJS and PHP to make requests and retrieve a response. The new interface and the modules also use Bootstrap.
+// TODO: write better Introduction
+
+
+##Anatomy of a basic module
+A basic module will request information through AngularJS to PHP, and then PHP will provide a response to AngularJS, where it will then be displayed on the page.
From 342e9fb6685e1bb8d4ec1666db86b56ea9cf1ec4 Mon Sep 17 00:00:00 2001
From: Marc
Date: Tue, 5 Apr 2016 23:47:08 +0100
Subject: [PATCH 26/51] Hopefully this doesnt look awful
---
creating_modules.md | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/creating_modules.md b/creating_modules.md
index de0c864..7f68812 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -3,8 +3,14 @@
##Introduction
With the new WiFi Pineapple Interface, It is easy to create modules that use the new [API](api.md).
Modules use HTML, AngularJS and PHP to make requests and retrieve a response. The new interface and the modules also use Bootstrap.
+
// TODO: write better Introduction
##Anatomy of a basic module
-A basic module will request information through AngularJS to PHP, and then PHP will provide a response to AngularJS, where it will then be displayed on the page.
+A basic module will request information through AngularJS to PHP, and then the PHP will provide a response to AngularJS, where it will then be displayed on the HTML page for the user to see.
+```
++-------------------+ +--------------+ +-----------+ +------+
+| AngularJS Request | --> | PHP Response | --> | AngularJS | --> | HTML |
++-------------------+ +--------------+ +-----------+ +------+
+```
From 7a16bab7eb55a03da9044007f43f49f48000a2c7 Mon Sep 17 00:00:00 2001
From: Marc
Date: Wed, 6 Apr 2016 00:00:40 +0100
Subject: [PATCH 27/51] Add information about structure
---
creating_modules.md | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/creating_modules.md b/creating_modules.md
index 7f68812..2952351 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -9,8 +9,20 @@ Modules use HTML, AngularJS and PHP to make requests and retrieve a response. Th
##Anatomy of a basic module
A basic module will request information through AngularJS to PHP, and then the PHP will provide a response to AngularJS, where it will then be displayed on the HTML page for the user to see.
+
```
+-------------------+ +--------------+ +-----------+ +------+
| AngularJS Request | --> | PHP Response | --> | AngularJS | --> | HTML |
+-------------------+ +--------------+ +-----------+ +------+
```
+
+A module will contain at least four files required to function. A `module.html` that contains the HTML for the module, A `module.info` that contains the name, description, version and author of the module in JSON format, a `module.js` file inside of the `js/` folder that contains the AngularJS, and finally a `module.php` file inside of the `php/` folder. It is structured like this:
+```
+.
+├── js
+│ └── module.js
+├── module.html
+├── module.info
+└── php
+ └── module.php
+```
From 0302cc0bde26b54785fc1f7cc363683f9efac8f7 Mon Sep 17 00:00:00 2001
From: Marc
Date: Wed, 6 Apr 2016 00:32:47 +0100
Subject: [PATCH 28/51] Start creating the module, add general information
---
creating_modules.md | 37 +++++++++++++++++++++++++++++++++++++
1 file changed, 37 insertions(+)
diff --git a/creating_modules.md b/creating_modules.md
index 2952351..81628a6 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -26,3 +26,40 @@ A module will contain at least four files required to function. A `module.html`
└── php
└── module.php
```
+
+Modules are stored on the WiFi Pineapple at `/pineapple/modules/`.
+
+##Creating a module
+You can create the module files on the WiFi Pineapple with ease using the [Module Maker](https://www.wifipineapple.com/modules) module. It will create the initial files for you (with an example included), and will also allow you to package the module for distribution when you are finished.
+
+After downloading the module, enter the correct information into the Name, Description, Version and Author fields and click "Generate". Your module will then be ready to download and edit. Open the module in your favorite text editor.
+
+### An example module
+This example will teach you how to make requests, obtain data, and return it back to the HTML.
+
+#### module.html
+The WiFi Pineapple modules make use of Bootstrap to provide a good mobile viewing experience and a clean look. Module developers are encouraged to make use of Bootstrap components, such as responsive tables and the grid system. To learn more about Bootstrap, visit the [Bootstrap Website](https://getbootstrap.com).
+
+In this example we will make a `div` that is the width of the webpage. To do this, we will create a row, and then our `div` element which will use the `col-md-12` Bootstrap class.
+
+Your code should look like this:
+```
+
+```
+
+As the module is written with AngularJS, the HTML must be hooked up to a controller. For more information on AngularJS, visit the [AngularJS](https://angularjs.org) website.
+
+To hook up the HTML to a controller, we will use our `div` element with the argument `ng-controller="ControllerName"`. For this example, our controller will be referred to as `ExampleController`. This div is now able to interact with your AngularJS inside of the `module.js` file.
+
+Your code should now look like this:
+```
+
+```
From dba53157fd8f68c85d13e2b24de1632f0993b13c Mon Sep 17 00:00:00 2001
From: Marc
Date: Wed, 6 Apr 2016 00:33:38 +0100
Subject: [PATCH 29/51] Remove useless text
---
creating_modules.md | 3 ---
1 file changed, 3 deletions(-)
diff --git a/creating_modules.md b/creating_modules.md
index 81628a6..9ea08e2 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -34,9 +34,6 @@ You can create the module files on the WiFi Pineapple with ease using the [Modul
After downloading the module, enter the correct information into the Name, Description, Version and Author fields and click "Generate". Your module will then be ready to download and edit. Open the module in your favorite text editor.
-### An example module
-This example will teach you how to make requests, obtain data, and return it back to the HTML.
-
#### module.html
The WiFi Pineapple modules make use of Bootstrap to provide a good mobile viewing experience and a clean look. Module developers are encouraged to make use of Bootstrap components, such as responsive tables and the grid system. To learn more about Bootstrap, visit the [Bootstrap Website](https://getbootstrap.com).
From 0f14fb504eeaabd4b39279b59295a5abcef3f706 Mon Sep 17 00:00:00 2001
From: Marc
Date: Wed, 6 Apr 2016 00:39:32 +0100
Subject: [PATCH 30/51] Finish module.html section (for now)
---
creating_modules.md | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/creating_modules.md b/creating_modules.md
index 9ea08e2..80a1e25 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -60,3 +60,15 @@ Your code should now look like this:
```
+
+Finally, we will use an expression called `hello`. This is done with `{{hello}}`. Later, we will use this expression to display text from our PHP. You can learn more at [AngularJS - Scopes](https://docs.angularjs.org/guide/expression).
+
+Our HTML code should now look like this:
+```
+
+
+#### module.js
From 55ee6d1da278e9b5df848c64bc63a99e94b82a54 Mon Sep 17 00:00:00 2001
From: Marc
Date: Wed, 6 Apr 2016 00:40:28 +0100
Subject: [PATCH 31/51] Add backticks to example
---
creating_modules.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/creating_modules.md b/creating_modules.md
index 80a1e25..9c7725d 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -70,5 +70,6 @@ Our HTML code should now look like this:
{{hello}}
+```
#### module.js
From 8101f3a0079c1d948415a54bee91a88a6fc800ad Mon Sep 17 00:00:00 2001
From: Marc
Date: Wed, 6 Apr 2016 00:52:29 +0100
Subject: [PATCH 32/51] rename scopes->expressions
---
creating_modules.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/creating_modules.md b/creating_modules.md
index 9c7725d..3b5fcf7 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -61,7 +61,7 @@ Your code should now look like this:
```
-Finally, we will use an expression called `hello`. This is done with `{{hello}}`. Later, we will use this expression to display text from our PHP. You can learn more at [AngularJS - Scopes](https://docs.angularjs.org/guide/expression).
+Finally, we will use an expression called `hello`. This is done with `{{hello}}`. Later, we will use this expression to display text from our PHP. You can learn more at [AngularJS - Expression](https://docs.angularjs.org/guide/expression).
Our HTML code should now look like this:
```
From d3f2f87fbc2abd66d5336acd79e150e839d01034 Mon Sep 17 00:00:00 2001
From: Marc
Date: Wed, 6 Apr 2016 00:56:04 +0100
Subject: [PATCH 33/51] fix file names (php->api)
---
creating_modules.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/creating_modules.md b/creating_modules.md
index 3b5fcf7..4214e89 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -16,14 +16,14 @@ A basic module will request information through AngularJS to PHP, and then the P
+-------------------+ +--------------+ +-----------+ +------+
```
-A module will contain at least four files required to function. A `module.html` that contains the HTML for the module, A `module.info` that contains the name, description, version and author of the module in JSON format, a `module.js` file inside of the `js/` folder that contains the AngularJS, and finally a `module.php` file inside of the `php/` folder. It is structured like this:
+A module will contain at least four files required to function. A `module.html` that contains the HTML for the module, A `module.info` that contains the name, description, version and author of the module in JSON format, a `module.js` file inside of the `js/` folder that contains the AngularJS, and finally a `module.php` file inside of the `api/` folder. It is structured like this:
```
.
├── js
│ └── module.js
├── module.html
├── module.info
-└── php
+└── api
└── module.php
```
From dfac42092f586909bfb5fb34d339ebdc4eded612 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Wed, 6 Apr 2016 09:37:11 +0100
Subject: [PATCH 34/51] TODO
---
creating_modules.md | 1 +
1 file changed, 1 insertion(+)
diff --git a/creating_modules.md b/creating_modules.md
index 4214e89..15f5de9 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -73,3 +73,4 @@ Our HTML code should now look like this:
```
#### module.js
+# TODO: Continue
From 1d0de4f58e97e9d972d32b3f8b6952ee6e7613f0 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Wed, 6 Apr 2016 09:37:54 +0100
Subject: [PATCH 35/51] neaten
---
creating_modules.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/creating_modules.md b/creating_modules.md
index 15f5de9..d78eea2 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -67,7 +67,7 @@ Our HTML code should now look like this:
```
- {{hello}}
+ {{ hello }}
```
From 87b56c9351e7c50f9c0afadf62e5eba2179c2b46 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Sun, 8 May 2016 21:08:34 +0100
Subject: [PATCH 36/51] Add Javascript information
---
creating_modules.md | 34 +++++++++++++++++++++++++++++++++-
1 file changed, 33 insertions(+), 1 deletion(-)
diff --git a/creating_modules.md b/creating_modules.md
index d78eea2..85c1e84 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -73,4 +73,36 @@ Our HTML code should now look like this:
```
#### module.js
-# TODO: Continue
+The module.js contains the AngularJS for your module. As described above, this is the middle "layer" between the HTML and PHP. AngularJS is a Javascript framework created by Google, and allows you to create responsive and dynamic webpages. This is useful with the WiFi Pineapple interface because it lets us update the HTML with changing content.
+
+To start, we can use a built in API function, `registerController()`. This allows us to easily create controllers for our module. An empty controller would look like this:
+```
+registerController("ExampleController", ['$api', '$scope', function($api, $scope) {
+
+}])
+```
+Here we register the name of the controller, `"ExampleController"`. Then we include our dependencies, usually the WiFi Pineapple API, with `$api` and then the scope of your module, with `$scope`.
+
+Now we will add a variable inside our scope called `hello`, like so:
+```
+registerController("ExampleController", ['$api', '$scope', function($api, $scope) {
+ $scope.text = "Hello World!";
+}])
+```
+
+Our HTML will now output "Hello World!".
+
+We can however get dynamic data, passed from our PHP. To do this, we can use the `$api.request()` function:
+```
+registerController("ExampleController", ['$api', '$scope', function($api, $scope) {
+ $api.request({
+ module: 'ExampleModule',
+ action: 'getHello'
+ }, function(response) {
+ $scope.text = response.text;
+ });
+}])
+```
+This will send a request to our module.php, and take its response and set `$scope.text` to `response.text`.
+
+#### module.php
From 974e9db6c141d1b04d50d5df35d1c1ef311204cd Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Sun, 8 May 2016 22:12:56 +0100
Subject: [PATCH 37/51] Add PHP info.
---
creating_modules.md | 49 +++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 49 insertions(+)
diff --git a/creating_modules.md b/creating_modules.md
index 85c1e84..37cb1a9 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -106,3 +106,52 @@ registerController("ExampleController", ['$api', '$scope', function($api, $scope
This will send a request to our module.php, and take its response and set `$scope.text` to `response.text`.
#### module.php
+The module.php contains all PHP code and can directly interface with other modules, talk to the Javascript and access the WiFi Pineapple API. In this guide, we will finish our Example Module by making it reply to our AngularJS request and return a string containing "Hello World!".
+
+To start, we must extend the `Module` class inside of the `pineapple` namespace. We must then add the method to handle our requests.:
+```
+request->action) {
+ case 'getHello':
+ $this->hello();
+ break;
+ }
+ }
+}
+```
+
+This snippet of code will loop over every action it receieves from the Javascript. In our case it is `getHello`. Once it finds `getHello` it will execute a function called `hello()` that we will define next. After the route() function:
+```
+private function hello()
+{
+ $this->response = array('text' => "Hello World");
+}
+```
+
+Once this function is executed it will simply create an array with a property called text equaling "Hello World". All together, your code will look like this:
+```
+request->action) {
+ case 'getHello':
+ $this->hello();
+ break;
+ }
+ }
+
+ private function hello()
+ {
+ $this->response = array('text' => "Hello World");
+ }
+}
+```
+Our PHP is now complete, and when the HTML is loaded, it will now display the "Hello World" string from your module.php.
From 4c5c9a6d8d3bfa8715835b08cae0e36f44608945 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Sun, 8 May 2016 22:15:20 +0100
Subject: [PATCH 38/51] Remove TODO
---
creating_modules.md | 2 --
1 file changed, 2 deletions(-)
diff --git a/creating_modules.md b/creating_modules.md
index 37cb1a9..f37c3cc 100644
--- a/creating_modules.md
+++ b/creating_modules.md
@@ -4,8 +4,6 @@
With the new WiFi Pineapple Interface, It is easy to create modules that use the new [API](api.md).
Modules use HTML, AngularJS and PHP to make requests and retrieve a response. The new interface and the modules also use Bootstrap.
-// TODO: write better Introduction
-
##Anatomy of a basic module
A basic module will request information through AngularJS to PHP, and then the PHP will provide a response to AngularJS, where it will then be displayed on the HTML page for the user to see.
From eb87e66346c8e7b5502256c595fc818b2dfe0f56 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 19:33:10 +0100
Subject: [PATCH 39/51] Start ModuleManager info
---
api.md | 13 +++++++++++++
1 file changed, 13 insertions(+)
diff --git a/api.md b/api.md
index 6648257..579aa03 100644
--- a/api.md
+++ b/api.md
@@ -84,6 +84,19 @@ Action|Description|Parameters
#### Description
### ModuleManager
#### Description
+The Module Manager is responsible for installing, removing, and upgrading modules. It's API can be used to manage modules, as well as fetching the list of installed modules and getting available modules. To use them in your module, your request body would look like this:
+```
+{
+ "module": "ModuleManager",
+ "action": "removeModule",
+ "moduleName": "Module"
+}
+```
+
+Action|Description|Parameters
+------|-----------|----------
+`getAvailableModules`|Return an array of modules available for download|_none_
+`getInstalledModules`|Return an array of modules currently installed|_none_
### Networking
#### Description
The Networking module API allows you to interface with the networking side of the WiFi Pineapple without having to write your own functions to manage interfaces, the DNS, and the routing table. As described above, you can use these actions in your own module like so:
From 5af06fa23f886f3ba8df4ee2d96c781aba8bbd11 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 19:42:56 +0100
Subject: [PATCH 40/51] upd8
---
api.md | 2 ++
1 file changed, 2 insertions(+)
diff --git a/api.md b/api.md
index 579aa03..af5b339 100644
--- a/api.md
+++ b/api.md
@@ -1,4 +1,5 @@
# WiFi Pineapple Module API
+#TODO: Add available destinations for ModuleManager.
## Introduction
Unlike the old web interface, the back end of the new interface has been decoupled from the front end. All requests to perform system actions are sent as POSTs to `/api/`. The content of the POST is JSON and contains a minimum of two parameters.
@@ -97,6 +98,7 @@ Action|Description|Parameters
------|-----------|----------
`getAvailableModules`|Return an array of modules available for download|_none_
`getInstalledModules`|Return an array of modules currently installed|_none_
+`installModule`|Install a module|- `moduleName`
- Name of module to install
- `destination`
### Networking
#### Description
The Networking module API allows you to interface with the networking side of the WiFi Pineapple without having to write your own functions to manage interfaces, the DNS, and the routing table. As described above, you can use these actions in your own module like so:
From 67472c20a720fd4766ddf86b4ca8d0dcd78912e7 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 19:51:28 +0100
Subject: [PATCH 41/51] Complete Module Manager section
---
api.md | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/api.md b/api.md
index af5b339..22fb184 100644
--- a/api.md
+++ b/api.md
@@ -98,7 +98,12 @@ Action|Description|Parameters
------|-----------|----------
`getAvailableModules`|Return an array of modules available for download|_none_
`getInstalledModules`|Return an array of modules currently installed|_none_
-`installModule`|Install a module|
- `moduleName`
- Name of module to install
- `destination`
+`downloadModule`|Download a specified module|
- `moduleName`
- Name of module to install
- `destination`
+`installModule`|Install a specified module|
- `moduleName`
- Name of module to install
- `destination`
+`removeModule`|Remove a specified module|
+`downloadStatus`|Check status of module download|_none_
+`installStatus`|Check status of module install|_none_
+`checkDestination`|Check if the specified destination has the specified space free|
### Networking
#### Description
The Networking module API allows you to interface with the networking side of the WiFi Pineapple without having to write your own functions to manage interfaces, the DNS, and the routing table. As described above, you can use these actions in your own module like so:
From 645ad8534f80f8cfc89e5c80aa7b7d8924d3902f Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 20:03:08 +0100
Subject: [PATCH 42/51] Add logging section.
---
api.md | 16 ++++++++++++++++
1 file changed, 16 insertions(+)
diff --git a/api.md b/api.md
index 22fb184..f1031b9 100644
--- a/api.md
+++ b/api.md
@@ -83,6 +83,22 @@ Action|Description|Parameters
#### Description
### Logging
#### Description
+The Logging module provides easy access to the syslog, dmesg, PineAP and Reporting logs. To use these API functions, send your api request with the "module" set to "Logging":
+```
+{
+ "module": "Logging",
+ "action": "getSyslog",
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`getSyslog`|Return the system log in full|_none_
+`getDmesg`|Return the kernel log in full|_none_
+`getReportingLog`|Return the log from the Reporting module|_none_
+`getPineapLog`|Return the log from PineAP|_none_
+`clearPineapLog`|Clear the PineAP log file|_none_
+`getPineapLogLocation`|Return the location of the PineAP log|_none_
+`setPineapLogLocation`|Set the location for PineAP logging|- `location`
- New location of PineAP log.
### ModuleManager
#### Description
The Module Manager is responsible for installing, removing, and upgrading modules. It's API can be used to manage modules, as well as fetching the list of installed modules and getting available modules. To use them in your module, your request body would look like this:
From a19ad1b023977e783d2e92a9a0c014da114e567b Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 20:17:42 +0100
Subject: [PATCH 43/51] Add filters section.
---
api.md | 17 +++++++++++++++++
1 file changed, 17 insertions(+)
diff --git a/api.md b/api.md
index f1031b9..d4d20d9 100644
--- a/api.md
+++ b/api.md
@@ -81,6 +81,23 @@ Action|Description|Parameters
#### Description
### Filters
#### Description
+The filters module has API that will allow you manage all aspects of the Filter module externally, such as getting client data or adding clients. It is used like so:
+```
+{
+ "module": "Filters",
+ "action": "getClientData"
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`getClientData`|Return an array of client filters. (Mode and Filters)|_none_
+`getSSIDData`|Return an array of SSID filters (Mode and Filters)|_none_
+`toggleClientMode`|Toggle between whitelist and blacklist mode for client filtering|_none_
+`toggleSSIDMode`|Toggle between whitelist and blacklist mode for SSID filtering|_none_
+`addClient`|Add client to filter|
+`addSSID`|Add SSID to filter|
+`removeClient`|Remove client from filter|
+`removeSSID`|Remove SSID from filter|
### Logging
#### Description
The Logging module provides easy access to the syslog, dmesg, PineAP and Reporting logs. To use these API functions, send your api request with the "module" set to "Logging":
From aee192154918c75663dc50b63859ca2b9c10ee3a Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 20:44:26 +0100
Subject: [PATCH 44/51] Add Dashboard section...:fire:
---
api.md | 15 ++++++++++++++-
1 file changed, 14 insertions(+), 1 deletion(-)
diff --git a/api.md b/api.md
index d4d20d9..076e4d0 100644
--- a/api.md
+++ b/api.md
@@ -52,7 +52,7 @@ If the `apiToken` parameter is valid, the request will be route; otherwise an er
## Modules
### Advanced
#### Description
-The advanced module simplifies some more advanced processes like performing system upgrades and clearing system caches. FOr example, the following will clear the pineapple's caches:
+The advanced module simplifies some more advanced processes like performing system upgrades and clearing system caches. For example, the following will clear the pineapple's caches:
```
{
"module": "Advanced",
@@ -79,6 +79,19 @@ Action|Description|Parameters
#### Description
### Dashboard
#### Description
+You can use the Dashboards API to return useful values such as CPU usage, total SSIDs, SSIDs discovered this session and uptime. For example, the following will get the bulletins:
+```
+{
+ "module": "Dashboard",
+ "action": "getBulletins"
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`getOverviewData`|Return an array containing `cpu`, `uptime`, `clients`, `SSIDs` and `newSSIDs`.|_none_
+`getLandingPageData`|Return all landing page browser stats|_none_
+`getBulletins`|Return bulletins|_none_
+
### Filters
#### Description
The filters module has API that will allow you manage all aspects of the Filter module externally, such as getting client data or adding clients. It is used like so:
From 9cb8d4d6698da35623df01fd5260e8744245520e Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Fri, 13 May 2016 18:31:49 -0400
Subject: [PATCH 45/51] Finish documenting modules
---
api.md | 79 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
1 file changed, 78 insertions(+), 1 deletion(-)
diff --git a/api.md b/api.md
index 076e4d0..7d5665f 100644
--- a/api.md
+++ b/api.md
@@ -75,8 +75,42 @@ Action|Description|Parameters
`getCurrentVersion`|Returns the current firmware version on the pineapple|_none_
### Clients
#### Description
+The Clients module allows for the monitoring and management of connected clients. For example, the following would kick the client with the MAC address `aa:bb:cc:dd:ee:ff`:
+```
+{
+ "module": "Clients",
+ "action": "kickClient",
+ "mac": "aa:bb:cc:dd:ee:ff"
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`getClientData`|Returns a JSON array of connected clients|_none_
+`kickClient`|Kicks (disconnects) a connected client from the pineapple|- `mac`
- The MAC address of the client to be kicked
+
### Configuration
#### Description
+The configuration module allows for the modification of several pineapple configuration options such as timezone and landing page. The example below would set the landing page content to `Pineapples are yummy`:
+```
+{
+ "module": "Configuration",
+ "action": "saveLandingPage",
+ "landingPageData": "Pineapples are yummy"
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`getCurrentTimeZone`|Retrieves the current timezone of the pineapple|_none_
+`changeTimeZone`|Changes the pineapple's timezone|- `timeZone`
- The timezone to switch to
+`getLandingPageData`|Gets the current landing page data|_none_
+`saveLandingPage`|Changes the landing page content|- `landingPageData`
- The text to which the landing page will be set
+`changePassword`|Changes the password for the root user|- `newPassword`
- The new password for the root user
- `newPasswordRepeat`
- For verification, must be the same as `newPassword`
- oldPassword
The current password for root
+`resetPineapple`|Resets the pineapple (executes `mtd erase rootfs_data`)|_none_
+`haltPineapple`|Halts the pineapple|_none_
+`rebootPineapple`|Reboots the pineapple|_none_
+`getLandingPageStatus`|Shows whether the landing page is enabled or not|_none_
+`enableLandingPage`|Enables the landing page|_none_
+`disableLandingPage`|Disables the landing page|_none_
### Dashboard
#### Description
You can use the Dashboards API to return useful values such as CPU usage, total SSIDs, SSIDs discovered this session and uptime. For example, the following will get the bulletins:
@@ -201,11 +235,54 @@ Action|Description|Parameters
`downloadPineAPPool`|Get a download link to the SSID pool (useful for client side modules)|_none_
### Recon
#### Description
+The recon module allows for the detection of access points and clients within range of the pineapple. The following example would scan for nearby access points:
+```
+{
+ "module": "Recon",
+ "action": "startScan",
+ "scanType": "apOnly"
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`startScan`|Starts a new scan|- `scanType`
- The type of scan to perform (either `apOnly` or `clientAp`)
- `scanDuration`
- The duration to of time (in seconds) to scan for
+`scanStatus`|Get the status or results of a scan|- `scan`
- A JSON encoded scan object (e.g.`{"scanID": "1234567895", "scanType": "apOnly"}`)
+
### Reporting
#### Description
+The reporting module allows you to control the automatic reporting features of the pineapple. For example, the following would return report contents:
+```
+{
+ "module": "Reporting",
+ "action": "getReportContents"
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`getReportConfiguration`|Gets the current reporting configuration|_none_
+`getReportContents`|Gets the report contents|_none_
+`getEmailConfiguration`|Gets the current email configuration for reporting|_none_
+`setReportConfiguration`|Changes the report configuration|- config
- A JSON object containing the new configuration (eg. `{"storeReport": true, "sendReport": true, "interval": 1, "generateReport": true}`)
+`setReportContents`|Set which items get reported|- config
- A JSON object containing the new configuration (eg. `{"pineAPLog": true, "clearLog": true, "siteSurvey": false, "siteSurveyDuration": 0, "client": false, "tracking": false}`)
+`setEmailConfiguration`|Set the email configuration|
### Tracking
#### Description
-
+Tracking allows you to create custom scripts for tracking clients. The following example would set a new tracking script:
+```
+{
+ "module": "Tracking",
+ "action": "saveScript",
+ "trackingScript": "#!/bin/bash\n\nMAC=$1\nTYPE=$2 # 0 PROBE; 1 ASSOCIATION\nSSID=$3\n"
+}
+```
+Action|Description|Parameters
+------|-----------|----------
+`getScript`|Gets the current tracking script contents|_none_
+`saveScript`|Sets the current tracking script contents|- `trackingScript`
- The tracking script contents
+`getTrackingList`|Gets the current list of clients being tracked|_none_
+`addMac`|Adds a MAC to tracking|- `mac`
- The MAC address to start tracking
+`removeMac`|Removes a MAC from tracking|- `mac`
- The MAC address to stop tracking
## Community Python API
+
## Further Information
From b6ced623c0a01a8aac96da2d24a75a454f113e69 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Fri, 13 May 2016 18:38:34 -0400
Subject: [PATCH 46/51] Update api.md
---
api.md | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/api.md b/api.md
index 7d5665f..a9e95a0 100644
--- a/api.md
+++ b/api.md
@@ -283,6 +283,4 @@ Action|Description|Parameters
`addMac`|Adds a MAC to tracking|- `mac`
- The MAC address to start tracking
`removeMac`|Removes a MAC from tracking|- `mac`
- The MAC address to stop tracking
## Community Python API
-
-
-## Further Information
+A community python API wrapper exists [here](https://github.com/735tesla/python-pineapple) but documentation is still in progress.
From c63be13dd5c33eadcf50c05ba783c465c345b081 Mon Sep 17 00:00:00 2001
From: Henry Pitcairn <735tesla@gmail.com>
Date: Fri, 13 May 2016 18:38:53 -0400
Subject: [PATCH 47/51] Update api.md
---
api.md | 1 -
1 file changed, 1 deletion(-)
diff --git a/api.md b/api.md
index a9e95a0..b2681e0 100644
--- a/api.md
+++ b/api.md
@@ -1,5 +1,4 @@
# WiFi Pineapple Module API
-#TODO: Add available destinations for ModuleManager.
## Introduction
Unlike the old web interface, the back end of the new interface has been decoupled from the front end. All requests to perform system actions are sent as POSTs to `/api/`. The content of the POST is JSON and contains a minimum of two parameters.
From e17b803eeeb12b6ef3872284f448b1ccb9406371 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 23:39:02 +0100
Subject: [PATCH 48/51] Add destinations and remove todo
---
api.md | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/api.md b/api.md
index 7d5665f..e52253d 100644
--- a/api.md
+++ b/api.md
@@ -178,8 +178,8 @@ Action|Description|Parameters
------|-----------|----------
`getAvailableModules`|Return an array of modules available for download|_none_
`getInstalledModules`|Return an array of modules currently installed|_none_
-`downloadModule`|Download a specified module|- `moduleName`
- Name of module to install
- `destination`
-`installModule`|Install a specified module|
- `moduleName`
- Name of module to install
- `destination`
+`downloadModule`|Download a specified module|
- `moduleName`
- Name of module to install
- `destination`
- Destination of module.(`sdcard` or `internal`)
+`installModule`|Install a specified module|- `moduleName`
- Name of module to install
- `destination`
- Destination of module.(`sdcard` or `internal`)
`removeModule`|Remove a specified module|
`downloadStatus`|Check status of module download|_none_
`installStatus`|Check status of module install|_none_
From fa11010fb1a03c93e6caacf7e0d0946e9fea2953 Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 23:43:11 +0100
Subject: [PATCH 49/51] made wiv luv
---
api.md | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/api.md b/api.md
index e52253d..d138b33 100644
--- a/api.md
+++ b/api.md
@@ -1,5 +1,4 @@
# WiFi Pineapple Module API
-#TODO: Add available destinations for ModuleManager.
## Introduction
Unlike the old web interface, the back end of the new interface has been decoupled from the front end. All requests to perform system actions are sent as POSTs to `/api/`. The content of the POST is JSON and contains a minimum of two parameters.
@@ -286,3 +285,4 @@ Action|Description|Parameters
## Further Information
+made with love <3
From 9861cdf21ffdd622492754279d62e25a7de550fb Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 23:49:41 +0100
Subject: [PATCH 50/51] made with love
---
api.md | 6 +-----
1 file changed, 1 insertion(+), 5 deletions(-)
diff --git a/api.md b/api.md
index 1385f13..0362153 100644
--- a/api.md
+++ b/api.md
@@ -282,11 +282,7 @@ Action|Description|Parameters
`addMac`|Adds a MAC to tracking|- `mac`
- The MAC address to start tracking
`removeMac`|Removes a MAC from tracking|- `mac`
- The MAC address to stop tracking
## Community Python API
-<<<<<<< HEAD
-
## Further Information
-made with love <3
-=======
A community python API wrapper exists [here](https://github.com/735tesla/python-pineapple) but documentation is still in progress.
->>>>>>> c63be13dd5c33eadcf50c05ba783c465c345b081
+made with love <3
From 340022fffca2048ad7bcf02a0741352a30515daf Mon Sep 17 00:00:00 2001
From: Foxtrot
Date: Fri, 13 May 2016 23:53:05 +0100
Subject: [PATCH 51/51] move python info to right place, try to love
---
api.md | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/api.md b/api.md
index 0362153..104db93 100644
--- a/api.md
+++ b/api.md
@@ -281,8 +281,9 @@ Action|Description|Parameters
`getTrackingList`|Gets the current list of clients being tracked|_none_
`addMac`|Adds a MAC to tracking|- `mac`
- The MAC address to start tracking
`removeMac`|Removes a MAC from tracking|- `mac`
- The MAC address to stop tracking
+
## Community Python API
+A community python API wrapper exists [here](https://github.com/735tesla/python-pineapple) but documentation is still in progress.
## Further Information
-A community python API wrapper exists [here](https://github.com/735tesla/python-pineapple) but documentation is still in progress.
-made with love <3
+made with <3