SShortSingh.
0
ProgrammingDEV Community ·

How to Detect and Fix Catastrophic Backtracking in JavaScript Regexes

A developer maintaining CodeSwap, a browser-based developer-tools site, documented a repeatable audit process for identifying JavaScript regular expressions vulnerable to ReDoS, or Regular Expression Denial of Service attacks. The core risk arises when nested or overlapping quantifiers allow the regex engine to explore an exponentially growing number of match paths before rejecting a crafted input. Testing the pattern /^(a+)+$/ with incrementally longer hostile strings revealed that every two additional characters roughly quadrupled processing time, reaching over six seconds for just 30 characters. OWASP identifies nested quantifiers and overlapping alternatives inside repetition as key warning signs of this vulnerability. The recommended fix is to eliminate ambiguous repetition — for example, replacing /^(a+)+$/ with /^a+$/ — and to always test suspicious patterns in an isolated environment using short, controlled inputs rather than on a live request thread.

0
ProgrammingDEV Community ·

Five Common Casbin model.conf Mistakes That Silently Break Permissions

Casbin is a cross-language permission framework where model.conf defines access rules and a separate policy file stores the data, but beginners frequently misconfigure it with no error feedback. The five most reported mistakes include swapping the order of request or policy definition columns, failing to add the required role-assignment rows in the policy file alongside the role definition, and misunderstanding how policy effects like priority denial work. Developers using the cached synced enforcer often mistake stale cache results for model errors, delaying debugging. Because model.conf fails silently by returning false, the Casbin community is now gathering real user pain points to build a plain-language tool that auto-generates correct configurations.

0
ProgrammingDEV Community ·

Developer shares input validation lessons from building 77 browser calculators

A developer building 77 free browser-based calculators for a platform called Efficienco found that handling user inputs correctly was far harder than writing the underlying formulas. Key lessons included distinguishing between empty fields and invalid entries, rather than treating all falsy values as missing. Domain-specific range checks, unit conversion to a single base unit before calculation, and preserving full numeric precision until the final display step were identified as critical patterns. The developer also noted that hidden assumptions — such as waste factors or efficiency rates — should be surfaced and made editable to avoid giving users a false sense of precision. The article focuses entirely on pre- and post-formula logic, offering reusable validation patterns applicable across varied calculator types.

0
ProgrammingDEV Community ·

How to Show Gratitude to React Developers: Community Ways to Give Back

A developer who has successfully used React in a commercial Enterprise Content Management system is looking for ways to thank the framework's creators. The user praised React's component-based architecture and its state and props model for managing large codebases. They explored React's official site and GitHub repository but could not find clear channels for financial or non-financial contributions. Possible ways to give back include reporting bugs, contributing to the open-source codebase, creating learning materials, or promoting the framework within the developer community. The post invites advice from others on meaningful ways to express appreciation to the React team and its broader ecosystem.

0
IndiaTimes of India ·

India becomes key petrol supplier to Russia amid Ukraine drone strikes on refineries

India has significantly ramped up gasoline exports to Russia following Ukrainian drone attacks that disrupted Russian refinery operations. Russian gasoline imports reached record levels in August, with India playing a central role in meeting that demand. A considerable portion of these shipments were carried out using sanctioned vessels and complex cargo transfer methods. Analysts suggest that India's growing imports of Russian crude oil are closely linked to the expansion of this reverse fuel export relationship.

0
IndiaNDTV ·

Panjab University LLB Student Found Dead by Suicide in Campus Hostel

A law student named Chatanniya Singh was found dead by suicide in a hostel on the Panjab University campus, police confirmed on Saturday. Singh, a resident of Panipat, Haryana, was enrolled in the LLB program at the University Institute of Legal Studies (UILS). Authorities have identified the deceased and are investigating the circumstances surrounding his death. No further details regarding a possible motive have been officially disclosed so far.

0
ProgrammingDEV Community ·

Developer Builds VSCode Plugin to Display Flat AI-Generated Files as Virtual Folder Trees

A developer found that an AI coding agent had created 340 flat files in a single directory within one week, making navigation difficult for humans. To solve this, they built a plugin called Logical Folders for VSCode and IntelliJ that parses underscore-separated filenames and renders them as a virtual directory tree. No files are moved on disk — the hierarchy exists purely as a visual layer within the IDE. The plugin works by splitting filenames on a configurable separator character and mapping the segments to tree nodes using TypeScript. It includes performance safeguards such as a default 10,000-file cap to prevent slowdowns in large monorepos.

0
ProgrammingDEV Community ·

Three Open-Source AI Tools Aim to Strengthen Defensive Security Workflows

Developers have introduced three open-source AI-powered tools designed to support defensive cybersecurity operations. The tools focus on security findings reporting, AI-assisted alert triage, and log anomaly detection. Built with auditability in mind, the lightweight utilities target security teams seeking transparent, inspectable AI assistance. The tools — SentinelMesh, an AI Security Report generator, and an LLM-based Log Anomaly Detector — are documented via a hub called Ax0r. Their small footprint and open-source nature make them accessible for teams looking to integrate AI into security workflows without relying on black-box solutions.

0
IndiaTimes of India ·

NASA Chief Backs Space-Based Data Centers Alongside Musk and Pichai

NASA Administrator Jared Isaacman has voiced support for relocating data centers to Earth's orbit, joining tech leaders Elon Musk and Sundar Pichai in backing the concept. The initiative would harness solar energy in space while reducing the environmental footprint of ground-based facilities. Growing public resistance to terrestrial data centers, driven by economic and environmental concerns, is adding momentum to the idea. Technology companies are increasingly exploring space-based infrastructure as a long-term solution for powering future AI development.

0
IndiaNDTV ·

Netanyahu's Son Evacuated from US to Israel Amid Serious Iranian Threat

Israeli Prime Minister Benjamin Netanyahu's son has been flown back to Israel from the United States due to a significant security threat attributed to Iran. The evacuation follows Netanyahu's statement last week in which he claimed Iran had attempted to assassinate one of his sons. The move indicates that Israeli security officials assessed the threat as credible and serious enough to warrant immediate action. The incident reflects the ongoing and escalating tensions between Israel and Iran, which have extended beyond the battlefield to targeting individuals abroad.

0
IndiaNDTV ·

Delhi Man Kills Schizophrenic Son With Help of Accomplice After Repeated Fights

A 64-year-old Delhi man, Talukdar Ansari, allegedly killed his 38-year-old schizophrenic son Gul Hasan with the help of an accomplice, Md Wasim alias Akram, aged 49. The two men lured Gul Hasan to an abandoned container under the false pretense of taking him to a doctor. Once there, they struck him on the head with a concrete block and subsequently strangled him to death. The killing is reported to have been motivated by the father's frustration over repeated altercations with his mentally ill son. Authorities are investigating the case following the discovery of the crime.

0
SportsESPNcricinfo ·

Trinbago Knight Riders retire Dwayne Bravo's No. 47 jersey in his honour

Trinbago Knight Riders have retired the No. 47 jersey of Caribbean cricket legend Dwayne Bravo in recognition of his contributions to the franchise. Bravo was a central figure in the team's success, winning the Caribbean Premier League title five times with the Knight Riders. His association with the franchise extended beyond his playing career, as he led the side to the CPL title as head coach last season. The retirement of his jersey number marks a lasting tribute to one of the most decorated figures in CPL history.

0
IndiaTimes of India ·

Roger Federer gets emotional at International Tennis Hall of Fame induction speech

Tennis legend Roger Federer was inducted into the International Tennis Hall of Fame and delivered a heartfelt speech during the ceremony. The 20-time Grand Slam champion became visibly emotional multiple times while reflecting on his career and the people who shaped it. Federer expressed gratitude toward his childhood hero, longtime coach, and wife Mirka for their support throughout his journey. He also used the occasion to inspire future players to continue pushing the boundaries of tennis. Broadcaster Mary Carillo was inducted alongside Federer, describing the honour as beyond her wildest dreams.

0
ProgrammingDEV Community ·

AfterMind Uses AI to Transform Personal Thoughts Into Narrative Stories

AfterMind is an AI-powered storytelling platform built to help users express their thoughts and emotions through personalized narratives rather than traditional journaling. Users input their experiences via a simple interface, and the application processes that input to generate a contextually relevant, personalized story. The development team integrated TrueForge as an agent layer to connect AI capabilities with the storytelling workflow, moving beyond basic input-output interactions. Code quality tool Qodo was also used during development to review implementation, flag issues, and improve code maintainability. The platform was designed with a minimal, approachable interface to ensure users feel comfortable sharing personal content while keeping the generated story at the center of the experience.

0
ProgrammingDEV Community ·

AI Writes Code Fast, But Verifying It Correctly Is Now the Critical Developer Skill

As AI tools rapidly generate functional-looking code, software engineers face a growing challenge: proving that code is actually correct, not just superficially working. A 2025 Stack Overflow survey found 84% of developers use or plan to use AI tools, yet only 33% trust AI output accuracy, with 66% frustrated by code that is 'almost correct but not quite.' Industry frameworks from NIST and CISA recommend layered verification practices — including peer review, static analysis, and automated testing — rather than relying on any single check. Experts argue that AI shifts the developer's role from writing code to rigorously understanding, verifying, and validating what AI produces before it reaches production. The core message is that while code generation is becoming cheaper and faster, the ability to critically evaluate and prove correctness is becoming the more valuable engineering skill.

0
ProgrammingHacker News ·

Google Maps to Reflect Official US Rename of Lake Ontario to Lake America

Google has announced that an official US government name change for Lake Ontario will be reflected in Google Maps. The renaming, which designates the lake as 'Lake America' within US borders, follows an update to the Geographic Names Information System (GNIS), the authoritative federal database for US place names. Google stated it updates Maps in accordance with official government naming bodies. The change means US users of Google Maps will see the lake labeled differently than users in Canada, where the original name remains in use.

← NewerPage 625 of 3971Older →