World: r3wp
[MySQL]
older newer | first last |
Pekr 9-Jan-2006 [452] | I am innocent unless I am proven being guilty, so it is upon to you to prove me using your code for my code creation :-) |
JaimeVargas 9-Jan-2006 [453] | If you do a clean-lab implementation your code doesn't need to be GPL(ed). |
Pekr 9-Jan-2006 [454] | Jaime - with rebol, you even can't to use it, can you? So you use mysql-protocol.r, which is let's say GPL. Then you do some app using it. You can open-source your app, but you can't open-source one part of your app - REBOL itself ... well, I am weak in licensing stuff, so I really don't have clear opinion on that issue - just trying to use common-sense ... |
JaimeVargas 9-Jan-2006 [455x3] | REBOL as is an interpreter doesn't need to be GPL(ed). MS will need in that case to release is code becacues it is running Apache. |
REBOL is the medium. | |
Any how. Need to go. GPL is just some biz terms, that you either decide to play with or not. If you don't like the terms the reimplement the functionality yourself, or get it from somewhere else. | |
Dockimbel 9-Jan-2006 [458] | The protocol of v5 has changed (since v4.x I guess). It needs more than just log in the server to make the driver work. I need to update the protocol implementation too. I'll try to see if I can make something work tomorrow. |
Pekr 9-Jan-2006 [459x4] | hmm, really? |
I was able to send queries and get results? | |
OK, anyway, please let us know, if you will find free time to work on it .... | |
but what part of your code are you talking about? caching? reading-out packets? low level stuff? | |
Dockimbel 9-Jan-2006 [463x3] | I can retrieve the result of a query. The colums and row formats have changed |
I'm using server version 5.0.18 | |
sorry, can => can't | |
Pekr 9-Jan-2006 [466x3] | uh, that is bad ... the only thing I tried was "select * from user" |
and I easily got the result ... | |
should I upload my version? | |
Dockimbel 9-Jan-2006 [469x2] | Upload it. |
What server version are you using ? | |
Pekr 9-Jan-2006 [471x3] | http://www.rebol.cz/mysql/mysql-protocol-new.r |
wait a sec, just retrying here at home ... latest version here ... | |
5.0.18 | |
Dockimbel 9-Jan-2006 [474] | Are you able to log into the server with the new password algorithm using your version ? |
Pekr 9-Jan-2006 [475x3] | >> insert db "select * from user" == none >> probe copy db [["localhost" "root" "*F86989FB72FDCB10211242B0F66A00AB9561DC07" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" " Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "" "" "" "" 0 0 0 0]] == [["localhost" "root" "*F86989FB72FDCB10211242B0F66A00AB9561DC07" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y Y" "Y" "Y" "Y" "Y" "Y"... |
above shows that yes ... | |
because it is clean 5.0.18 install and second, the field size is 41 bytes, starting with asterisk ... | |
Dockimbel 9-Jan-2006 [478] | That's weird... |
Pekr 9-Jan-2006 [479x4] | have you any short script which will try to set-up new db, tables, insert records etc.? |
I would try it here ... | |
>> db: open mysql://root:[gaia-:-127-:-0-:-0-:-1]/information_schema connecting to: 127.0.0.1 >> insert db "select * from collations" == none >> length? copy db == 124 >> probe copy db none == none >> insert db "select * from collations" == none >> probe copy db [["big5_chinese_ci" "big5" "1" "Yes" "Yes" "1"] ["big5_bin" "big5" "84" "" "Yes" "1"] ["dec8_swedish_ci" " dec8" "3" "Yes" "" "0"] ["dec8_bin" "dec8" "69" "" "" "0"] ["cp850_general_ci" "cp850" "4" "Yes" "" "0"] [ cp850_bin "cp850" "80" "" "" "0"] ["hp8_english_ci" "hp8" "6" "Yes" "" "0"] ["hp8_bin" "hp8" "72" "" "" 0 ] ["koi8r_general_ci" "koi8r" "7" "Yes" "" "0"] ["koi8r_bin" "koi8r" "74" "" "" "0"] ["latin1_german1_c i" "latin1" "5" "" "" "0"] ["latin1_swedish_ci" "latin1" "8" "Yes" "Yes" "1"] ["latin1_danish_ci" "latin1" "15" "" "" "0"] ["latin1_german2_ci" "latin1" "31" "" "Yes" "2"] ["latin1_bin" "latin1" "47" "" "Yes" "1" ] ["latin1_general_ci" "latin1" "48" "" "" "0"] ["latin1_general_cs" "latin1" "49" "" "" "0"] ["latin1_spa nish_ci" "latin1" "94" "" "" "0"] ["latin2_czech_cs" "latin2" "2" "" "Yes" "4"] ["latin2_general_ci" "lati n2" "9" "Yes" "" "0"] ["latin2_hungarian_ci" "latin2" "21" "" "" "0"] ["latin2_croatian_ci" "latin2" "27" "" "0"] ["latin2_bin" "latin2" "77" "" "" "0"] ["swe7_swedish_ci" "swe7" "10" "Yes" "" "0"] ["swe7_bin" "swe7" "82" "" "" "0"] ["ascii_general_ci" "ascii" "11" "Yes" "" "0"] ["ascii_bin" "ascii" "65" "" "" "0" ] ["ujis_japanese_ci" "ujis" "12" "Yes" "Yes" "1"] ["ujis_bin" "ujis" "91" "" "Yes" "1"] ["sjis_japanese_c i" "sjis" "13" "Yes" "Yes" "1"] ["sjis_bin" "sjis" "88" "" "Yes" "1"] ["hebrew_general_ci" "hebrew" "16" " Yes" "" "0"] ["hebrew_bin" "hebrew" "71" "" "" "0"] ["tis620_thai_ci" "tis620" "18" "Yes" "Yes" "4"] ["tis 620_bin" "tis620" "89" "" "Yes" "1"] ["euckr_korean_ci" "euckr" "19" "Yes" "Yes" "1"] ["euckr_bin" "euckr" "85" "" "Yes" "1"] ["koi8u_general_ci" "koi8u" "22" "Yes" "" "0"] ["koi8u_bin" "koi8u" "75" "" "" "0"] [" gb2312_chinese_ci" "gb2312" "24" "Yes" "Yes" "1"] ["gb2312_bin" "gb2312" "86" "" "Yes" "1"] ["greek_genera l_ci" "greek" "25" "Yes" "" "0"] ["greek_bin" "greek" "70" "" "" "0"] ["cp1250_general_ci" "cp1250" "26" " Yes" "" "0"] ["cp1250_czech_cs" "cp1250" "34" "" "Yes" "2"] ["cp1250_croatian_ci" "cp1250" "44" "" "" "0"] ["cp1250_bin" "cp1250" "66" "" "" "0"] ["gbk_chinese_ci" "gbk" "28" "Yes" "Yes" "1"] ["gbk_bin" "gbk" "87 Yes" "1"] ["latin5_turkish_ci" "latin5" "30" "Yes" "" "0"] ["latin5_bin" "latin5" "78" "" "" "0"] [" armscii8_general_ci" "armscii8" "32" "Yes" "" "0"] ["armscii8_bin" "armscii8" "64" "" "" "0"] ["utf8_gener al_ci" "utf8" "33" "Yes" "Yes" "1"] ["utf8_bin" "utf8" "83" "" "Yes" "1"] ["utf8_unicode_ci" "utf8" "192" "Yes" "8"] ["utf8_icelandic_ci" "utf8" "193" "" "Yes" "8"] ["utf8_latvian_ci" "utf8" "194" "" "Yes" "8" ] ["utf8_romanian_ci" "utf8" "195" "" "Yes" "8"] ["utf8_slovenian_ci" "utf8" "196" "" "Yes" "8"] ["utf8_po lish_ci" "utf8" "197" "" "Yes" "8"] ["utf8_estonian_ci" "utf8" "198" "" "Yes" "8"] ["utf8_spanish_ci" "utf 8" "199" "" "Yes" "8"] ["utf8_swedish_ci" "utf8" "200" "" "Yes" "8"] ["utf8_turkish_ci" "utf8" "201" "" "Y es" "8"] ["utf8_czech_ci" "utf8" "202" "" "Yes" "8"] ["utf8_danish_ci" "utf8" "203" "" "Yes" "8"] ["utf8_l ithuanian_ci" "utf8" "204" "" "Yes" "8"] ["utf8_slovak_ci" "utf8" "205" "" "Yes" "8"] ["utf8_spanish2_ci" utf8 "206" "" "Yes" "8"] ["utf8_roman_ci" "utf8" "207" "" "Yes" "8"] ["utf8_persian_ci" "utf8" "208" "" Yes "8"] ["utf8_esperanto_ci" "utf8" "209" "" "Yes" "8"] ["ucs2_general_ci" "ucs2" "35" "Yes" "Yes" "1"] ["ucs2_bin" "ucs2" "90" "" "Yes" "1"] ["ucs2_unicode_ci" "ucs2" "128" "" "Yes" "8"] ["ucs2_icelandic_ci" ucs2 "129" "" "Yes" "8"] ["ucs2_latvian_ci" "ucs2" "130" "" "Yes" "8"] ["ucs2_romanian_ci" "ucs2" "131" "Yes" "8"] ["ucs2_slovenian_ci" "ucs2" "132" "" "Yes" "8"] ["ucs2_polish_ci" "ucs2" "133" "" "Yes" "8"] ["ucs2_estonian_ci" "ucs2" "134" "" "Yes" "8"] ["ucs2_spanish_ci" "ucs2" "135" "" "Yes" "8"] ["ucs2_swedi sh_ci" "ucs2" "136" "" "Yes" "8"] ["ucs2_turkish_ci" "ucs2" "137" "" "Yes" "8"] ["ucs2_czech_ci" "ucs2" "1 38" "" "Yes" "8"] ["ucs2_danish_ci" "ucs2" "139" "" "Yes" "8"] ["ucs2_lithuanian_ci" "ucs2" "140" "" "Yes" "8"] ["ucs2_slovak_ci" "ucs2" "141" "" "Yes" "8"] ["ucs2_spanish2_ci" "ucs2" "142" "" "Yes" "8"] ["ucs2_r oman_ci" "ucs2" "143" "" "Yes" "8"] ["ucs2_persian_ci" "ucs2" "144" "" "Yes" "8"] ["ucs2_esperanto_ci" "uc s2" "145" "" "Yes" "8"] ["cp866_general_ci" "cp866" "36" "Yes" "" "0"] ["cp866_bin" "cp866" "68" "" "" "0" ] ["keybcs2_general_ci" "keybcs2" "37" "Yes" "" "0"] ["keybcs2_bin" "keybcs2" "73" "" "" "0"] ["macce_gene ral_ci" "macce" "38" "Yes" "" "0"] ["macce_bin" "macce" "43" "" "" "0"] ["macroman_general_ci" "macroman" 39 "Yes" "" "0"] ["macroman_bin" "macroman" "53" "" "" "0"] ["cp852_general_ci" "cp852" "40" "Yes" "" "0 ] [ cp852_bin" "cp852" "81" "" "" "0"] ["latin7_estonian_cs" "latin7" "20" "" "" "0"] ["latin7_general_ci latin7" "41" "Yes" "" "0"] ["latin7_general_cs" "latin7" "42" "" "" "0"] ["latin7_bin" "latin7" "79" "" "" "0"] ["cp1251_bulgarian_ci" "cp1251" "14" "" "" "0"] ["cp1251_ukrainian_ci" "cp1251" "23" "" "" "0"] [ cp1251_bin "cp1251" "50" "" "" "0"] ["cp1251_general_ci" "cp1251" "51" "Yes" "" "0"] ["cp1251_general_cs cp1251" "52" "" "" "0"] ["cp1256_general_ci" "cp1256" "57" "Yes" "" "0"] ["cp1256_bin" "cp1256" "67" "" "" "0"] ["cp1257_lithuanian_ci" "cp1257" "29" "" "" "0"] ["cp1257_bin" "cp1257" "58" "" "" "0"] ["cp1257_ general_ci" "cp1257" "59" "Yes" "" "0"] ["binary" "binary" "63" "Yes" "Yes" "1"] ["geostd8_general_ci" "ge ostd8" "92" "Yes" "" "0"] ["geostd8_bin" "geostd8" "93" "" "" "0"] ["cp932_japanese_ci" "cp932" "95" "Yes" "Yes" "1"] ["cp932_bin" "cp932" "96" "" "Yes" "1"] ["eucjpms_japanese_ci" "eucjpms" "97" "Yes" "Yes" "1"] ["eucjpms_bin" "eucjpms" "98" "" "Yes" "1"]] == [["big5_chinese_ci" "big5" "1" "Yes" "Yes" "1"] ["big5_bin" "big5" "84" "" "Yes" "1"] ["dec8_swedish_ci dec8" "3" "Yes" "" "0"... | |
I should change my password now :-) well, behind firewall, running only local connections as a root, so ... :-) | |
Dockimbel 9-Jan-2006 [483] | nope, no script. It seems that I made some troubles in my install by copying my olds testing tables in the new server. |
Pekr 9-Jan-2006 [484x2] | does at least above work for you? |
well, if you do so, then: | |
Dockimbel 9-Jan-2006 [486] | you only get string! values, shouldn't some of the values be converted to integer! for example ? |
Pekr 9-Jan-2006 [487x2] | look into your password field - if you use old databases, the field is not extended to be able to keep 41 bytes |
dunno ... | |
Dockimbel 9-Jan-2006 [489x2] | my 'mysql' db is v5, it's only the 'test' db who was copied from v3. |
I'll check that tomorrow, have to go. Thanks a lot for your good work ;-) | |
Pekr 9-Jan-2006 [491x2] | ok, thanks ... |
strange thing, that conversion does not happen :-( | |
Dockimbel 9-Jan-2006 [493] | You're using checksum/secure and not checksum/method key 'sha1 ?? |
Pekr 9-Jan-2006 [494x8] | no, as I found checksum/secure = cheksum/method "string" 'sha1 |
imo Carl just decided to call it /secure and that 'sha1 was added later, dunno ... | |
whoa, it does datatype translations :-) " [[1 "Petr" "Krenzelok" "This is pekr" 33] [2 "Marek" "Krenzelok" "This is pekrs brother" 31]]" | |
Doc, are you sure the low-level protocl changed? The protocol is still version 10, which you have covered already. What is more, it is strange, as you can work with old passwords, without the change to the stack, so I would let it as it is, just let's correctly implement the password stuff as first step :-) | |
I mean - let's find out the way of how to distinguish there is new password scheme used for connection. I thought that LONG_FLAG or PROTOCOL_411 flags will be set, but they apparently are not set. Maybe we could distinguish by long-seed length? If it is still 8, then old password scheme should be used, if it is 20, then new password scheme is used? | |
aha - LONG_FLAG = long column info ... | |
it seems to me your older code was inspired by - http://svn.mysql.com/svnpublic/connector-net/trunk/mysqlclient/nativedriver.cs ? | |
Doc, are you sure your 'docode table is ok? I mean defs/client .... client [ long-password 1 ; new more secure passwords found-rows 2 ; Found instead of affected rows long-flag 4 ; Get all column flags connect-with-db 8 ; One can specify db on connect no-schema 16 ; Don't allow db.table.column compress 32 ; Can use compression protcol odbc 64 ; Odbc client local-files 128 ; Can use LOAD DATA LOCAL ignore-space 256 ; Ignore spaces before '(' change-user 512 ; Support the mysql_change_user() interactive 1024 ; This is an interactive client ssl 2048 ; Switch to SSL after handshake ignore-sigpipe 4096 ; IGNORE sigpipes transactions 8196 ; Client knows about transactions ] While in protocol description, there is: MySQL uses the following codes: Capability name Value Meaning LONG_PASSWORD 1 New more secure passwords FOUND_ROWS 2 Found instead of affected rows LONG_FLAG 4 Get all column flags CONNECT_WITH_DB 8 One can specify db on connect NO_SCHEMA 16 Don't allow database.table.column COMPRESS 32 Can use compression protocol ODBC 64 ODBC client LOCAL_FILES 128 Can use LOAD DATA LOCAL IGNORE_SPACE 256 Ignore spaces before '(' PROTOCOL_41 512 Support the 4.1 protocol INTERACTIVE 1024 This is an interactive client SSL 2048 Switch to SSL after handshake IGNORE_SIGPIPE 4096 IGNORE sigpipes TRANSACTIONS 8192 Client knows about transactions SECURE_CONNECTION 32768 New 4.1 authentication MULTI_STATEMENTS 65536 Multi-statement support MULTI_RESULTS 131072 Multi-results | |
older newer | first last |