Skip to main content


Showing posts from 2016

`` Debian init script

Startup init script for the Distributed WPA PSK strength auditor python script Turning the `` utility into a system daemon can be achieved by utilizing the `screen` utility, below is my first attempt at it - feel free to comment with improvements or questions. #!/bin/sh ### BEGIN INIT INFO # Provides: # Required-Start: $remote_fs $syslog # Required-Stop: $remote_fs $syslog # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start daemon at boot time # Description: Enable service provided by daemon. ### END INIT INFO # Symbolic link this file into your `/etc/init.d`, then run `rcconf` and select the script to start, note the file name must be alphanumeric only # example: `root@sh1:/etc/init.d# ln -s /usr/local/ help_crack` dir="/usr/local/" cmd="screen -d -m -S ./" user="" #!/bin/sh ### B

Lightning Out off Platform Example

Due to the limited documentation out there for the BETA Lightning Out functionality I am posting my code for others to benefit. Please note that after extensive research I have come to the conclusion that off platform functionality is broken, but executing the code from within a naked VF page should work. The issue is that the bootstrapping process does not adjust the URLs for the dynamically loaded scripts and styles sheets - the JS assumes it is still run from within a SF org domain. A case with SF has been filled but if I am incorrect on my conclusion please comment. Even if one patches the script/style URLs loading at runtime further errors manifest from withing aura_prod.js Salesforce's 'Lighting Out' Example Prior to using the below code ensure you have wrapped your lighting component into an App , setup a connected App , and CORS whitelisted your domain - afterwards copy and paste the below into your HTML file to be served from a server. ... <div

Windows Error: "Source Path Too Long"

Unable to delete folder due to 'path too long' error Windows dinosaur 256(?) path limitation weirdness prevented me from deleting a backup recovery folder, the solution to that is to use a utility called Unlocker - it also allows deletion/moving of locked files. If you found this useful feel free to follow me on twitter @danielsokolows or comment, also do donate the author of the program.

Softeher 'Error occurred. (Error code: 2)' sollution

Protocol error occurred. Error was returned from the destination server. The Softether server by default to run on port 443 , if you server also hosts normal https then 443 is already taken and so Softether can't bind to it. When you run `vpncmd` it attempts to connect, find an active port, but of course fails with 'Protocol error occurred. Error was returned from the destination server.' because it's not actually connecting to the vpn server. By default Softether also listens on 992 , 1194 , and 5555 so the sollution is to modify specify `localhost:5555` when executing the `vpncmnd`. If this has helped you feel free to comment or follow me on twitter @danielsokolows .

FIELD_INTEGRITY_EXCEPTION: Failed to save undefined: QualifiedName is required for descriptors: Source

Save error: A problem was encountered while invoking the subscription method If in the Salesforce 'Developer Console' you get the error mentioned in the subject or if you in Eclipse IDE you get: Save error: A problem was encountered while invoking the subscription method: No TOKENS named markup://c:defaultTokens foundproblem Save error: COMPONENT's markup cannot be empty. If you are trying to delete the Lightning definition bundle, directly delete the bundle instead. Save error: QualifiedName is required for descriptors Then ensure that you don't have an empty `controller=""` attribute, this took a me a little while to notice so for the prosperity of others and my own memory forming benefit I am posting this. If this has helped you feel free to follow @danielsokolows or thanks comment.

`fetch chromium` fails

Fix for: `Command '/usr/bin/python src/build/linux/sysroot_scripts/ --running-as-hook' returned non-zero exit status 1 in /root/chromium-src`. As part of some R&D for a JS framework I have been thinking of for a while I needed to do some Chromium hacking, problem is I hit a wall just simply attempting to check out the source code. This was on a fresh Debian VM machine following the official checkout docs . root@lh1:~/chromium-src# fetch --no-history chromium Running: gclient root Running: gclient config --spec 'solutions = [ { "url": "", "managed": False, "name": "src", "deps_file": ".DEPS.git", "custom_deps": {}, }, ] ' Running: gclient sync --no-history Error: Command '/usr/bin/python src/build/linux/sysroot_scripts/ --running-as-hook' returned non-zero exit status

Eclipse IDE Unable to Save to Server

"Save error: Package Visibility: Type is not visible: " If all other checks fail and you are actually able to reference ` ` than in my experience this error is caused due to the fact that the class you are working on has been updated on the server. Solution is to disable tooling api support in project properties. If this has helped you please comment or follow me @danielsokolows .

Emulate Bluetooh Keyboard using Windows PC

Control your Phone with Windows keyboard and mouse While at work, I have been on a search to control my phone through the computers keyboard and mouse. Today I have found Across software which is a possible solution, but unfortunatly Lumia 640 LTE lacks the proper bluetooth keyboard profile. If you find a solution to get Lumia 640 to work please post a comment.

I prefix my variables with their type!

Why 'Systems Hungarian' makes sense. As a developer, if you prefix the variable type you are clearly in the minority - I for one am a proponent of the Systems Hungarian notation, not the Apps Hungarian notation. The merits become apparent when reading other people's code, or when you look at your own code months/years after. Properly naming variables can be hard, the type is not always obvious from the name itself and left to individual interpenetration. Prefixing completely removes any uncertainty, it immediately reveals the type of the variable, and the developer reading the code does not have to go through the mental friction of inferring from either the name, or from how it is being used in the context, or traversing to where the variable was defined. For weakly typed languages like JS/Python it has the huge additional benefit of making debugging that much easier, when one treats the prefix as the intent of what should be the value stored it reveals possi

Salesforce Developer Console Not Showing Code Coverage

Code coverage highlighting lines missing from class editor It appears that in latest Winter 2016 upgrade a bug was introduced where code coverage line highlights are missing from the Salesforce Developer Console You can get them back by selecting the 'Test > Always Run Asynchronously' checkbox and re-running your test. If this has helped you please comment or follow me @danielsokolows .

LightScribe Template Labeler for Windows 10

LightScribe Template Labeler installation "Operating System Inadequate" Issue Unfortunately 'LightScribe Template Labeler' installation will not work on Windows 8 and Windows 10 machines as the install simply will error out with 'Operating System Inadequate'. Trying to install using compatibility mode did not help. Installing LightScribe Template Labeler Workaround However if you simply copy the installed folder from an older machine like Windows 7 into your `C:\\Program Files (x86)\LightScribe Template Labeler`, create a shortcut, then the software will still happily work, see: So you can install Windows 7 machine in a virtual machine, install 'LightScribe Template Labeler', and then copy the resulting folder to your Windows 8 or Windows 10 machine. For my own convenien