コマンドライン

VPN接続に関する話題、疑問、質問はこちらからお願いします。

コマンドライン

投稿記事by Giskard » 2014年1月21日(火) 00:47

ローカルでWaffle CellのHDDにアクセスするときや、
外からVPNで接続するときのログインを、
コマンドラインで出来る方法は無いですか?
と言うか欲しいです。
Giskard
 
記事: 41
登録日時: 2013年11月18日(月) 02:03

Re: コマンドライン

投稿記事by Sysop » 2014年1月21日(火) 14:48

Sysopの大坊です。

Giskardさん、よくぞ聞いてくれました!!
というか、思いつきませんでした。コマンドラインでの接続を。すっかりGUIに毒されてしまっていたようです(笑)
さっそく調べてみましたが、以下のコマンドで接続可能です。

書式
rasdial "Waffle Cell VPN" 一般ユーザ名 パスワード /PHONEBOOK:"C:\Users\ウインドウズでのユーザ名\AppData\Roaming\Waffle Computer\WafflePhoneBook.pbk"
※ユーザ名とパスワードは管理者用でなく、一般ユーザ名とパスワードになりますので、ご注意下さい。

書式例:一般ユーザ名が「yama」、パスワードが「afafjophygfa」、ウインドウズでのユーザ名が「abcxyz」の場合
rasdial "Waffle Cell VPN" yama afafjophygfa /PHONEBOOK:"C:\Users\abcxyz\AppData\Roaming\Waffle Computer\WafflePhoneBook.pbk"

ポイントはWafflePhoneBook.pbkがどこにあるのかを確認し、そのパスを書くことです。上記の例はウインドウズ7の標準的な設定の場合ですので、XPなどは「c:」以下が違うパスになっている可能性があります。ファイルマネージャー等で検索して探してください。
また、接続プログラムWaffle Cell VPN Manager(ワッフルセル VPN マネージャー)で既に接続設定を行って、正常に接続が出来ていることが前提です。

コマンドをバッチファイル化(って懐かしいなぁ)しておけば、ダブルクリックで接続可能です。
ただし、この場合、バッチファイルを開くとパスワードが丸見えになりますので、その点ご注意下さい。

なお、気を利かせて切断のコマンドラインもご紹介します。
rasdial "Waffle Cell VPN" /DISCONNECT
これもバッチファイル化しておけば、二つのファイルで接続と切断が思いのままになります。

コマンドラインでの接続方法は、おいおい取説にも反映していこうと思います。
Sysop
 
記事: 237
登録日時: 2013年5月24日(金) 14:13

Re: コマンドライン

投稿記事by Giskard » 2014年1月21日(火) 15:56

ありがとうございます。出来ました!。素晴らしい!。

XPでは以下の場所にありました。

c:\Documents and Settings\(PCユーザー名)\Application Data\Waffle Computer\WafflePhoneBook.pbk

ところで、VPN接続後、エクスプローラーなどで開こうとすると
『Waffle Cellに接続』で、再度ユーザー名、パスワードを聞かれますが、
何とかならないですか。これもコマンドラインで処理できるとか。
Giskard
 
記事: 41
登録日時: 2013年11月18日(月) 02:03

Re: コマンドライン

投稿記事by Sysop » 2014年1月21日(火) 16:21

Sysopの大坊です。

>ところで、VPN接続後、エクスプローラーなどで開こうとすると
>『Waffle Cellに接続』で、再度ユーザー名、パスワードを聞かれますが、
>何とかならないですか。これもコマンドラインで処理できるとか。

ふっふふのふ。やっぱりその質問が来ましたね。
思わず前回の回答の末尾に「お前の次の質問は....」と書いておけばよかったと思ったくらいです。

で、コマンドは以下の通りです。
NET USE "¥¥l.ワッフルセルの名前.wafflecell.com\ユーザ名" パスワード /USER:ユーザー名
       ↑¥は実際には半角

何故かrasdialとユーザ名とパスワードの指定順が逆なので注意して下しさい。
7ではうまくいきましたが、XPでは試してません。たぶん大丈夫だと思いますので、お試し下さい。

ユーザ名がyamaでパスワードがgfaruafaff、Waffle Cellの名前がexample、ウインドウズのユーザ名がpppppの場合なら、
rasdial "Waffle Cell VPN" yama gfaruafaff /PHONEBOOK:"C:\Users\ppppp\AppData\Roaming\Waffle Computer\WafflePhoneBook.pbk"
NET USE "¥¥l.example.wafflecell.com\yama" gfaruafaff /USER:yama
       ↑¥は実際には半角

などと、バッチに2行書いておくと一発でファイルサーバーにつなげられて、猛烈に便利です。
もちろん私も既にバッチ組んで使い始めました。
最後に編集したユーザー Sysop [ 2014年1月22日(水) 12:03 ], 累計 4 回
Sysop
 
記事: 237
登録日時: 2013年5月24日(金) 14:13

Re: コマンドライン

投稿記事by Sysop » 2014年1月21日(火) 16:32

ところで、よくよく考えてみれば、標準のWaffle Cell VPNマネージャを改造して、

起動するだけで接続を開始する
ファイルサーバ(samba)の認証も行う

という機能を追加しておけばよかったのに気が付きました。
そうすれば、バッチを覗けばIDやパスワードが丸わかりというのも回避できるはずで...

コマンドは判明したので、野手に要望しておきます。
きっとGUI満載で作ってくれるでしょう。
Sysop
 
記事: 237
登録日時: 2013年5月24日(金) 14:13

Re: コマンドライン

投稿記事by mozart » 2014年1月21日(火) 16:47

Sysop さんが書きました:コマンドは判明したので、野手に要望しておきます。
きっとGUI満載で作ってくれるでしょう。


あ、圧力団体・・・・

しかし久しぶりにバッチファイルの話を聞き、「少し昔」のDOS時代に味わったちょっとした喜びを感じました。
Winodwsになってこういう楽しみ、激減しましたね。

もて
アバター
mozart
 
記事: 707
登録日時: 2013年5月24日(金) 13:56
お住まい: 東京の中心、板橋区

Re: コマンドライン

投稿記事by Giskard » 2014年1月21日(火) 17:45

Sysopさん、ありがとうございます。
1アクションでWaffle Cellにアクセス出来るようになって気分がいいです。

低レベルながらAutoHotkeyなどで、ちょっとした事をさせるのが好きです。
(以前はWinBatchEhとかも使ったりしました)

プログラマーは何でも出来るんでしょ?。すごいな~。
Giskard
 
記事: 41
登録日時: 2013年11月18日(月) 02:03

Re: コマンドライン

投稿記事by Sysop » 2014年1月21日(火) 17:49

>プログラマーは何でも出来るんでしょ?。すごいな~。

何でも出来てたら、今頃野手は女の子にもてもてだったはずなので、
残念ながら何でもできそうなのはPCに関してのみです。
Sysop
 
記事: 237
登録日時: 2013年5月24日(金) 14:13

Re: コマンドライン

投稿記事by Sysop » 2014年1月22日(水) 10:41

Sysopの大坊です。

今朝さらに一つ思いつきました。
VPN接続、ファイルサーバ(samba)へのログインを自動化したのなら、さらにもう一歩進んで、ファイルサーバの自分のフォルダをエクスプローラで自動で開くように出来ないかと。
バッチの最後に、

explorer ¥¥l.ワッフルセルの名前.wafflecell.com¥ユーザ名
      ↑※¥は実際は半角に直してください

の1行を付け加えるだけで、アラ不思議、自動的にエクスプローラが起動してファイルサーバの自分の領域が開きます。

これで今まで
1:Waffle Cell VPNマネージャーを起動
2:Waffle Cell VPNマネージャーの接続ボタンを押す
3:Waffle Cellへ接続のダイアログで接続ボタンを押す
4:接続完了後、ファイルサーバの自分のフォルダを選択(ショートカットを作ってある)
5:ファイルサーバ接続用のIDとパスワードを入力
という作業をしていたところが、バッチファイルをダブルクリックするだけで完了するようになりました。

Windowsを使い始めて18年以上、すっかりGUIに慣れきって工夫して作業工程を減らす事を忘れてました。
dosプロンプトもPING打つとき位しか使ってなかった。
Waffle Cellを使う上で、頭を切り替えて色々と考えて行こうと思います。
Sysop
 
記事: 237
登録日時: 2013年5月24日(金) 14:13


Re: コマンドライン

投稿記事by yanath » 2025年6月01日(日) 18:14

http://audiobookkeeper.ruhttp://cottagenet.ruhttp://eyesvision.ruhttp://eyesvisions.comhttp://factoringfee.ruhttp://filmzones.ruhttp://gadwall.ruhttp://gaffertape.ruhttp://gageboard.ruhttp://gagrule.ruhttp://gallduct.ruhttp://galvanometric.ruhttp://gangforeman.ruhttp://gangwayplatform.ruhttp://garbagechute.ruhttp://gardeningleave.ruhttp://gascautery.ruhttp://gashbucket.ruhttp://gasreturn.ruhttp://gatedsweep.ruhttp://gaugemodel.ruhttp://gaussianfilter.ruhttp://gearpitchdiameter.ru
http://geartreating.ruhttp://generalizedanalysis.ruhttp://generalprovisions.ruhttp://geophysicalprobe.ruhttp://geriatricnurse.ruhttp://getintoaflap.ruhttp://getthebounce.ruhttp://habeascorpus.ruhttp://habituate.ruhttp://hackedbolt.ruhttp://hackworker.ruhttp://hadronicannihilation.ruhttp://haemagglutinin.ruhttp://hailsquall.ruhttp://hairysphere.ruhttp://halforderfringe.ruhttp://halfsiblings.ruhttp://hallofresidence.ruhttp://haltstate.ruhttp://handcoding.ruhttp://handportedhead.ruhttp://handradar.ruhttp://handsfreetelephone.ru
http://hangonpart.ruhttp://haphazardwinding.ruhttp://hardalloyteeth.ruhttp://hardasiron.ruhttp://hardenedconcrete.ruhttp://harmonicinteraction.ruhttp://hartlaubgoose.ruhttp://hatchholddown.ruhttp://haveafinetime.ruhttp://hazardousatmosphere.ruhttp://headregulator.ruhttp://heartofgold.ruhttp://heatageingresistance.ruhttp://heatinggas.ruhttp://heavydutymetalcutting.ruhttp://jacketedwall.ruhttp://japanesecedar.ruhttp://jibtypecrane.ruhttp://jobabandonment.ruhttp://jobstress.ruhttp://jogformation.ruhttp://jointcapsule.ruhttp://jointsealingmaterial.ru
http://journallubricator.ruhttp://juicecatcher.ruhttp://junctionofchannels.ruhttp://justiciablehomicide.ruhttp://juxtapositiontwin.ruhttp://kaposidisease.ruhttp://keepagoodoffing.ruhttp://keepsmthinhand.ruhttp://kentishglory.ruhttp://kerbweight.ruhttp://kerrrotation.ruhttp://keymanassurance.ruhttp://keyserum.ruhttp://kickplate.ruhttp://killthefattedcalf.ruhttp://kilowattsecond.ruhttp://kingweakfish.ruhttp://kinozones.ruhttp://kleinbottle.ruhttp://kneejoint.ruhttp://knifesethouse.ruhttp://knockonatom.ruhttp://knowledgestate.ru
http://kondoferromagnet.ruhttp://labeledgraph.ruhttp://laborracket.ruhttp://labourearnings.ruhttp://labourleasing.ruhttp://laburnumtree.ruhttp://lacingcourse.ruhttp://lacrimalpoint.ruhttp://lactogenicfactor.ruhttp://lacunarycoefficient.ruhttp://ladletreatediron.ruhttp://laggingload.ruhttp://laissezaller.ruhttp://lambdatransition.ruhttp://laminatedmaterial.ruhttp://lammasshoot.ruhttp://lamphouse.ruhttp://lancecorporal.ruhttp://lancingdie.ruhttp://landingdoor.ruhttp://landmarksensor.ruhttp://landreform.ruhttp://landuseratio.ru
http://languagelaboratory.ruhttp://largeheart.ruhttp://lasercalibration.ruhttp://laserlens.ruhttp://laserpulse.ruhttp://laterevent.ruhttp://latrinesergeant.ruhttp://layabout.ruhttp://leadcoating.ruhttp://leadingfirm.ruhttp://learningcurve.ruhttp://leaveword.ruhttp://machinesensible.ruhttp://magneticequator.ruhttp://magnetotelluricfield.ruhttp://mailinghouse.ruhttp://majorconcern.ruhttp://mammasdarling.ruhttp://managerialstaff.ruhttp://manipulatinghand.ruhttp://manualchoke.ruhttp://medinfobooks.ruhttp://mp3lists.ru
http://nameresolution.ruhttp://naphtheneseries.ruhttp://narrowmouthed.ruhttp://nationalcensus.ruhttp://naturalfunctor.ruhttp://navelseed.ruhttp://neatplaster.ruhttp://necroticcaries.ruhttp://negativefibration.ruhttp://neighbouringrights.ruhttp://objectmodule.ruhttp://observationballoon.ruhttp://obstructivepatent.ruhttp://oceanmining.ruhttp://octupolephonon.ruhttp://offlinesystem.ruhttp://offsetholder.ruhttp://olibanumresinoid.ruhttp://onesticket.ruhttp://packedspheres.ruhttp://pagingterminal.ruhttp://palatinebones.ruhttp://palmberry.ru
http://papercoating.ruhttp://paraconvexgroup.ruhttp://parasolmonoplane.ruhttp://parkingbrake.ruhttp://partfamily.ruhttp://partialmajorant.ruhttp://quadrupleworm.ruhttp://qualitybooster.ruhttp://quasimoney.ruhttp://quenchedspark.ruhttp://quodrecuperet.ruhttp://rabbetledge.ruhttp://radialchaser.ruhttp://radiationestimator.ruhttp://railwaybridge.ruhttp://randomcoloration.ruhttp://rapidgrowth.ruhttp://rattlesnakemaster.ruhttp://reachthroughregion.ruhttp://readingmagnifier.ruhttp://rearchain.ruhttp://recessioncone.ruhttp://recordedassignment.ru
http://rectifiersubstation.ruhttp://redemptionvalue.ruhttp://reducingflange.ruhttp://referenceantigen.ruhttp://regeneratedprotein.ruhttp://reinvestmentplan.ruhttp://safedrilling.ruhttp://sagprofile.ruhttp://salestypelease.ruhttp://samplinginterval.ruhttp://satellitehydrology.ruhttp://scarcecommodity.ruhttp://scrapermat.ruhttp://screwingunit.ruhttp://seawaterpump.ruhttp://secondaryblock.ruhttp://secularclergy.ruhttp://seismicefficiency.ruhttp://selectivediffuser.ruhttp://semiasphalticflux.ruhttp://semifinishmachining.ruhttp://spicetrade.ruhttp://spysale.ru
http://stungun.ruhttp://tacticaldiameter.ruhttp://tailstockcenter.ruhttp://tamecurve.ruhttp://tapecorrection.ruhttp://tappingchuck.ruhttp://taskreasoning.ruhttp://technicalgrade.ruhttp://telangiectaticlipoma.ruhttp://telescopicdamper.ruhttp://temperateclimate.ruhttp://temperedmeasure.ruhttp://tenementbuilding.rutuchkashttp://ultramaficrock.ruhttp://ultraviolettesting.ru
yanath
 
記事: 8440
登録日時: 2025年5月12日(月) 16:27


Return to VPN接続

オンラインデータ

このフォーラムを閲覧中のユーザー: なし & ゲスト[3人]

cron