これはひどい


SCAN DISPATCH : 素人に突破された役所のセキュリティ
https://www.netsecurity.ne.jp/2_11514.html
より



アレックスがサーチ結果のページにある「印刷用ページ」のリンクを見てみると、URLは以下の通りだった。
http://docapp8.doc.state.ok.us/pls/portal30/url/page/sor_ros
ter?sqlString=select distinct o.offender_id,doc_number,o.social_security_number,o.date_of_birth,o.first_name,o.middle_name,o.last_name,o.sir_name,sor_data.getCD(race) race,sor_data.getCD(sex) sex,l.address1 address,l.city,l.state stateid,l.zip,l.county,sor_data.getCD(l.state) state,l.country countryid,sor_data.getCD(l.country) country,decode(habitual,'Y','habitual','') habitual,decode(aggravated,'Y','aggravated','') aggravated,l.status,x.status,x.registration_date,x.end_registration_date,l.jurisdiction from registration_offender_xref x, sor_last_locn_v lastLocn, sor_offender o, sor_location l , (select distinct offender_id from sor_location where status = 'Verified' and upper(zip) = '73064' ) h where lastLocn.offender_id(%2B) = o.offender_id and l.location_id(%2B) = lastLocn.location_id and x.offender_id = o.offender_id and x.status not in ('Merged') and x.REG_TYPE_ID = 1 and nvl(x.admin_validated,to_date(1,'J')) >= nvl(x.entry_date,to_date(1,'J')) and x.status = 'Active' and x.status <> 'Deleted' and h.offender_id = o.offender_id order by o.last_name,o.first_name,o.middle_name&sr=yes

お分かりだろう。このURLのリンクは、ずばりページのデータを返すデータベース・クエリそのものを含んでいる。このクエリには、social_security_number(国民保障番号)や、date_of_birth(生年月日)などのコラムも含んでいる。そこでアレックスはこのクエリを改変して新たなURLをつくり、そのURLを入力して10,597人もの、国民保障番号、生年月日、現住所を含むデータを出力させることができた。



「突破された」というより、最初から守る気ないだろ。
SQLインジェクションもびっくり。