並び順

ブックマーク数

期間指定

  • から
  • まで

1 - 40 件 / 113件

新着順 人気順

else if operator in pythonの検索結果1 - 40 件 / 113件

  • 【2020年】CTF Web問題の攻撃手法まとめ - こんとろーるしーこんとろーるぶい

    はじめに 対象イベント 読み方、使い方 Remote Code Execution(RCE) 親ディレクトリ指定によるopen_basedirのバイパス PHP-FPMのTCPソケット接続によるopen_basedirとdisable_functionsのバイパス JavaのRuntime.execでシェルを実行 Cross-Site Scripting(XSS) nginx環境でHTTPステータスコードが操作できる場合にCSPヘッダーを無効化 GoogleのClosureLibraryサニタイザーのXSS脆弱性 WebのProxy機能を介したService Workerの登録 括弧を使わないXSS /記号を使用せずに遷移先URLを指定 SOME(Same Origin Method Execution)を利用してdocument.writeを順次実行 SQL Injection MySQ

      【2020年】CTF Web問題の攻撃手法まとめ - こんとろーるしーこんとろーるぶい
    • みちびき災危通報を受信するためにGNSS受信機を作った話

      前回の記事から約4年3ヶ月ぶりの投稿です... 定期的に文章を書かないと書けなくなってしまうので何か書かなければ...と思っていたら、ちょうどタイミングよくアドベントカレンダーの季節だったので 防災アプリ Advent Calendar 2022の7日目として参加させていただきます。 現在、日本からオーストラリアにかけての上空に「みちびき(初号機〜4号機、初号機後継機)」と命名された準天頂衛星(quasi-zenith satellites)が4機(待機運用中の初号機も合わせると5機)飛んでいます。 この衛星を利用した準天頂衛星システムみちびき(QZSS)は既存のGPSやGLONASSといった衛星測位システムを補完し、常時1機は日本から高仰角で見通せる位置に滞空するように設計されています。 高層ビルの多い都市部や山間部において低仰角を飛んでいるGPSをうまく捕捉できない場合でも高仰角を飛ぶ

        みちびき災危通報を受信するためにGNSS受信機を作った話
      • プロと読み解く Ruby 3.1 NEWS - クックパッド開発者ブログ

        技術部の笹田(ko1)と遠藤(mame)です。クックパッドで Ruby (MRI: Matz Ruby Implementation、いわゆる ruby コマンド) の開発をしています。お金をもらって Ruby を開発しているのでプロの Ruby コミッタです。 本日 12/25 に、ついに Ruby 3.1.0 がリリースされました(Ruby 3.1.0 リリース )。今年も Ruby 3.1 の NEWS.md ファイルの解説をします。NEWS ファイルとは何か、は以前の記事を見てください。 プロと読み解く Ruby 2.6 NEWS ファイル - クックパッド開発者ブログ プロと読み解くRuby 2.7 NEWS - クックパッド開発者ブログ プロと読み解くRuby 3.0 NEWS - クックパッド開発者ブログ 本記事は新機能を解説することもさることながら、変更が入った背景や苦労な

          プロと読み解く Ruby 3.1 NEWS - クックパッド開発者ブログ
        • Docker is deleting Open Source organisations - what you need to know

          Coming up with a title that explains the full story here was difficult, so I'm going to try to explain quickly. Yesterday, Docker sent an email to any Docker Hub user who had created an "organisation", telling them their account will be deleted including all images, if they do not upgrade to a paid team plan. The email contained a link to a tersely written PDF (since, silently edited) which was mi

            Docker is deleting Open Source organisations - what you need to know
          • プロと読み解くRuby 3.4 NEWS - STORES Product Blog

            プロと読み解くRuby 3.4 NEWS テクノロジー部門技術基盤グループの笹田(ko1)と遠藤(mame)です。Ruby (MRI: Matz Ruby Implementation、いわゆる ruby コマンド) の開発をしています。お金をもらって Ruby を開発しているのでプロの Ruby コミッタです。 本日 12/25 に、恒例のクリスマスリリースとして、Ruby 3.4.0 がリリースされました(Ruby 3.4.0 リリース )。今年も STORES Product Blog にて Ruby 3.4 の NEWS.md ファイルの解説をします(ちなみに、STORES Advent Calendar 2024 の記事になります。他も読んでね)。NEWS ファイルとは何か、は以前の記事を見てください。 プロと読み解く Ruby 2.6 NEWS ファイル - クックパッド開発者

              プロと読み解くRuby 3.4 NEWS - STORES Product Blog
            • ぼくのMac環境 ver.のんピ | DevelopersIO

              何年後かの自分へ こんにちは、のんピ(@non____97)です。 業務で使用する新しいMacが届きました。 新しいMacを初期セットアップするにあたって「今の設定どうだったっけ...」と調べる時間が結構かかってしまいました ということで何年後かの自分がまた新しいMacに乗り換える際に手間取らないように、設定した内容を書き記しておきます。 移行先のMacの情報は以下の通りです。M1 Max、嬉しい。 # OSのバージョンの確認 > sw_vers ProductName: macOS ProductVersion: 12.4 BuildVersion: 21F79 # カーネルのバージョン確認 > uname -r 21.5.0 # CPUのアーキテクチャの確認 > uname -m arm64 # CPUの詳細確認 > sysctl -a machdep.cpu machdep.cpu.

                ぼくのMac環境 ver.のんピ | DevelopersIO
              • 2023パズル をRustで解いてみる - すぎゃーんメモ

                tkihiraさんの問題が面白そうだったので挑戦してみた。 2023年クイズ! 上の例のように、数字の合間に四則演算(+−×÷)や括弧を入れることで、2023 を作ってください。 - 数字の間に必ず演算子を 1 つ入れてください - ただし 9 と 8 の間には既に ÷ が入っています - 括弧は複数重ねて使用できます - 10×(-9 ÷ 8) のようなマイナス記号の使用は禁止です pic.twitter.com/K0w2miMXJA— Takuo Kihira (@tkihira) December 31, 2022 既に解説記事が出ているので解答はこちらをどうぞ。 nmi.jp 結局自分は自力では解けなくて 他の人の解法や上記の解説記事を読んでようやくできた、のだけど… 自分なりに理解して改めてRustで実装してみた。 RPN(逆ポーランド記法)の backtracking 探索の高

                  2023パズル をRustで解いてみる - すぎゃーんメモ
                • neue cc - Claudia - Anthropic ClaudeのC# SDKと現代的なC#によるウェブAPIクライアントの作り方

                  AI関連、競合は現れども、性能的にやはりOpenAI一強なのかなぁというところに現れたAnthropic Claude 3は、確かに明らかに性能がいい、GPT-4を凌駕している……!というわけで大いに気に入った(ついでに最近のOpenAIのムーブが気に入らない)ので、C#で使い倒していきたい!そこで、まずはSDKがないので非公式SDKを作りました。こないだまでプレビュー版を流していたのですが、今回v1.0.0として出します。ライブラリ名は、Claudeだから、Claudiaです!.NET全般で使えるのと、Unity(Runtime/Editor双方)でも動作確認をしているので、アイディア次第で色々活用できると思います。 GitHub - Cysharp/Claudia 今回のSDKを作るにあたっての設計指針の一番目は、公式のPython SDKやTypeScript SDKと限りなく似せる

                  • Azure OpenAI Service で、Function calling を試してみる - Taste of Tech Topics

                    こんにちは、igaです。 台風が接近していて、外出の予定と重ならないかドキドキしています。 今回は、Azure OpenAI Service(以下、Azure OpenAIと記載します)で7月から利用できるようになった「Function calling」を試してみます。 Function callingとは、実行可能な関数を予め定義しておき、自然言語から実行すべき関数と引数を特定してくれる機能です。 OpenAIのAPIで、6月にリリースされた機能ですが、それがAzure OpenAIでも利用できるようになりました。 この機能のポイントは、「関数を呼び出す」ことではなく、「呼び出す関数(とその引数)を特定してくれる」ことにあります。 (名前が「Function calling」なのに、ややこしいですね) Azure OpenAIの利用開始方法とAPIの呼び出し方については、前回の記事を参考

                      Azure OpenAI Service で、Function calling を試してみる - Taste of Tech Topics
                    • Introducing Ezno

                      Ezno is an experimental compiler I have been working on and off for a while. In short, it is a JavaScript compiler featuring checking, correctness and performance for building full-stack (rendering on the client and server) websites. This post is just an overview of some of the features I have been working on which I think are quite cool as well an overview on the project philosophy ;) It is still

                        Introducing Ezno
                      • 【機械学習】機械学習を用いたin silico screening【AI創薬】~第2/5章 スクレイピングによる公共データベース(PDB)からの機械学習データを収集~ - LabCode

                        AI創薬とは? AI創薬は、人工知能(AI)技術を利用して新しい薬物を発見、開発するプロセスです。AIは大量のデータを高速に処理し、薬物の候補を予測したり、薬物相互作用を評価したりします。また、AIは薬物の効果や安全性をシミュレートすることも可能で、臨床試験の前の段階でリスクを評価することができます。これにより、薬物開発のコストと時間を大幅に削減することが期待されています。AI創薬は、薬物開発の新しいパラダイムとして注目を集め、製薬企業や研究機関で積極的に研究、導入が進められています。また、バイオインフォマティクス、ケモインフォマティクス、機械学習、ディープラーニングなどの技術が組み合わされ、薬物開発のプロセスを革新しています。さらに、AI創薬は個人化医療の推進にも寄与し、患者にとって最適な治療法を提供する可能性を秘めています。 今回はAI創薬の中でも、in silico screeeni

                        • Writing a C compiler in 500 lines of Python

                          A few months ago, I set myself the challenge of writing a C compiler in 500 lines of Python1, after writing my SDF donut post. How hard could it be? The answer was, pretty hard, even when dropping quite a few features. But it was also pretty interesting, and the result is surprisingly functional and not too hard to understand! There's too much code for me to comprehensively cover in a single blog

                          • Lessons from Writing a Compiler

                            The prototypical compilers textbook is: 600 pages on parsing theory. Three pages of type-checking a first-order type system like C. Zero pages on storing and checking the correctness of declarations (the “symbol table”). Zero pages on the compilation model, and efficiently implementing separate compilation. 450 pages on optimization and code generation. The standard academic literature is most use

                            • LangGraph を用いた LLM エージェント、Plan-and-Execute Agents の実装解説 - Algomatic Tech Blog

                              はじめに こんにちは。Algomatic LLM STUDIO 機械学習エンジニアの宮脇(@catshun_)です。 Wang+’23 - A Survey on Large Language Model Based Autonomous Agents ChatGPT が発表されてからおよそ 1 年が経ち、AutoGPT, BabyAGI, HuggingGPT, Generative Agents, ChatDev, Mind2Web, Voyager, MetaGPT, Self-Recovery Prompting, OpenCodeInterpreter, AutoAgents などなど、大規模言語モデル (LLM) の抱負な知識および高度な推論能力を活用した LLM エージェント (AIエージェント) が発表されています。 直近ではコード生成からデバッグ、デプロイまで自律的に行う

                                LangGraph を用いた LLM エージェント、Plan-and-Execute Agents の実装解説 - Algomatic Tech Blog
                              • Rewriting the Ruby parser

                                At Shopify, we have spent the last year writing a new Ruby parser, which we’ve called YARP (Yet Another Ruby Parser). As of the date of this post, YARP can parse a semantically equivalent syntax tree to Ruby 3.3 on every Ruby file in Shopify’s main codebase, GitHub’s main codebase, CRuby, and the 100 most popular gems downloaded from rubygems.org. We recently got approval to merge this work into C

                                  Rewriting the Ruby parser
                                • Changing std::sort at Google’s Scale and Beyond

                                  TL;DR; We are changing std::sort in LLVM’s libcxx. That’s a long story of what it took us to get there and all possible consequences, bugs you might encounter with examples from open source. We provide some benchmarks, perspective, why we did this in the first place and what it cost us with exciting ideas from Hyrum’s Law to reinforcement learning. All changes went into open source and thus I can

                                    Changing std::sort at Google’s Scale and Beyond
                                  • 4 Pandas Anti-Patterns to Avoid and How to Fix Them

                                    pandas is a powerful data analysis library with a rich API that offers multiple ways to perform any given data manipulation task. Some of these approaches are better than others, and pandas users often learn suboptimal coding practices that become their default workflows. This post highlights four common pandas anti-patterns and outlines a complementary set of techniques that you should use instea

                                      4 Pandas Anti-Patterns to Avoid and How to Fix Them
                                    • Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction - cl-fast-ecs by Andrew

                                      Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction In this series of tutorials, we will delve into creating simple 2D games in Common Lisp. The result of the first part will be a development environment setup and a basic simulation displaying a 2D scene with a large number of physical objects. It is assumed that the reader is familiar with some high-level programming language, has a gener

                                        Gamedev in Lisp. Part 1: ECS and Metalinguistic Abstraction - cl-fast-ecs by Andrew
                                      • Perl 5.32の連鎖比較(Chained comparisons)はどの様に実装されているのか - Acme::AnaTofuZ->new;

                                        この記事はPerl Advent Calendar 2020と琉大 Advent Calendar 2020の11日目の記事です。 PerlはPerl5になって長いですが、現在の最新の安定版のバージョンは5.32です。 Perl5.32で取り入れられた(厳密には5.31からですが)のおもしろ機能として連鎖比較(Chained comparisons)が存在します。 今までPerlで数値などが特定の範囲に含まれているかどうかをif文で判定するには次の様に書く必要がありました。 if (10 < $n && $n <= 20) これがこう書ける様になります!!! if ( 10 < $n <= 20 ) {...} 便利!!!!!!!!!!!!!!!!!!!!!!!! ...........というわけで、この便利な連鎖比較がどの様に実装されているかを探検してみます。 言語処理系の実装 さて今か

                                          Perl 5.32の連鎖比較(Chained comparisons)はどの様に実装されているのか - Acme::AnaTofuZ->new;
                                        • The Roc Programming Language

                                          Examples Roc is a young language. It doesn't even have a numbered release yet, just nightly builds! However, it can already be used for several things if you're up for being an early adopter— with all the bugs and missing features which come with that territory. Here are some examples of how it can be used today. Command-Line Interfaces main! = |args| Stdout.line!("Hello!") You can use Roc to crea

                                          • Weird Lexical Syntax

                                            I just learned 42 programming languages this month to build a new syntax highlighter for llamafile. I feel like I'm up to my eyeballs in programming languages right now. Now that it's halloween, I thought I'd share some of the spookiest most surprising syntax I've seen. The languages I decided to support are Ada, Assembly, BASIC, C, C#, C++, COBOL, CSS, D, FORTH, FORTRAN, Go, Haskell, HTML, Java,

                                              Weird Lexical Syntax
                                            • Golang Mini Reference 2022: A Quick Guide to the Modern Go Programming Language (REVIEW COPY)

                                              Golang Mini Reference 2022 A Quick Guide to the Modern Go Programming Language (REVIEW COPY) Harry Yoon Version 0.9.0, 2022-08-24 REVIEW COPY This is review copy, not to be shared or distributed to others. Please forward any feedback or comments to the author. • feedback@codingbookspress.com The book is tentatively scheduled to be published on September 14th, 2022. We hope that when the release da

                                              • Why Rust strings seem hard | Brandon's Website

                                                Why Rust strings seem hard April 13, 2021 Lately I've been seeing lots of anecdotes from people trying to get into Rust who get really hung up on strings (&str, String, and their relationship). Beyond Rust's usual challenges around ownership, there can be an added layer of frustration because strings are so easy in the great majority of languages. You just add them together, split them, whatever!

                                                • syntaxdesign

                                                  One of the most recognizable features of a languages is its syntax. What are some of the things about syntax that matter? What questions might you ask if you were creating a syntax for your own language? Motivation A programming language gives us a way structure our thoughts. Each program, has a kind of internal structure, for example: How can we capture this structure? One way is directly, via pi

                                                  • Implementing Logic Programming

                                                    Most of my readers are probably familiar with procedural programming, object-oriented programming (OOP), and functional programming (FP). The majority of top programming languages on all of the language popularity charts (like TIOBE) support all three to some extent. Even if a programmer avoided one or more of those three paradigms like the plague, they’re likely at least aware of them and what th

                                                      Implementing Logic Programming
                                                    • Font with Built-In Syntax Highlighting

                                                      Note: I received a lot of great feedback from the discussions at Mastodon and Hacker News, so I've updated the post with some improvements to the font! I've also added some further examples and acknowledgements at the end. Syntax Highlighting in Hand-Coded Websites The problem I have been trying to identify practical reasons why hand-coding websites with HTML and CSS is so hard (by hand-coding, I

                                                      • Using Rust at a startup: A cautionary tale

                                                        Rust is awesome, for certain things. But think twice before picking it up for a startup that needs to move fast. All of the art for this post was generated using DALL-E.I hesitated writing this post, because I don’t want to start, or get into, a holy war over programming languages. (Just to get the flame bait out of the way, Visual Basic is the best language ever!) But I’ve had a number of people

                                                          Using Rust at a startup: A cautionary tale
                                                        • Agentic GraphRAG for Commercial Contracts | Towards Data Science

                                                          In every business, legal contracts are foundational documents that define the relationships, obligations, and responsibilities between parties. Whether it’s a partnership agreement, an NDA, or a supplier contract, these documents often contain critical information that drives decision-making, risk management, and compliance. However, navigating and extracting insights from these contracts can be a

                                                            Agentic GraphRAG for Commercial Contracts | Towards Data Science
                                                          • Python でアプリ開発できる Flet を触ってみた | DevelopersIO

                                                            こんにちは、森田です。 最近周りの人から Python でアプリ開発のできる Flet について教えてもらい、面白そうなのでチュートリアルをやってみました。 よかったら参考にしてみてください。 Flet とは Flet は、フロントエンド開発の経験がなくても、簡単に Web、デスクトップ、モバイル アプリケーションを開発できるフレームワークです。 開発はPythonで行うことができ、内部的には、Flutter を利用しているようです。 標準でウィジェットが用意されているため、フロントの開発を行うことなく、少ない労力で、アプリとして動作させることができます。 Python で複雑すぎないアプリを作りたい場合にピッタリのフレームワークとなります。 やってみた 本記事では、チュートリアルに従って、電卓アプリを作ってみます。 なお、本記事では、Mac Python 3.8.13にて行います。 ライ

                                                              Python でアプリ開発できる Flet を触ってみた | DevelopersIO
                                                            • Kalyn: a self-hosting compiler for x86-64

                                                              Over the course of my Spring 2020 semester at Harvey Mudd College, I developed a self-hosting compiler entirely from scratch. This article walks through many interesting parts of the project. It’s laid out so you can just read from beginning to end, but if you’re more interested in a particular topic, feel free to jump there. Or, take a look at the project on GitHub. Table of contents What the pro

                                                              • Lies we tell ourselves to keep using Golang

                                                                👋 This page was last updated ~3 years ago. Just so you know. In the two years since I’ve posted I want off Mr Golang’s Wild Ride, it’s made the rounds time and time again, on Reddit, on Lobste.rs, on HackerNews, and elsewhere. And every time, it elicits the same responses: You talk about Windows: that’s not what Go is good at! (Also, who cares?) This is very one-sided: you’re not talking about th

                                                                  Lies we tell ourselves to keep using Golang
                                                                • A Walk with LuaJIT

                                                                  The following is a chronicle of implementing a general purpose zero-instrumentation BPF based profiler for LuaJIT. Some assumptions are made about what this entails and it may be helpful to read some of our other work in this area. One major change from prior efforts is that instead of working with the original Parca unwinder we are now working with the OpenTelemetry eBPF profiler. If you missed t

                                                                    A Walk with LuaJIT
                                                                  • The joy of building a ray tracer, for fun, in Rust. // flurries of latent creativity

                                                                    TLDR? You can find the code and a bunch of examples on GitHub at dps/rust-raytracer. Over the holiday break, I decided to learn Rust. Rust is a modern systems programming language which has a really interesting type system. The type system can catch broad classes of common programming mistakes - e.g. ensuring memory is accessed safely - at compile time while generating tight, performant machine co

                                                                      The joy of building a ray tracer, for fun, in Rust. // flurries of latent creativity
                                                                    • Coroutines and effects

                                                                      For the past few months I’ve been mulling over some things that Russell Johnston made me realize about the relationship between effect systems and coroutines. You can read more of his thoughts on this subject here, but he made me realize that effect systems (like that found in Koka) and coroutines (like Rust’s async functions or generators) are in some ways isomorphic to one another. I’ve been pon

                                                                      • 自作 Set ライブラリ提供 : C++ の std::set が残念な件 - Qiita

                                                                        はじめに C++ の std::set は素晴らしいライブラリです。自前でこれを実装しようとしてもなかなかここまで速いものは作れないでしょう。 std::set の代替手段として tatyam さんのライブラリが有名ですが、これは std::set がない Python のためのやつなので、Python ユーザー限定です。 Python に順序付き集合がないことはよく話題に上がることなのですが、C++ の順序付き集合である std::set も競プロをする上ではなかなか残念なので、C++ 用の順序付き集合ライブラリを公開すればみなさん嬉しいかもと思い、公開するに至りました。 競技プログラミングにおける活用 std::set にもつけ入る隙があります。 要素アクセスが線形時間 集約や遅延評価が載っていない 値の重複を許さない(これは std::map と併用するなどで解決できますが) これら

                                                                          自作 Set ライブラリ提供 : C++ の std::set が残念な件 - Qiita
                                                                        • OpenAI API の Structured Outputs の使い方|npaka

                                                                          以下の記事が面白かったので、簡単にまとめました。 ・Introducing Structured Outputs in the API 1. Structured Outputs昨年のDevDayで、「JSONモード」を導入しました。これは、OpenAIのモデルを使用して信頼性の高いアプリを構築しようとしている開発者にとって便利な構成要素です。「JSONモード」は、有効なJSON出力を生成するためのモデルの信頼性を向上させますが、モデルの応答が特定のスキーマに準拠することを保証するものではありません。本日、APIに「Structured Outputs」を導入します。これは、モデルによって生成された出力が、開発者が提供するJSONスキーマと完全に一致するように設計された新機能です。 複雑なJSONスキーマのフォローの評価では、「Structured Outputs」を備えた新しいモデル「g

                                                                            OpenAI API の Structured Outputs の使い方|npaka
                                                                          • 0.8.0 Release Notes ⚡ The Zig Programming Language

                                                                            Tier 4 Support § Support for these targets is entirely experimental. If this target is provided by LLVM, LLVM may have the target as an experimental target, which means that you need to use Zig-provided binaries for the target to be available, or build LLVM from source with special configure flags. zig targets will display the target if it is available. This target may be considered deprecated by

                                                                            • Zig in 30 minutes

                                                                              test.md A half-hour to learn Zig This is inspired by https://fasterthanli.me/blog/2020/a-half-hour-to-learn-rust/ Basics the command zig run my_code.zig will compile and immediately run your Zig program. Each of these cells contains a zig program that you can try to run (some of them contain compile-time errors that you can comment out to play with) You'll want to declare a main() function to get

                                                                                Zig in 30 minutes
                                                                              • "�[31m"?! ANSI Terminal security in 2023 and finding 10 CVEs

                                                                                This paper reflects work done in late 2022 and 2023 to audit for vulnerabilities in terminal emulators, with a focus on open source software. The results of this work were 10 CVEs against terminal emulators that could result in Remote Code Execution (RCE), in addition various other bugs and hardening opportunities were found. The exact context and severity of these vulnerabilities varied, but some

                                                                                • The Architecture of a Modern Startup | by Dmitry Kruglov | Nov, 2022 | Better Programming

                                                                                  workflow — all images by authorThe Tech side of startups can sometimes be very fluid and contain a lot of unknowns. What tech stack to use? Which components might be overkill for now but worth keeping an eye on in the future? How to balance the pace of business features development while keeping the quality bar high enough to have a maintainable codebase? Here I want to share our experience buildi

                                                                                    The Architecture of a Modern Startup | by Dmitry Kruglov | Nov, 2022 | Better Programming