First they came for the Whistleblowers, and I did not speak out

nsa-logoFirst they came for the Whistleblowers, and I did not speak out—
Because I was not a Whistleblower.

Then they came for the Boing Boing Readers, and I did not speak out—
Because I was not a  Boing Boing Reader.

Then they came for the Linux Users, and I did not speak out—
Because I was not a Linux User.

Then they came for people who mocked the NSA, and I did not speak out—
Because I was not mocking the NSA.

Then they came for the Jews (they always eventually come for the Jews even when Jews think they are mainstream), and I did not speak out—
Because I was not a Jew.

Then they came for me—and there was no one left to speak for me.

CLI to Switch Amazon AWS Shell Environment Credentials

AwsCredsI work with many different AWS IAM Accounts and need to easily switch between these accounts. The good news is the AWS CLI tools now support a standard config file (~/.aws/config) that allows you to create profiles  for  multiple accounts in the one config file. You can select them when using the aws-cli with the --profile flag.

But many other tools don’t yet support the new format config file or multi-profiles. But they do support shell environment variables. So I wrote a simple ruby script that

  • Allows you to specify the profile name as an argument
  • Reads in the config file ~/.aws/config
  • Outputs the export statements for publishing the environment variables
    • You can eval the output to set the environment of your current shell session

So if you had a config file ~/.aws/config that looked like this:

[default]
aws_access_key_id=AKI***********2A
aws_secret_access_key=jt41************************************p
region=us-east-1

[profile foo]
aws_access_key_id=0K***************K82
aws_secret_access_key=2b+***********************************1g
region=us-east-1

[profile bar]
aws_access_key_id=AKI**************GA
aws_secret_access_key=MG************************************/d
region=us-east-1

If you don’t specify any argument to the command it will output the default profile:

 $ aws_switch
export AWS_ACCESS_KEY_ID=AKI***********2A
export AWS_SECRET_ACCESS_KEY=jt41************************************p
export AMAZON_ACCESS_KEY_ID=AKI***********2A
export AMAZON_SECRET_ACCESS_KEY=jt41************************************p
export AWS_ACCESS_KEY=AKI***********2A
export AWS_SECRET_KEY=jt41************************************p

If you specified a profile (in this case foo):

$ aws_switch foo
export AWS_ACCESS_KEY_ID=0K***************K82
export AWS_SECRET_ACCESS_KEY=2b+***********************************1g
export AMAZON_ACCESS_KEY_ID=0K***************K82
export AMAZON_SECRET_ACCESS_KEY=2b+***********************************1g
export AWS_ACCESS_KEY=0K***************K82
export AWS_SECRET_KEY=2b+***********************************1g

You would actually use it by eval’ing the output of aws_switch so it sets the variables in the environment of yhour current shell:

eval `aws_switch foo`

Here’s the code for aws_switch. Put it in someplace in your $PATH and make sure to chmod 0755 the file so its executable:

#!/usr/bin/env ruby
require 'inifile'

configs = IniFile.load(File.join(File.expand_path('~'), '.aws', 'config'))

profile_name_input = ARGV[0]
case profile_name_input
when 'default'
  profile_name = 'default'
when nil
  profile_name = 'default'
when ""
  profile_name = 'default'
else
  profile_name = "profile #{profile_name_input}"
end

id = configs[profile_name]['aws_access_key_id']
key = configs[profile_name]['aws_secret_access_key']

puts "export AWS_ACCESS_KEY_ID=#{id}"
puts "export AWS_SECRET_ACCESS_KEY=#{key}"
puts "export AMAZON_ACCESS_KEY_ID=#{id}"
puts "export AMAZON_SECRET_ACCESS_KEY=#{key}"
puts "export AWS_ACCESS_KEY=#{id}"
puts "export AWS_SECRET_KEY=#{key}"

Message to My Senator Boxer: Uphold your Oath of Office: Squash Shadow Secret Gov’t

Remind your elected officials from the President on down to keep their oath of office: to Preserve, Protect and Defend the Constitution of the United States of America.Senate Oath of OfficeJust a reminder you swore an oath of office to uphold the Constitution but you are not upholding it if you are not investigating and prosecuting those in all branches of the government that have been sidestepping the Constitution.

The 13 years of Cheney/Obama administrations has set up a shadow secret government with its own courts, laws and interpretations of the public laws.

Arrest and Try James Clapper for Lying to CongressMembers of at least the current administration have now been proven to have lied under oath in front of congressional hearing.

But nothing has been done. Instead the whistleblowers are in jail or forced to seek asylum in other nations and the real criminals are in the seats of the White House, Congress, the Judiciary and the Media.

I’m not even bothering to write to Diane “NSA” Feinstein but I for some reason still have hope that maybe you have a bone of integrity left in your body.

You are being called to get out of your comfort zone and safeguard our Democracy before its too late (though it may be too late already, especially if you and at least some colleagues don’t do something about it)

Data Wants to be Free (as in Freedom)

Tonight I was at the Sensored Meetup #10: Data! APIs! Standards!. Besides some great thought provoking talks, there was some great discussions afterward that got me thinking more clearly about some stuff that has been bubbling in my brain.

Scott McNealy Was Right - Privacy: ‘Get Over It’

Scot McNealyI really thought McNealy was wrong when he said way back in 1999 that consumer privacy issues are a “red herring.” “You have zero privacy anyway,” But today in conversation with one of the participants, Antoine Lizee, about how can we get people’s  Medical data available to medical researchers I realized that McNealy was correct.

We both felt that if medical sensor and other data from  millions of people could be made available in some open source form to researchers, huge breakthroughs in medical science would quickly emerge just from modern data mining, machine learning and statistical processing. Of course the issue of privacy came up almost immediately. But from his experience and from recent news that even anonymized DNA sequences can be traced back to an individual’s identity. So even with anonymization, its almost impossible to completely protect an individual’s identity in light of modern big data techniques.

I wondered, “Actually, what are people real fears about their Medical Data getting out?”. Is it any different than 5 or ten years ago when people said they would NEVER use a credit card on the Internet

I would never by something over the Internet. I'd hate to have my credit card number floating around there.

Dilbert by Scott Adams January 11, 1996

How long and what would it take to have a similar change in mass mentality that would allow folks to not mind that their medical data might be use “on the Internet”?

Big Data Processing of  Medical Sensors: A Solution to Rising Health Care Costs

I have long believed that if the data collected from medical sensors and the burgeoning world of the Quantified Self could be aggregated and made available to researchers (and not just “medical researchers”) we would enter a new golden era of medical breakthrough and real cures for major illnesses.

With sample sizes of MILLIONs instead of the 10 to 100 people in most modern medical studies, just using statistical processing on the billions of data samples  patterns of health and illness will practically just apear. That alone would make it worthwhile for us to do it, the government (or insurance companies) to fund it and for individuals to feel there would be a value to allow their data to be aggregated. Even if it meant that their data may leak out.

And using similar Big Data techniques used today to sell more stuff on the Internet (like we did at my last company Runa), we could map some of those discoveries of patterns back to the real time processing of individual’s sensor data to let them know if their personal real time data stream indicates they are about to have a heart attack or something.

Just Do It

nike-fuel-band-launched_smallMy conclusion was that we need to break the logjam and start some projects that demonstrate how powerful it will be to do open Big Data medical research using aggregated data. One way would be to get companies with silos of Quantified Self and similar data to make it available (with permission from the individuals) to open medical research. I’m sure there are other short term ways the community can come up with to show that this kind of research can have huge positive results.

Legal Protections are More Viable than Technical Protections

Mechanisms, that can be publicly audited,  should be made to make the data a anonymized as possible but as mentioned earlier, the nature of medical data is inherently personally identifiable, especially if drawn from multiple sources and linked with other publicly available personal info (aka Facebook and the like).

There can be huge benefits of allowing at least some explicit linkage of personal data to the person. The primary one would be to allow the processor of the data to notify the individual if they found patterns that would indicate a medical problem or would predict a high probability of a future medical problem.DNA Privacy

So we need the aggregators and users of this huge pool of data to be responsible and we need to make sure individuals don’t have to worry about discrimination or other negative impacts of their medical info leaking out.

This is much more a legal issue than a technical one. There already is The Genetic Information Nondiscrimination Act of 2008 and related laws that protects Americans from discrimination based on their genetic information in both health insurance (Title I) and employment (Title II). Just as the laws and policies of banks limits the risk of using your Credit Card on the Internet makes people much more comfortable, we need appropriate laws and corporate policies to allow people to feel comfortable sharing their medical and personal sensor data as well.

So if we could implement as much technical and legal means as possible combined with the huge individual and collective win of using machine learning and statistical processing on the huge corpus of personal & medical data that is already being collected by individuals, we could come up with major new cures and solutions to age old health problems and solve the US core economic problem (Health Care Costs) in one very low cost way.